Commits

Anonymous committed 0713676

#i107512# let the singleton be registered

  • Participants
  • Parent commits f3d0513

Comments (0)

Files changed (3)

comphelper/source/misc/comphelper_services.cxx

 extern void createRegistryInfo_OfficeInstallationDirectories();
 extern void createRegistryInfo_OInstanceLocker();
 extern void createRegistryInfo_Map();
+extern void createRegistryInfo_OSimpleLogRing();
 
 //........................................................................
 namespace comphelper { namespace module
                 createRegistryInfo_OfficeInstallationDirectories();
                 createRegistryInfo_OInstanceLocker();
                 createRegistryInfo_Map();
+                createRegistryInfo_OSimpleLogRing();
             }
         }
     }

comphelper/source/misc/documentiologring.cxx

 #include <com/sun/star/frame/DoubleInitializationException.hpp>
 #include <com/sun/star/lang/IllegalArgumentException.hpp>
 
+#include <comphelper_module.hxx>
+
 #include "documentiologring.hxx"
 
 using namespace ::com::sun::star;
 }
 
 // ----------------------------------------------------------
-uno::Sequence< ::rtl::OUString > SAL_CALL OSimpleLogRing::impl_staticGetSupportedServiceNames()
+uno::Sequence< ::rtl::OUString > SAL_CALL OSimpleLogRing::getSupportedServiceNames_static()
 {
     uno::Sequence< rtl::OUString > aResult( 1 );
-    aResult[0] = impl_staticGetServiceName();
+    aResult[0] = getServiceName_static();
     return aResult;
 }
 
 // ----------------------------------------------------------
-::rtl::OUString SAL_CALL OSimpleLogRing::impl_staticGetImplementationName()
+::rtl::OUString SAL_CALL OSimpleLogRing::getImplementationName_static()
 {
     return rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.logging.SimpleLogRing" ) );
 }
 
 // ----------------------------------------------------------
-::rtl::OUString SAL_CALL OSimpleLogRing::impl_staticGetSingletonName()
+::rtl::OUString SAL_CALL OSimpleLogRing::getSingletonName_static()
 {
     return rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.logging.DocumentIOLogRing" ) );
 }
 
 // ----------------------------------------------------------
-::rtl::OUString SAL_CALL OSimpleLogRing::impl_staticGetServiceName()
+::rtl::OUString SAL_CALL OSimpleLogRing::getServiceName_static()
 {
     return rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.logging.SimpleLogRing" ) );
 }
 
 // ----------------------------------------------------------
-uno::Reference< uno::XInterface > SAL_CALL OSimpleLogRing::impl_staticCreateSelfInstance( const uno::Reference< uno::XComponentContext >& rxContext )
+uno::Reference< uno::XInterface > SAL_CALL OSimpleLogRing::Create( const uno::Reference< uno::XComponentContext >& rxContext )
 {
     return static_cast< cppu::OWeakObject* >( new OSimpleLogRing( rxContext ) );
 }
 // ----------------------------------------------------------
 ::rtl::OUString SAL_CALL OSimpleLogRing::getImplementationName() throw (uno::RuntimeException)
 {
-    return impl_staticGetImplementationName();
+    return getImplementationName_static();
 }
 
 // ----------------------------------------------------------
 ::sal_Bool SAL_CALL OSimpleLogRing::supportsService( const ::rtl::OUString& aServiceName ) throw (uno::RuntimeException)
 {
-    const uno::Sequence< rtl::OUString > & aSupportedNames = impl_staticGetSupportedServiceNames();
+    const uno::Sequence< rtl::OUString > & aSupportedNames = getSupportedServiceNames_static();
     for ( sal_Int32 nInd = 0; nInd < aSupportedNames.getLength(); nInd++ )
     {
         if ( aSupportedNames[ nInd ].equals( aServiceName ) )
 // ----------------------------------------------------------
 uno::Sequence< ::rtl::OUString > SAL_CALL OSimpleLogRing::getSupportedServiceNames() throw (uno::RuntimeException)
 {
-    return impl_staticGetSupportedServiceNames();
+    return getSupportedServiceNames_static();
 }
 
 } // namespace comphelper
 
+void createRegistryInfo_OSimpleLogRing()
+{
+    static ::comphelper::module::OAutoRegistration< ::comphelper::OSimpleLogRing > aAutoRegistration;
+    static ::comphelper::module::OSingletonRegistration< ::comphelper::OSimpleLogRing > aSingletonRegistration;
+}

comphelper/source/misc/documentiologring.hxx

 	virtual ~OSimpleLogRing();
 
 	static ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL
-			impl_staticGetSupportedServiceNames();
+			getSupportedServiceNames_static();
 
-	static ::rtl::OUString SAL_CALL impl_staticGetImplementationName();
+	static ::rtl::OUString SAL_CALL getImplementationName_static();
 
-	static ::rtl::OUString SAL_CALL impl_staticGetSingletonName();
+	static ::rtl::OUString SAL_CALL getSingletonName_static();
 
-	static ::rtl::OUString SAL_CALL impl_staticGetServiceName();
+	static ::rtl::OUString SAL_CALL getServiceName_static();
 
 	static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > SAL_CALL
-		impl_staticCreateSelfInstance( 
-			const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
+		Create( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
 
 // XSimpleLogRing
     virtual void SAL_CALL logString( const ::rtl::OUString& aMessage ) throw (::com::sun::star::uno::RuntimeException);