host.embeddedThe embedded host extension provides some simple options for embedding the SCA runtime in other applications such as the programs that the Apache Tuscany project uses for tests and for its sample applications. SCADomainYou will see SCADomain used in many of the project's test and sample applications in the following form: Code Block |
---|
// intialize the Tuscany SCA Java runtime and provide a contribution
SCADomain scaDomain = SCADomain.newInstance("Calculator.composite");
// a self reference to a service in the contribution
CalculatorService calculatorService = scaDomain.getService(CalculatorService.class, "CalculatorServiceComponent");
// do some work with the service
int result = calculatorService.add(3, 2)
// shut down the Tuscany SCA Java runitme
scaDomain.close();
|
SCADomain provides an interface for creating a domain and adding contributions. Once the domain is initialize it can be used to find services and references from the domain so that they can be manipulated directly. Selecting A Domain ImplementationCurrently two domain inplementations are provided, DefaultSCADomain and EmbeddedSCADomain. You can choose between the two by... TODO
DefaultSCADomainDefining A Contribution TODO
Domain URI TODO
Getting Services TODO
Getting References TODO
EmbeddedSCADomainDefining A Contribution TODO
Domain URI TODO
Getting Services TODO
Getting References TODO
|