The Free and Open Productivity Suite
Released: Apache OpenOffice 4.1.14

Registering java components

As there are many ways to Rom, there many ways to register a component. But what all ways have in common, is that an ImplementationRegistration instance is needed.

So, a service can be registered via star basic creating the service ImplementationRegistration and calling the method registerImplementation.

Basic example:

regImpl = createUnoService("")
regImpl.registerImplementation("", "file:///home/testComponent.jar", null)

Another way is to use the binary UNO bound tool regcomp. This tool needs to create a java virtual machine, which it does by the service JavaVirtualMachine.

Binary exmaple (UNIX):

setenv OO_JAVA_PROPERTIES RuntimeLib=/usr/java1.2/jre/lib/sparc/native_threads/
setenv CLASSPATH $UDK/ridljar:$UDK/jurt.jar:$UDK/java_uno.jar
regcomp -register -br applicat.rdb -c file:///home/testComponent.jar -l

Unfortunatley this service JavaVirtualMachine often needs some hints, to find the java installation to use. To avoid this, there is another java based tool.

Java example:

java applicat.rdb register file:///home/testComponent.jar 



Apache Software Foundation

Copyright & License | Privacy | Contact Us | Donate | Thanks

Apache, OpenOffice, and the seagull logo are registered trademarks of The Apache Software Foundation. The Apache feather logo is a trademark of The Apache Software Foundation. Other names appearing on the site may be trademarks of their respective owners.