diff options
Diffstat (limited to 'javaunohelper/com/sun/star/comp/helper')
7 files changed, 162 insertions, 162 deletions
diff --git a/javaunohelper/com/sun/star/comp/helper/Bootstrap.java b/javaunohelper/com/sun/star/comp/helper/Bootstrap.java index 04bba081e37f..d954f036820d 100644 --- a/javaunohelper/com/sun/star/comp/helper/Bootstrap.java +++ b/javaunohelper/com/sun/star/comp/helper/Bootstrap.java @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -68,34 +68,34 @@ import java.util.Random; // insert the service manager xSet.insert( aSingleComponentFactory ); </pre> -*/ +*/ public class Bootstrap { - + private static void insertBasicFactories( XSet xSet, XImplementationLoader xImpLoader ) throws Exception { - // insert the factory of the loader + // insert the factory of the loader xSet.insert( xImpLoader.activate( "com.sun.star.comp.loader.JavaLoader", null, null, null ) ); - - // insert the factory of the URLResolver + + // insert the factory of the URLResolver xSet.insert( xImpLoader.activate( "com.sun.star.comp.urlresolver.UrlResolver", null, null, null ) ); - + // insert the bridgefactory xSet.insert( xImpLoader.activate( "com.sun.star.comp.bridgefactory.BridgeFactory", null, null, null ) ); - + // insert the connector xSet.insert( xImpLoader.activate( "com.sun.star.comp.connections.Connector", null, null, null ) ); - + // insert the acceptor xSet.insert( xImpLoader.activate( "com.sun.star.comp.connections.Acceptor", null, null, null ) ); } - + /** Bootstraps an initial component context with service manager and basic jurt components inserted. @param context_entries the hash table contains mappings of entry names (type string) to @@ -107,22 +107,22 @@ public class Bootstrap { { XImplementationLoader xImpLoader = UnoRuntime.queryInterface( XImplementationLoader.class, new JavaLoader() ); - + // Get the factory of the ServiceManager XSingleComponentFactory smgr_fac = UnoRuntime.queryInterface( XSingleComponentFactory.class, xImpLoader.activate( "com.sun.star.comp.servicemanager.ServiceManager", null, null, null ) ); - + // Create an instance of the ServiceManager XMultiComponentFactory xSMgr = UnoRuntime.queryInterface( XMultiComponentFactory.class, smgr_fac.createInstanceWithContext( null ) ); - + // post init loader XInitialization xInit = UnoRuntime.queryInterface( XInitialization.class, xImpLoader ); Object[] args = new Object [] { xSMgr }; xInit.initialize( args ); - + // initial component context if (context_entries == null) context_entries = new Hashtable( 1 ); @@ -132,22 +132,22 @@ public class Bootstrap { new ComponentContextEntry( null, xSMgr ) ); // ... xxx todo: add standard entries XComponentContext xContext = new ComponentContext( context_entries, null ); - + // post init smgr xInit = UnoRuntime.queryInterface( XInitialization.class, xSMgr ); args = new Object [] { null, xContext }; // no registry, default context xInit.initialize( args ); - + XSet xSet = UnoRuntime.queryInterface( XSet.class, xSMgr ); // insert the service manager xSet.insert( smgr_fac ); // and basic jurt factories insertBasicFactories( xSet, xImpLoader ); - + return xContext; } - + /** * Bootstraps a servicemanager with the jurt base components registered. * <p> @@ -159,10 +159,10 @@ public class Bootstrap { return UnoRuntime.queryInterface( XMultiServiceFactory.class, createInitialComponentContext( null ).getServiceManager() ); } - - + + /** Bootstraps the initial component context from a native UNO installation. - + @see cppuhelper/defaultBootstrap_InitialComponentContext() */ static public final XComponentContext defaultBootstrap_InitialComponentContext() @@ -171,12 +171,12 @@ public class Bootstrap { return defaultBootstrap_InitialComponentContext( null, null ); } /** Bootstraps the initial component context from a native UNO installation. - + @param ini_file ini_file (may be null: uno.rc besides cppuhelper lib) @param bootstrap_parameters bootstrap parameters (maybe null) - + @see cppuhelper/defaultBootstrap_InitialComponentContext() */ static public final XComponentContext defaultBootstrap_InitialComponentContext( @@ -197,7 +197,7 @@ public class Bootstrap { pairs[ n++ ] = (String)bootstrap_parameters.get( name ); } } - + if (! m_loaded_juh) { NativeLibraryLoader.loadLibrary( Bootstrap.class.getClassLoader(), "juh" ); @@ -208,7 +208,7 @@ public class Bootstrap { cppuhelper_bootstrap( ini_file, pairs, Bootstrap.class.getClassLoader() ) ); } - + static private boolean m_loaded_juh = false; static private native Object cppuhelper_bootstrap( String ini_file, String bootstrap_parameters [], ClassLoader loader ) @@ -216,27 +216,27 @@ public class Bootstrap { /** * Bootstraps the component context from a UNO installation. - * + * * @return a bootstrapped component context. - * + * * @since UDK 3.1.0 - */ + */ public static final XComponentContext bootstrap() throws BootstrapException { - + XComponentContext xContext = null; - + try { - // create default local component context + // create default local component context XComponentContext xLocalContext = createInitialComponentContext( null ); if ( xLocalContext == null ) throw new BootstrapException( "no local component context!" ); - + // find office executable relative to this class's class loader String sOffice = System.getProperty( "os.name" ).startsWith( "Windows" ) ? - "soffice.exe" : "soffice"; + "soffice.exe" : "soffice"; File fOffice = NativeLibraryLoader.getResource( Bootstrap.class.getClassLoader(), sOffice ); if ( fOffice == null ) @@ -245,7 +245,7 @@ public class Bootstrap { // create random pipe name String sPipeName = "uno" + Long.toString( (new Random()).nextLong() & 0x7fffffffffffffffL ); - + // create call with arguments String[] cmdArray = new String[7]; cmdArray[0] = fOffice.getPath(); @@ -255,26 +255,26 @@ public class Bootstrap { cmdArray[4] = "-nocrashreport"; cmdArray[5] = "-nolockcheck"; cmdArray[6] = "-accept=pipe,name=" + sPipeName + ";urp;"; - + // start office process Process p = Runtime.getRuntime().exec( cmdArray ); pipe( p.getInputStream(), System.out, "CO> " ); pipe( p.getErrorStream(), System.err, "CE> " ); - + // initial service manager XMultiComponentFactory xLocalServiceManager = xLocalContext.getServiceManager(); if ( xLocalServiceManager == null ) throw new BootstrapException( "no initial service manager!" ); - + // create a URL resolver XUnoUrlResolver xUrlResolver = UnoUrlResolver.create( xLocalContext ); - + // connection string String sConnect = "uno:pipe,name=" + sPipeName + ";urp;StarOffice.ComponentContext"; - + // wait until office is started for (int i = 0;; ++i) { try { @@ -301,13 +301,13 @@ public class Bootstrap { } catch ( java.lang.Exception e ) { throw new BootstrapException( e ); } - + return xContext; } private static void pipe( final InputStream in, final PrintStream out, final String prefix ) { - + new Thread( "Pipe: " + prefix) { public void run() { BufferedReader r = new BufferedReader( diff --git a/javaunohelper/com/sun/star/comp/helper/BootstrapException.java b/javaunohelper/com/sun/star/comp/helper/BootstrapException.java index 4d84a4f7dd3f..3136358c257f 100644 --- a/javaunohelper/com/sun/star/comp/helper/BootstrapException.java +++ b/javaunohelper/com/sun/star/comp/helper/BootstrapException.java @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -30,16 +30,16 @@ package com.sun.star.comp.helper; /** * BootstrapException is a checked exception that wraps an exception * thrown by the original target. - * + * * @since UDK 3.1.0 */ public class BootstrapException extends java.lang.Exception { - + /** * This field holds the target exception. */ private Exception m_target = null; - + /** * Constructs a <code>BootstrapException</code> with <code>null</code> as * the target exception. @@ -56,7 +56,7 @@ public class BootstrapException extends java.lang.Exception { */ public BootstrapException( String message ) { super( message ); - } + } /** * Constructs a <code>BootstrapException</code> with the specified @@ -69,17 +69,17 @@ public class BootstrapException extends java.lang.Exception { super( message ); m_target = target; } - + /** * Constructs a <code>BootstrapException</code> with a target exception. * - * @param target the target exception + * @param target the target exception */ public BootstrapException( Exception target ) { super(); m_target = target; } - + /** * Get the thrown target exception. * @@ -87,5 +87,5 @@ public class BootstrapException extends java.lang.Exception { */ public Exception getTargetException() { return m_target; - } + } } diff --git a/javaunohelper/com/sun/star/comp/helper/ComponentContext.java b/javaunohelper/com/sun/star/comp/helper/ComponentContext.java index fe3336c1dbfb..fd4800d693b8 100644 --- a/javaunohelper/com/sun/star/comp/helper/ComponentContext.java +++ b/javaunohelper/com/sun/star/comp/helper/ComponentContext.java @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -45,7 +45,7 @@ import java.util.Vector; class Disposer implements XEventListener { private XComponent m_xComp; - + //---------------------------------------------------------------------------------------------- Disposer( XComponent xComp ) { @@ -65,19 +65,19 @@ public class ComponentContext implements XComponentContext, XComponent private static final boolean DEBUG = false; private static final String SMGR_NAME = "/singletons/com.sun.star.lang.theServiceManager"; private static final String TDMGR_NAME = "/singletons/com.sun.star.reflection.theTypeDescriptionManager"; - + private Hashtable m_table; private XComponentContext m_xDelegate; - + private XMultiComponentFactory m_xSMgr; private boolean m_bDisposeSMgr; - + private Vector m_eventListener; /** Ctor to create a component context passing a hashtable for values and a delegator reference. Entries of the passed hashtable are either direct values or ComponentContextEntry objects. - + @param table entries @param xDelegate @@ -109,7 +109,7 @@ public class ComponentContext implements XComponentContext, XComponent { m_xSMgr = m_xDelegate.getServiceManager(); } - + // listen for delegate XComponent xComp = UnoRuntime.queryInterface( XComponent.class, m_xDelegate ); @@ -118,7 +118,7 @@ public class ComponentContext implements XComponentContext, XComponent xComp.addEventListener( new Disposer( this ) ); } } - + // XComponentContext impl //______________________________________________________________________________________________ public Object getValueByName( String rName ) @@ -169,7 +169,7 @@ public class ComponentContext implements XComponentContext, XComponent if (DEBUG) System.err.println( "### exception occured on late init of singleton instance \"" + rName + "\": " + exc.getMessage() ); } - + if (xInstance != null) { synchronized (entry) @@ -218,14 +218,14 @@ public class ComponentContext implements XComponentContext, XComponent { return m_xSMgr; } - + // XComponent impl //______________________________________________________________________________________________ public void dispose() { if (DEBUG) System.err.print( "> disposing context " + this ); - + // fire events EventObject evt = new EventObject( this ); Enumeration eventListener = m_eventListener.elements(); @@ -235,7 +235,7 @@ public class ComponentContext implements XComponentContext, XComponent listener.disposing( evt ); } m_eventListener.removeAllElements(); - + XComponent tdmgr = null; // dispose values, then service manager, then typdescription manager Enumeration keys = m_table.keys(); @@ -249,7 +249,7 @@ public class ComponentContext implements XComponentContext, XComponent { o = ((ComponentContextEntry)o).m_value; } - + XComponent xComp = UnoRuntime.queryInterface( XComponent.class, o ); if (xComp != null) { @@ -265,7 +265,7 @@ public class ComponentContext implements XComponentContext, XComponent } } m_table.clear(); - + // smgr if (m_bDisposeSMgr) { @@ -277,13 +277,13 @@ public class ComponentContext implements XComponentContext, XComponent } } m_xSMgr = null; - + // tdmgr if (tdmgr != null) { tdmgr.dispose(); } - + if (DEBUG) System.err.println( "... finished" ); } @@ -293,8 +293,8 @@ public class ComponentContext implements XComponentContext, XComponent if (xListener == null) throw new com.sun.star.uno.RuntimeException( "Listener must not be null" ); if (m_eventListener.contains( xListener )) - throw new com.sun.star.uno.RuntimeException( "Listener already registred." ); - + throw new com.sun.star.uno.RuntimeException( "Listener already registred." ); + m_eventListener.addElement( xListener ); } //______________________________________________________________________________________________ @@ -303,8 +303,8 @@ public class ComponentContext implements XComponentContext, XComponent if (xListener == null) throw new com.sun.star.uno.RuntimeException( "Listener must not be null" ); if (! m_eventListener.contains( xListener )) - throw new com.sun.star.uno.RuntimeException( "Listener is not registered." ); - - m_eventListener.removeElement( xListener ); + throw new com.sun.star.uno.RuntimeException( "Listener is not registered." ); + + m_eventListener.removeElement( xListener ); } } diff --git a/javaunohelper/com/sun/star/comp/helper/ComponentContextEntry.java b/javaunohelper/com/sun/star/comp/helper/ComponentContextEntry.java index 52b116469f7a..48e999d5700f 100644 --- a/javaunohelper/com/sun/star/comp/helper/ComponentContextEntry.java +++ b/javaunohelper/com/sun/star/comp/helper/ComponentContextEntry.java @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -45,11 +45,11 @@ public class ComponentContextEntry /** set entry value */ public Object m_value; - + /** Creating a late-init singleton entry component context entry. The second parameter will be ignored and overwritten during instanciation of the singleton instance. - + @param lateInit object factory or service string @param value @@ -61,7 +61,7 @@ public class ComponentContextEntry this.m_value = value; } /** Creating a direct value component context entry. - + @param value pass null */ diff --git a/javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java b/javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java index 826c812fa049..c748187babd3 100644 --- a/javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java +++ b/javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -34,32 +34,32 @@ import com.sun.star.uno.UnoRuntime; import com.sun.star.uno.RuntimeException; /** The class provides a set of methods which create instances of the - com.sun.star.lang.RegistryServiceManager service. - + com.sun.star.lang.RegistryServiceManager service. + @deprecated use class Bootstrap instead */ public class RegistryServiceFactory { static { System.loadLibrary("juh"); } - + private static native Object createRegistryServiceFactory( - String writeRegistryFile, - String readRegistryFile, + String writeRegistryFile, + String readRegistryFile, boolean readOnly, ClassLoader loader); - + /** - * This bootstraps an initial service factory working on a registry. If the first or both + * This bootstraps an initial service factory working on a registry. If the first or both * parameters contain a value then the service factory is initialized with a simple registry * or a nested registry. Otherwise the service factory must be initialized later with a valid * registry. *<BR> - * @param writeRegistryFile file name of the simple registry or the first registry file of - * the nested registry which will be opened with read/write rights. This - * file will be created if necessary. - * @param readRegistryFile file name of the second registry file of the nested registry - * which will be opened with readonly rights. + * @param writeRegistryFile file name of the simple registry or the first registry file of + * the nested registry which will be opened with read/write rights. This + * file will be created if necessary. + * @param readRegistryFile file name of the second registry file of the nested registry + * which will be opened with readonly rights. * @return a new RegistryServiceFactory. */ public static XMultiServiceFactory create(String writeRegistryFile, String readRegistryFile) @@ -69,28 +69,28 @@ public class RegistryServiceFactory { } /** - * This bootstraps an initial service factory working on a registry. If the first or both + * This bootstraps an initial service factory working on a registry. If the first or both * parameters contain a value then the service factory is initialized with a simple registry * or a nested registry. Otherwise the service factory must be initialized later with a valid * registry. *<BR> - * @param writeRegistryFile file name of the simple registry or the first registry file of - * the nested registry which will be opened with read/write rights. This - * file will be created if necessary. - * @param readRegistryFile file name of the second registry file of the nested registry - * which will be opened with readonly rights. - * @param readOnly flag which specify that the first registry file will be opened with - * readonly rights. Default is FALSE. If this flag is used the registry - * will not be created if not exist. + * @param writeRegistryFile file name of the simple registry or the first registry file of + * the nested registry which will be opened with read/write rights. This + * file will be created if necessary. + * @param readRegistryFile file name of the second registry file of the nested registry + * which will be opened with readonly rights. + * @param readOnly flag which specify that the first registry file will be opened with + * readonly rights. Default is FALSE. If this flag is used the registry + * will not be created if not exist. * * @return a new RegistryServiceFactory */ public static XMultiServiceFactory create(String writeRegistryFile, String readRegistryFile, boolean readOnly) throws com.sun.star.uno.Exception { - // Ensure that we are on a native threads vm + // Ensure that we are on a native threads vm // (binary UNO does use native threads). - String vm_info = System.getProperty("java.vm.info"); + String vm_info = System.getProperty("java.vm.info"); if(vm_info != null && vm_info.indexOf("green") != -1) throw new RuntimeException(RegistryServiceFactory.class.toString() + ".create - can't use binary UNO with green threads"); @@ -107,7 +107,7 @@ public class RegistryServiceFactory { // } else // throw new com.sun.star.uno.Exception(writeRegistryFile + " doese not exist!"); // } - + // if (readRegistryFile != null) { // java.io.File file = new java.io.File(readRegistryFile); @@ -122,18 +122,18 @@ public class RegistryServiceFactory { writeRegistryFile, readRegistryFile, readOnly, RegistryServiceFactory.class.getClassLoader() ); return UnoRuntime.queryInterface( - XMultiServiceFactory.class, obj ); + XMultiServiceFactory.class, obj ); } /** * This bootstraps an initial service factory working on a registry file. *<BR> - * @param registryFile file name of the registry to use/ create; if this is an empty - * string, the default registry is used instead + * @param registryFile file name of the registry to use/ create; if this is an empty + * string, the default registry is used instead * * @return a new RegistryServiceFactory. */ - public static XMultiServiceFactory create(String registryFile) + public static XMultiServiceFactory create(String registryFile) throws com.sun.star.uno.Exception { return create(registryFile, null, false); @@ -142,15 +142,15 @@ public class RegistryServiceFactory { /** * This bootstraps an initial service factory working on a registry file. *<BR> - * @param registryFile file name of the registry to use/ create; if this is an empty - * string, the default registry is used instead - * @param readOnly flag which specify that the registry file will be opened with - * readonly rights. Default is FALSE. If this flag is used the registry - * will not be created if not exist. - * + * @param registryFile file name of the registry to use/ create; if this is an empty + * string, the default registry is used instead + * @param readOnly flag which specify that the registry file will be opened with + * readonly rights. Default is FALSE. If this flag is used the registry + * will not be created if not exist. + * * @return a new RegistryServiceFactory. */ - public static XMultiServiceFactory create(String registryFile, boolean readOnly) + public static XMultiServiceFactory create(String registryFile, boolean readOnly) throws com.sun.star.uno.Exception { return create(registryFile, null, readOnly); diff --git a/javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java b/javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java index e077fe6bb9bd..34d523a60516 100644 --- a/javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java +++ b/javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -34,34 +34,34 @@ import com.sun.star.registry.XRegistryKey; /** * @deprecated use class Bootstrap bootstrapping a native UNO installation * and use the shared library loader service. - * + * * The <code>SharedLibraryLoader</code> class provides the functionality of the <code>com.sun.star.loader.SharedLibrary</code> * service. * <p> * @see com.sun.star.loader.SharedLibrary * @see com.sun.star.comp.servicemanager.ServiceManager - * @see com.sun.star.lang.ServiceManager + * @see com.sun.star.lang.ServiceManager */ public class SharedLibraryLoader { - /** - * The default library which contains the SharedLibraryLoader component + /** + * The default library which contains the SharedLibraryLoader component */ public static final String DEFAULT_LIBRARY = "shlibloader.uno"; - /** + /** * The default implementation name */ public static final String DEFAULT_IMPLEMENTATION = "com.sun.star.comp.stoc.DLLComponentLoader"; - + static { System.loadLibrary("juh"); } - - private static native boolean component_writeInfo( + + private static native boolean component_writeInfo( String libName, XMultiServiceFactory smgr, XRegistryKey regKey, ClassLoader loader ); - - private static native Object component_getFactory( + + private static native Object component_getFactory( String libName, String implName, XMultiServiceFactory smgr, XRegistryKey regKey, ClassLoader loader ); @@ -71,19 +71,19 @@ public class SharedLibraryLoader { * for the library and "com.sun.star.comp.stoc.DLLComponentLoader" * for the component name. * <p> - * @return the factory for the "com.sun.star.comp.stoc.DLLComponentLoader" component. - * @param smgr the ServiceManager - * @param regKey the root registry key - * @see com.sun.star.loader.SharedLibrary - * @see com.sun.star.lang.ServiceManager - * @see com.sun.star.registry.RegistryKey + * @return the factory for the "com.sun.star.comp.stoc.DLLComponentLoader" component. + * @param smgr the ServiceManager + * @param regKey the root registry key + * @see com.sun.star.loader.SharedLibrary + * @see com.sun.star.lang.ServiceManager + * @see com.sun.star.registry.RegistryKey */ public static XSingleServiceFactory getServiceFactory( - XMultiServiceFactory smgr, + XMultiServiceFactory smgr, XRegistryKey regKey ) { return UnoRuntime.queryInterface( - XSingleServiceFactory.class, + XSingleServiceFactory.class, component_getFactory( DEFAULT_LIBRARY, DEFAULT_IMPLEMENTATION, smgr, regKey, SharedLibraryLoader.class.getClassLoader() ) ); @@ -92,40 +92,40 @@ public class SharedLibraryLoader { /** * Loads and returns a specific factory for a given library and implementation name. * <p> - * @return the factory of the component - * @param libName the name of the shared library - * @param impName the implementation name of the component - * @param smgr the ServiceManager - * @param regKey the root registry key - * @see com.sun.star.loader.SharedLibrary - * @see com.sun.star.lang.ServiceManager - * @see com.sun.star.registry.RegistryKey + * @return the factory of the component + * @param libName the name of the shared library + * @param impName the implementation name of the component + * @param smgr the ServiceManager + * @param regKey the root registry key + * @see com.sun.star.loader.SharedLibrary + * @see com.sun.star.lang.ServiceManager + * @see com.sun.star.registry.RegistryKey */ public static XSingleServiceFactory getServiceFactory( String libName, String impName, - XMultiServiceFactory smgr, + XMultiServiceFactory smgr, XRegistryKey regKey ) { return UnoRuntime.queryInterface( - XSingleServiceFactory.class, + XSingleServiceFactory.class, component_getFactory( libName, impName, smgr, regKey, SharedLibraryLoader.class.getClassLoader() ) ); } - + /** * Registers the SharedLibraryLoader under a RegistryKey. * <p> - * @return true if the registration was successfull - otherwise false - * @param smgr the ServiceManager - * @param regKey the root key under that the component should be registered - * @see com.sun.star.loader.SharedLibrary - * @see com.sun.star.lang.ServiceManager - * @see com.sun.star.registry.RegistryKey + * @return true if the registration was successfull - otherwise false + * @param smgr the ServiceManager + * @param regKey the root key under that the component should be registered + * @see com.sun.star.loader.SharedLibrary + * @see com.sun.star.lang.ServiceManager + * @see com.sun.star.registry.RegistryKey */ public static boolean writeRegistryServiceInfo( - com.sun.star.lang.XMultiServiceFactory smgr, + com.sun.star.lang.XMultiServiceFactory smgr, com.sun.star.registry.XRegistryKey regKey ) { return component_writeInfo( @@ -136,20 +136,20 @@ public class SharedLibraryLoader { /** * Registers the SharedLibraryLoader under a RegistryKey. * <p> - * @return true if the registration was successfull - otherwise false - * @param libName name of the shared library - * @param smgr the ServiceManager - * @param regKey the root key under that the component should be registered - * @see com.sun.star.loader.SharedLibrary - * @see com.sun.star.lang.ServiceManager - * @see com.sun.star.registry.RegistryKey + * @return true if the registration was successfull - otherwise false + * @param libName name of the shared library + * @param smgr the ServiceManager + * @param regKey the root key under that the component should be registered + * @see com.sun.star.loader.SharedLibrary + * @see com.sun.star.lang.ServiceManager + * @see com.sun.star.registry.RegistryKey */ public static boolean writeRegistryServiceInfo( String libName, - com.sun.star.lang.XMultiServiceFactory smgr, + com.sun.star.lang.XMultiServiceFactory smgr, com.sun.star.registry.XRegistryKey regKey ) - - throws com.sun.star.registry.InvalidRegistryException, + + throws com.sun.star.registry.InvalidRegistryException, com.sun.star.uno.RuntimeException { return component_writeInfo( diff --git a/javaunohelper/com/sun/star/comp/helper/UnoInfo.java b/javaunohelper/com/sun/star/comp/helper/UnoInfo.java index d528f433ba59..896974b9e301 100644 --- a/javaunohelper/com/sun/star/comp/helper/UnoInfo.java +++ b/javaunohelper/com/sun/star/comp/helper/UnoInfo.java @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -33,7 +33,7 @@ import java.net.URLClassLoader; /** * UnoInfo offers functionality to obtain the UNO jar files. - */ + */ public final class UnoInfo { /** @@ -45,7 +45,7 @@ public final class UnoInfo { * Gets the URL base. * * @return the URL base - */ + */ private static String getBase() { final String JUHJAR = "/juh.jar"; @@ -103,7 +103,7 @@ public final class UnoInfo { return getURLs( jarFileNames ); } - + /** * Gets the extra UNO types. * |