LCOV - code coverage report
Current view: top level - workdir/unxlngi6.pro/UnoApiHeadersTarget/udkapi/comprehensive/com/sun/star/container - XNameReplace.hpp (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 49 49 100.0 %
Date: 2012-08-25 Functions: 2 2 100.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 22 44 50.0 %

           Branch data     Line data    Source code
       1                 :            : #ifndef INCLUDED_COM_SUN_STAR_CONTAINER_XNAMEREPLACE_HPP
       2                 :            : #define INCLUDED_COM_SUN_STAR_CONTAINER_XNAMEREPLACE_HPP
       3                 :            : 
       4                 :            : #include "sal/config.h"
       5                 :            : 
       6                 :            : #include "com/sun/star/container/XNameReplace.hdl"
       7                 :            : 
       8                 :            : #include "com/sun/star/uno/RuntimeException.hpp"
       9                 :            : #include "com/sun/star/lang/WrappedTargetException.hpp"
      10                 :            : #include "com/sun/star/container/NoSuchElementException.hpp"
      11                 :            : #include "com/sun/star/lang/IllegalArgumentException.hpp"
      12                 :            : #include "com/sun/star/container/XNameAccess.hpp"
      13                 :            : #include "com/sun/star/uno/Any.hxx"
      14                 :            : #include "com/sun/star/uno/Reference.hxx"
      15                 :            : #include "com/sun/star/uno/Type.hxx"
      16                 :            : #include "cppu/unotype.hxx"
      17                 :            : #include "osl/mutex.hxx"
      18                 :            : #include "rtl/ustring.hxx"
      19                 :            : #include "rtl/instance.hxx"
      20                 :            : 
      21                 :            : namespace com { namespace sun { namespace star { namespace container { namespace detail {
      22                 :            : 
      23                 :            : struct theXNameReplaceType : public rtl::StaticWithInit< ::com::sun::star::uno::Type *, theXNameReplaceType >
      24                 :            : {
      25                 :        348 :     ::com::sun::star::uno::Type * operator()() const
      26                 :            :     {
      27         [ +  - ]:        348 :         ::rtl::OUString sTypeName( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.container.XNameReplace") );
      28                 :            : 
      29                 :            :         // Start inline typedescription generation
      30                 :        348 :         typelib_InterfaceTypeDescription * pTD = 0;
      31                 :            : 
      32                 :            :         typelib_TypeDescriptionReference * aSuperTypes[1];
      33         [ +  - ]:        348 :         aSuperTypes[0] = ::cppu::UnoType< ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > >::get().getTypeLibType();
      34                 :        348 :         typelib_TypeDescriptionReference * pMembers[1] = { 0 };
      35         [ +  - ]:        348 :         ::rtl::OUString sMethodName0( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.container.XNameReplace::replaceByName") );
      36                 :            :         typelib_typedescriptionreference_new( &pMembers[0],
      37                 :            :                                               (typelib_TypeClass)::com::sun::star::uno::TypeClass_INTERFACE_METHOD,
      38                 :        348 :                                               sMethodName0.pData );
      39                 :            : 
      40                 :            :         typelib_typedescription_newMIInterface(
      41                 :            :             &pTD,
      42                 :            :             sTypeName.pData, 0x00000000, 0x0000, 0x0000, 0x00000000, 0x00000000,
      43                 :            :             1, aSuperTypes,
      44                 :            :             1,
      45                 :        348 :             pMembers );
      46                 :            : 
      47                 :        348 :         typelib_typedescription_register( (typelib_TypeDescription**)&pTD );
      48                 :        348 :         typelib_typedescriptionreference_release( pMembers[0] );
      49                 :        348 :         typelib_typedescription_release( (typelib_TypeDescription*)pTD );
      50                 :            : 
      51                 :        348 :         return new ::com::sun::star::uno::Type( ::com::sun::star::uno::TypeClass_INTERFACE, sTypeName ); // leaked
      52                 :            :     }
      53                 :            : };
      54                 :            : 
      55                 :            : } } } } }
      56                 :            : 
      57                 :            : namespace com { namespace sun { namespace star { namespace container {
      58                 :            : 
      59                 :        348 : inline ::com::sun::star::uno::Type const & cppu_detail_getUnoType(SAL_UNUSED_PARAMETER ::com::sun::star::container::XNameReplace const *) {
      60                 :        348 :     const ::com::sun::star::uno::Type &rRet = *detail::theXNameReplaceType::get();
      61                 :            :     // End inline typedescription generation
      62                 :            :     static bool bInitStarted = false;
      63         [ +  - ]:        348 :     if (!bInitStarted)
      64                 :            :     {
      65 [ +  - ][ +  - ]:        348 :         ::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
      66         [ +  - ]:        348 :         if (!bInitStarted)
      67                 :            :         {
      68                 :            :             OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
      69                 :        348 :             bInitStarted = true;
      70         [ +  - ]:        348 :             ::cppu::UnoType< ::com::sun::star::uno::RuntimeException >::get();
      71         [ +  - ]:        348 :             ::cppu::UnoType< ::com::sun::star::lang::IllegalArgumentException >::get();
      72         [ +  - ]:        348 :             ::cppu::UnoType< ::com::sun::star::container::NoSuchElementException >::get();
      73         [ +  - ]:        348 :             ::cppu::UnoType< ::com::sun::star::lang::WrappedTargetException >::get();
      74                 :            : 
      75                 :        348 :             typelib_InterfaceMethodTypeDescription * pMethod = 0;
      76                 :            :             {
      77                 :            :                 typelib_Parameter_Init aParameters[2];
      78         [ +  - ]:        348 :                 ::rtl::OUString sParamName0( RTL_CONSTASCII_USTRINGPARAM("aName") );
      79         [ +  - ]:        348 :                 ::rtl::OUString sParamType0( RTL_CONSTASCII_USTRINGPARAM("string") );
      80                 :        348 :                 aParameters[0].pParamName = sParamName0.pData;
      81                 :        348 :                 aParameters[0].eTypeClass = (typelib_TypeClass)::com::sun::star::uno::TypeClass_STRING;
      82                 :        348 :                 aParameters[0].pTypeName = sParamType0.pData;
      83                 :        348 :                 aParameters[0].bIn = sal_True;
      84                 :        348 :                 aParameters[0].bOut = sal_False;
      85         [ +  - ]:        348 :                 ::rtl::OUString sParamName1( RTL_CONSTASCII_USTRINGPARAM("aElement") );
      86         [ +  - ]:        348 :                 ::rtl::OUString sParamType1( RTL_CONSTASCII_USTRINGPARAM("any") );
      87                 :        348 :                 aParameters[1].pParamName = sParamName1.pData;
      88                 :        348 :                 aParameters[1].eTypeClass = (typelib_TypeClass)::com::sun::star::uno::TypeClass_ANY;
      89                 :        348 :                 aParameters[1].pTypeName = sParamType1.pData;
      90                 :        348 :                 aParameters[1].bIn = sal_True;
      91                 :        348 :                 aParameters[1].bOut = sal_False;
      92         [ +  - ]:        348 :                 ::rtl::OUString the_ExceptionName0(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.lang.IllegalArgumentException"));
      93         [ +  - ]:        348 :                 ::rtl::OUString the_ExceptionName1(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.container.NoSuchElementException"));
      94         [ +  - ]:        348 :                 ::rtl::OUString the_ExceptionName2(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.lang.WrappedTargetException"));
      95         [ +  - ]:        348 :                 ::rtl::OUString the_ExceptionName3(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.uno.RuntimeException"));
      96                 :        348 :                 rtl_uString * the_Exceptions[] = { the_ExceptionName0.pData, the_ExceptionName1.pData, the_ExceptionName2.pData, the_ExceptionName3.pData };
      97         [ +  - ]:        348 :                 ::rtl::OUString sReturnType0( RTL_CONSTASCII_USTRINGPARAM("void") );
      98         [ +  - ]:        348 :                 ::rtl::OUString sMethodName0( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.container.XNameReplace::replaceByName") );
      99                 :            :                 typelib_typedescription_newInterfaceMethod( &pMethod,
     100                 :            :                     8, sal_False,
     101                 :            :                     sMethodName0.pData,
     102                 :            :                     (typelib_TypeClass)::com::sun::star::uno::TypeClass_VOID, sReturnType0.pData,
     103                 :            :                     2, aParameters,
     104                 :        348 :                     4, the_Exceptions );
     105                 :        348 :                 typelib_typedescription_register( (typelib_TypeDescription**)&pMethod );
     106                 :            :             }
     107                 :        348 :             typelib_typedescription_release( (typelib_TypeDescription*)pMethod );
     108         [ +  - ]:        348 :         }
     109                 :            :     }
     110                 :            :     else
     111                 :            :     {
     112                 :            :         OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
     113                 :            :     }
     114                 :        348 :     return rRet;
     115                 :            : }
     116                 :            : 
     117                 :            : } } } }
     118                 :            : 
     119                 :            : inline ::com::sun::star::uno::Type const & SAL_CALL getCppuType(SAL_UNUSED_PARAMETER ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace > const *) SAL_THROW(()) {
     120                 :            :     return ::cppu::UnoType< ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace > >::get();
     121                 :            : }
     122                 :            : 
     123                 :            : ::com::sun::star::uno::Type const & ::com::sun::star::container::XNameReplace::static_type(SAL_UNUSED_PARAMETER void *) {
     124                 :            :     return ::getCppuType(static_cast< ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace > * >(0));
     125                 :            : }
     126                 :            : 
     127                 :            : #endif // INCLUDED_COM_SUN_STAR_CONTAINER_XNAMEREPLACE_HPP

Generated by: LCOV version 1.10