xref: /trunk/main/cui/source/uno/services/services.cxx (revision 79aad27f)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 // MARKER(update_precomp.py): autogen include statement, do not remove
23 #include "precompiled_cui.hxx"
24 
25 #include <com/sun/star/registry/XRegistryKey.hpp>
26 #include "sal/types.h"
27 #include "cppuhelper/factory.hxx"
28 #include <cppuhelper/implementationentry.hxx>
29 
30 using rtl::OUString;
31 using namespace com::sun::star;
32 
33 namespace cui {
34 extern rtl::OUString SAL_CALL ColorPicker_getImplementationName();
35 extern uno::Reference< uno::XInterface > SAL_CALL ColorPicker_createInstance( uno::Reference< uno::XComponentContext > const & ) SAL_THROW( (uno::Exception) );
36 extern uno::Sequence< rtl::OUString > SAL_CALL ColorPicker_getSupportedServiceNames() throw( uno::RuntimeException );
37 }
38 
39 namespace
40 {
41 
42     cppu::ImplementationEntry entries[] = {
43         { &::cui::ColorPicker_createInstance, &::cui::ColorPicker_getImplementationName, &::cui::ColorPicker_getSupportedServiceNames, &cppu::createSingleComponentFactory, 0, 0 },
44         { 0, 0, 0, 0, 0, 0 }
45     };
46 }
47 
component_getFactory(char const * implName,void * serviceManager,void * registryKey)48 extern "C" SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory( char const * implName, void * serviceManager, void * registryKey)
49 {
50     return cppu::component_getFactoryHelper(implName, serviceManager, registryKey, entries);
51 }
52 
53 
component_getImplementationEnvironment(const sal_Char ** ppEnvTypeName,uno_Environment **)54 extern "C" SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment ( const sal_Char ** ppEnvTypeName, uno_Environment ** )
55 {
56     *ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
57 }
58 
59 // eof
60