diff options
Diffstat (limited to 'odk/examples/DevelopersGuide/Components/SimpleLicense/LicenseTest.java')
-rw-r--r-- | odk/examples/DevelopersGuide/Components/SimpleLicense/LicenseTest.java | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/odk/examples/DevelopersGuide/Components/SimpleLicense/LicenseTest.java b/odk/examples/DevelopersGuide/Components/SimpleLicense/LicenseTest.java index 211638c46c58..37ad00c593a6 100644 --- a/odk/examples/DevelopersGuide/Components/SimpleLicense/LicenseTest.java +++ b/odk/examples/DevelopersGuide/Components/SimpleLicense/LicenseTest.java @@ -2,7 +2,7 @@ * * The Contents of this file are made available subject to the terms of * the BSD license. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * All rights reserved. * @@ -29,7 +29,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR * TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * *************************************************************************/ import com.sun.star.lib.uno.helper.Factory; @@ -59,7 +59,7 @@ public class LicenseTest { */ static private final String __serviceName = "org.openoffice.LicenseTest"; - + /** The initial component contextr, that gives access to * the service manager, supported singletons, ... * It's often later used @@ -70,7 +70,7 @@ public class LicenseTest { * It's often later used */ private XMultiComponentFactory m_xMCF; - + /** The constructor of the inner class has a XMultiServiceFactory parameter. * @param xmultiservicefactoryInitialization A special service factory * could be introduced while initializing. @@ -78,13 +78,13 @@ public class LicenseTest { public _LicenseTest(XComponentContext xCompContext) { try { m_cmpCtx = xCompContext; - m_xMCF = m_cmpCtx.getServiceManager(); + m_xMCF = m_cmpCtx.getServiceManager(); } catch( Exception e ) { e.printStackTrace(); } } - + /** This method returns an array of all supported service names. * @return Array of supported service names. */ @@ -100,7 +100,7 @@ public class LicenseTest { String[] sSupportedServiceNames = { __serviceName }; return sSupportedServiceNames; } - + /** This method returns true, if the given service will be * supported by the component. * @param sServiceName Service name. @@ -109,16 +109,16 @@ public class LicenseTest { public boolean supportsService( String sServiceName ) { return sServiceName.equals( __serviceName ); } - + /** Return the class name of the component. * @return Class name of the component. */ public String getImplementationName() { return _LicenseTest.class.getName(); - } + } } - - + + /** * Gives a factory for creating the service. * This method is called by the <code>JavaLoader</code> @@ -132,11 +132,11 @@ public class LicenseTest { public static XSingleComponentFactory __getComponentFactory(String sImplName) { XSingleComponentFactory xFactory = null; - + if ( sImplName.equals( _LicenseTest.class.getName() ) ) xFactory = Factory.createComponentFactory(_LicenseTest.class, _LicenseTest.getServiceNames()); - + return xFactory; } @@ -167,5 +167,5 @@ public class LicenseTest { * your component using these objects. */ } - + } |