update dev300-m58
[ooovba.git] / udkapi / com / sun / star / lang / ServiceManager.idl
blob7c888e83147eb919a8d606132596509df6ef826e
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: ServiceManager.idl,v $
10 * $Revision: 1.16 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef __com_sun_star_lang_ServiceManager_idl__
31 #define __com_sun_star_lang_ServiceManager_idl__
33 #ifndef __com_sun_star_lang_MultiServiceFactory_idl__
34 #include <com/sun/star/lang/MultiServiceFactory.idl>
35 #endif
37 #ifndef __com_sun_star_lang_XComponent_idl__
38 #include <com/sun/star/lang/XComponent.idl>
39 #endif
41 #ifndef __com_sun_star_container_XSet_idl__
42 #include <com/sun/star/container/XSet.idl>
43 #endif
45 #ifndef __com_sun_star_container_XContentEnumerationAccess_idl__
46 #include <com/sun/star/container/XContentEnumerationAccess.idl>
47 #endif
49 #ifndef __com_sun_star_lang_XMultiServiceFactory_idl__
50 #include <com/sun/star/lang/XMultiServiceFactory.idl>
51 #endif
53 #ifndef __com_sun_star_lang_XMultiComponentFactory_idl__
54 #include <com/sun/star/lang/XMultiComponentFactory.idl>
55 #endif
57 #ifndef __com_sun_star_lang_XServiceInfo_idl__
58 #include <com/sun/star/lang/XServiceInfo.idl>
59 #endif
61 #ifndef __com_sun_star_beans_XPropertySet_idl__
62 #include <com/sun/star/beans/XPropertySet.idl>
63 #endif
65 //=============================================================================
67 module com { module sun { module star { module lang {
69 //=============================================================================
71 /** Provides a collection of implementations for services. This is a singleton
72 you commonly find in your component context under key
73 <code>/singletons/com.sun.star.lang.theServiceManager</code>.
75 <p>
76 The factories are accessed with a service name. It is possible to
77 access the factories with their implementation names, but you should
78 avoid this.
79 </p>
81 <p>Service factories added via <type scope="com::sun::star::container">XSet</type>
82 should support the following interfaces: </p>
84 <dl>
85 <dt><type>XServiceInfo</type></dt>
86 <dd>supported interfaces/ implementation name</dd>
88 <dt><type>XSingleComponentFactory</type>(optional)</dt>
89 <dd>is used to create instances of the implementation.</dd>
91 <dt><type>XComponent</type> (optional)</dt>
92 <dd>The service manager calls the method
93 <member scope="com::sun::star::lang">XComponent::dispose</member>
94 on the factory when going down (i.e. it is commonly disposed by the component context).</dd>
95 </dl>
97 @see com::sun::star::uno::XComponentContext
99 published service ServiceManager
101 /** This is a derived MultiServiceFactory service.
103 service com::sun::star::lang::MultiServiceFactory;
105 /** Disposing of service manager.
107 The component context disposes its service manager singleton when going down
108 (i.e. when the component context is disposed).
109 </p>
111 interface com::sun::star::lang::XComponent;
113 /** Management of service factories.
115 interface com::sun::star::container::XSet;
117 /** Enumeration of all service factories.
119 It is possible to enumerate all implementations that support the
120 service specified with the argument of the
121 <member scope="com::sun::star::container">XContentEnumerationAccess::createContentEnumeration</member> method.
122 The enumerator commonly returns <type>XSingleComponentFactory</type>
123 interfaces.
124 </p>
126 interface com::sun::star::container::XContentEnumerationAccess;
128 /** Property access.
130 [optional] interface com::sun::star::beans::XPropertySet;
131 /** specifies the default component context to be used, if instanciating services
132 via <type>XMultiServiceFactory</type>
134 [optional, property] com::sun::star::uno::XComponentContext DefaultContext;
137 //=============================================================================
139 }; }; }; };
141 /*=============================================================================
143 =============================================================================*/
144 #endif