19 #ifndef INCLUDED_COMPHELPER_SERVICEDECL_HXX
20 #define INCLUDED_COMPHELPER_SERVICEDECL_HXX
24 #include <com/sun/star/uno/XComponentContext.hpp>
25 #include <com/sun/star/lang/XServiceInfo.hpp>
28 #include <initializer_list>
35 typedef ::std::function<
36 css::uno::Reference<css::uno::XInterface>
38 css::uno::Sequence<css::uno::Any>
const&,
39 css::uno::Reference<css::uno::XComponentContext>
const&)>
CreateFuncF;
107 template <
typename ImplClassT>
109 char const* pImplName,
110 char const* pSupportedServiceNames )
111 : m_createFunc(implClass.m_createFunc),
112 m_pImplName(pImplName),
113 m_pServiceNames(pSupportedServiceNames) {}
116 void * getFactory(
char const* pImplName )
const;
149 std::initializer_list<ServiceDecl const *> args );
154 #endif // ! defined( INCLUDED_COMPHELPER_SERVICEDECL_HXX)
detail::CreateFuncF const m_createFunc
css::uno::Sequence< OUString > getSupportedServiceNames()
OUString getImplementationName()
Class to declare a service implementation.
::std::function< css::uno::Reference< css::uno::XInterface >(ServiceDecl const &, css::uno::Sequence< css::uno::Any > const &, css::uno::Reference< css::uno::XComponentContext > const &)> CreateFuncF
To specify whether the implementation class expects arguments (uno::Sequence).
bool CPPUHELPER_DLLPUBLIC supportsService(css::lang::XServiceInfo *implementation, rtl::OUString const &name)
ServiceDecl(ImplClassT const &implClass, char const *pImplName, char const *pSupportedServiceNames)
void * component_getFactoryHelper(const char *pImplName, std::initializer_list< ServiceDecl const * > args)
char const *const m_pImplName
char const *const m_pServiceNames
#define COMPHELPER_DLLPUBLIC