Hi,

We had discussions on this ML before on how to support SCDL extensibility elements which are not part of the base SCDL model and are used in SCDL for <xsd:any/>.

Let's use <import.sdo> as an example to illustrate my proposal.

1) ImportSDOLoader is a StAXElementLoader to load <import.sdo> element into ImportSDO model object.

2) The model object is attached to the parent model object which is CompositeComponentType in this case. We can use ModeObject.getExtensions() to keep the models loaded from the extensibility elements.

3) Add a GenericBuilder interface and GenericBuidlerExtension in SPI as follows:

public interface GenericBuilder<S extends SCAObject, M extends ModelObject> { S build(SCAObject parent, M modelObject, DeploymentContext deploymentContext) throws BuilderException;
}

4) Change the Buidler and BuilderRegistry interface to support GenericBuilder.

5) Create an ImportSDOBuilder which will create HelperContext from the ImportSDO model.

6) When the BuilderRegistery builds Component/Service/Reference, we look at the extensions for the corresponding model objects and try to run the GenericBuilders against the objects in ModelObject.getExtensions().

7) The ImportSDOBuilder creates a AtomicComponent to wrap HelperContext. and register it in the composite so that the component impl can use @Reference (autowire=true) to get access to this HelperContext.

If we agree I'm on track with the overall direction, I'll work on it.

Thanks,
Raymond


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to