1*e6ed5fbcSAndrew Rist /************************************************************** 2cdf0e10cSrcweir * 3*e6ed5fbcSAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4*e6ed5fbcSAndrew Rist * or more contributor license agreements. See the NOTICE file 5*e6ed5fbcSAndrew Rist * distributed with this work for additional information 6*e6ed5fbcSAndrew Rist * regarding copyright ownership. The ASF licenses this file 7*e6ed5fbcSAndrew Rist * to you under the Apache License, Version 2.0 (the 8*e6ed5fbcSAndrew Rist * "License"); you may not use this file except in compliance 9*e6ed5fbcSAndrew Rist * with the License. You may obtain a copy of the License at 10*e6ed5fbcSAndrew Rist * 11*e6ed5fbcSAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12*e6ed5fbcSAndrew Rist * 13*e6ed5fbcSAndrew Rist * Unless required by applicable law or agreed to in writing, 14*e6ed5fbcSAndrew Rist * software distributed under the License is distributed on an 15*e6ed5fbcSAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*e6ed5fbcSAndrew Rist * KIND, either express or implied. See the License for the 17*e6ed5fbcSAndrew Rist * specific language governing permissions and limitations 18*e6ed5fbcSAndrew Rist * under the License. 19*e6ed5fbcSAndrew Rist * 20*e6ed5fbcSAndrew Rist *************************************************************/ 21*e6ed5fbcSAndrew Rist 22*e6ed5fbcSAndrew Rist 23cdf0e10cSrcweir #include "cppuhelper/implementationentry.hxx" 24cdf0e10cSrcweir #include "com/sun/star/lang/XMultiServiceFactory.hpp" 25cdf0e10cSrcweir #include "com/sun/star/registry/XRegistryKey.hpp" 26cdf0e10cSrcweir #include "comphelper/servicedecl.hxx" 27cdf0e10cSrcweir 28cdf0e10cSrcweir // ============================================================================= 29cdf0e10cSrcweir // component exports 30cdf0e10cSrcweir // ============================================================================= 31cdf0e10cSrcweir using namespace ::com::sun::star; 32cdf0e10cSrcweir using namespace ::com::sun::star::uno; 33cdf0e10cSrcweir 34cdf0e10cSrcweir namespace sdecl = comphelper::service_decl; 35cdf0e10cSrcweir 36cdf0e10cSrcweir // reference service helper(s) 37cdf0e10cSrcweir namespace controlprovider 38cdf0e10cSrcweir { 39cdf0e10cSrcweir extern sdecl::ServiceDecl const serviceDecl; 40cdf0e10cSrcweir } 41cdf0e10cSrcweir 42cdf0e10cSrcweir namespace userform 43cdf0e10cSrcweir { 44cdf0e10cSrcweir extern sdecl::ServiceDecl const serviceDecl; 45cdf0e10cSrcweir } 46cdf0e10cSrcweir 47cdf0e10cSrcweir extern "C" 48cdf0e10cSrcweir { component_getImplementationEnvironment(const sal_Char ** ppEnvTypeName,uno_Environment **)49cdf0e10cSrcweir SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment( 50cdf0e10cSrcweir const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ ) 51cdf0e10cSrcweir { 52cdf0e10cSrcweir OSL_TRACE("In component_getImplementationEnv"); 53cdf0e10cSrcweir *ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME; 54cdf0e10cSrcweir } 55cdf0e10cSrcweir component_getFactory(const sal_Char * pImplName,lang::XMultiServiceFactory * pServiceManager,registry::XRegistryKey * pRegistryKey)56cdf0e10cSrcweir SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory( 57cdf0e10cSrcweir const sal_Char * pImplName, lang::XMultiServiceFactory * pServiceManager, 58cdf0e10cSrcweir registry::XRegistryKey * pRegistryKey ) 59cdf0e10cSrcweir { 60cdf0e10cSrcweir OSL_TRACE("In component_getFactory for %s", pImplName ); 61cdf0e10cSrcweir void* pRet = component_getFactoryHelper( 62cdf0e10cSrcweir pImplName, pServiceManager, pRegistryKey, controlprovider::serviceDecl, userform::serviceDecl ); 63cdf0e10cSrcweir OSL_TRACE("Ret is 0x%x", pRet); 64cdf0e10cSrcweir return pRet; 65cdf0e10cSrcweir } 66cdf0e10cSrcweir } 67