An OSGi bundle can use third-party JAR files. That is, classes located within a third-party JAR file can be used within an OSGi bundle. To demonstrate how to create an OSGi bundle that uses a third-party JAR file, this development article uses a third-party JAR file and EchoService.jar. This JAR file contains the following basic Java class named EchoService2.
package com.adobe.myexample;
public class EchoService2 {
public String sayHello(String val){
return "Echo Service says: " +val ;
}
}
Note: Before following along with this development article, install Adobe CQ 5.5 (or higher) and have it running. Also, ensure that you have CRXDE, which is the development environment. Finally, create a JAR file named EchoService.jar and ensure that it contains the EchoService2 class shown above.
To read this entire article, click this link: http://helpx.adobe.com/adobe-cq/using/creating-osgi-bundles-digital-marketing.html.
Note: This development article discusses how to develop an OSGi bundle using CRXDE.
There are other ways to create an OSGi bundle. For information, see http://scottsdigitalcommunity.blogspot.ca/2012/12/exploring-different-ways-in-which-you.html.
No comments:
Post a Comment
If you have any doubts or questions, please let us know.