Ripla

Rich Platform project for Java web applications.

This project is maintained by aktion-hip

OSGi Component Description

The following XML shows an example of a component description registering a use case as OSGi declarative service at the container's service registry:

<?xml version="1.0" encoding="UTF-8"?>
<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0" name="org.ripla.web.demo.widgets.usecase">
   <implementation class="org.ripla.web.demo.widgets.scr.UseCaseComponent"/>
   <service>
      <provide interface="org.ripla.web.services.IUseCase"/>
   </service>
</scr:component>

This component description states that the class org.ripla.demo.widgets.scr.UseCaseComponent is implementing the org.ripla.web.services.IUseCase service. This service will be registered as org.ripla.demo.widgets.usecase.

If you named this component description OSGI-INF/useCase.xml, you have to add the following statement to the bundle's MANIFEST.MF:

Service-Component: OSGI-INF/useCase.xml