LCOV - code coverage report
Current view: top level - libreoffice/workdir/unxlngi6.pro/UnoApiHeadersTarget/udkapi/comprehensive/com/sun/star/beans - XPropertySetInfo.hpp (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 69 69 100.0 %
Date: 2012-12-27 Functions: 4 4 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : #ifndef INCLUDED_COM_SUN_STAR_BEANS_XPROPERTYSETINFO_HPP
       2             : #define INCLUDED_COM_SUN_STAR_BEANS_XPROPERTYSETINFO_HPP
       3             : 
       4             : #include "sal/config.h"
       5             : 
       6             : #include "com/sun/star/beans/XPropertySetInfo.hdl"
       7             : 
       8             : #include "com/sun/star/uno/XInterface.hpp"
       9             : #include "com/sun/star/uno/RuntimeException.hpp"
      10             : #include "com/sun/star/beans/UnknownPropertyException.hpp"
      11             : #include "com/sun/star/beans/Property.hpp"
      12             : #include "com/sun/star/uno/Reference.hxx"
      13             : #include "com/sun/star/uno/Sequence.hxx"
      14             : #include "com/sun/star/uno/Type.hxx"
      15             : #include "cppu/unotype.hxx"
      16             : #include "osl/mutex.hxx"
      17             : #include "rtl/ustring.hxx"
      18             : #include "rtl/instance.hxx"
      19             : #include "sal/types.h"
      20             : 
      21             : namespace com { namespace sun { namespace star { namespace beans { namespace detail {
      22             : 
      23             : struct theXPropertySetInfoType : public rtl::StaticWithInit< ::com::sun::star::uno::Type *, theXPropertySetInfoType >
      24             : {
      25         263 :     ::com::sun::star::uno::Type * operator()() const
      26             :     {
      27         263 :         ::rtl::OUString sTypeName( "com.sun.star.beans.XPropertySetInfo" );
      28             : 
      29             :         // Start inline typedescription generation
      30         263 :         typelib_InterfaceTypeDescription * pTD = 0;
      31             : 
      32             :         typelib_TypeDescriptionReference * aSuperTypes[1];
      33         263 :         aSuperTypes[0] = ::cppu::UnoType< ::com::sun::star::uno::Reference< css::uno::XInterface > >::get().getTypeLibType();
      34         263 :         typelib_TypeDescriptionReference * pMembers[3] = { 0,0,0 };
      35         263 :         ::rtl::OUString sMethodName0( "com.sun.star.beans.XPropertySetInfo::getProperties" );
      36             :         typelib_typedescriptionreference_new( &pMembers[0],
      37             :                                               (typelib_TypeClass)::com::sun::star::uno::TypeClass_INTERFACE_METHOD,
      38         263 :                                               sMethodName0.pData );
      39         263 :         ::rtl::OUString sMethodName1( "com.sun.star.beans.XPropertySetInfo::getPropertyByName" );
      40             :         typelib_typedescriptionreference_new( &pMembers[1],
      41             :                                               (typelib_TypeClass)::com::sun::star::uno::TypeClass_INTERFACE_METHOD,
      42         263 :                                               sMethodName1.pData );
      43         263 :         ::rtl::OUString sMethodName2( "com.sun.star.beans.XPropertySetInfo::hasPropertyByName" );
      44             :         typelib_typedescriptionreference_new( &pMembers[2],
      45             :                                               (typelib_TypeClass)::com::sun::star::uno::TypeClass_INTERFACE_METHOD,
      46         263 :                                               sMethodName2.pData );
      47             : 
      48             :         typelib_typedescription_newMIInterface(
      49             :             &pTD,
      50             :             sTypeName.pData, 0x00000000, 0x0000, 0x0000, 0x00000000, 0x00000000,
      51             :             1, aSuperTypes,
      52             :             3,
      53         263 :             pMembers );
      54             : 
      55         263 :         typelib_typedescription_register( (typelib_TypeDescription**)&pTD );
      56         263 :         typelib_typedescriptionreference_release( pMembers[0] );
      57         263 :         typelib_typedescriptionreference_release( pMembers[1] );
      58         263 :         typelib_typedescriptionreference_release( pMembers[2] );
      59         263 :         typelib_typedescription_release( (typelib_TypeDescription*)pTD );
      60             : 
      61         263 :         return new ::com::sun::star::uno::Type( ::com::sun::star::uno::TypeClass_INTERFACE, sTypeName ); // leaked
      62             :     }
      63             : };
      64             : 
      65             : } } } } }
      66             : 
      67             : namespace com { namespace sun { namespace star { namespace beans {
      68             : 
      69         531 : inline ::com::sun::star::uno::Type const & cppu_detail_getUnoType(SAL_UNUSED_PARAMETER css::beans::XPropertySetInfo const *) {
      70         531 :     const ::com::sun::star::uno::Type &rRet = *detail::theXPropertySetInfoType::get();
      71             :     // End inline typedescription generation
      72             :     static bool bInitStarted = false;
      73         531 :     if (!bInitStarted)
      74             :     {
      75         263 :         ::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
      76         263 :         if (!bInitStarted)
      77             :         {
      78             :             OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
      79         263 :             bInitStarted = true;
      80         263 :             ::cppu::UnoType< css::uno::RuntimeException >::get();
      81         263 :             ::cppu::UnoType< ::cppu::UnoSequenceType< css::beans::Property > >::get();
      82         263 :             ::cppu::UnoType< css::beans::Property >::get();
      83         263 :             ::cppu::UnoType< css::beans::UnknownPropertyException >::get();
      84             : 
      85         263 :             typelib_InterfaceMethodTypeDescription * pMethod = 0;
      86             :             {
      87         263 :                 ::rtl::OUString the_ExceptionName0( "com.sun.star.uno.RuntimeException" );
      88         263 :                 rtl_uString * the_Exceptions[] = { the_ExceptionName0.pData };
      89         263 :                 ::rtl::OUString sReturnType0( "[]com.sun.star.beans.Property" );
      90         263 :                 ::rtl::OUString sMethodName0( "com.sun.star.beans.XPropertySetInfo::getProperties" );
      91             :                 typelib_typedescription_newInterfaceMethod( &pMethod,
      92             :                     3, sal_False,
      93             :                     sMethodName0.pData,
      94             :                     (typelib_TypeClass)::com::sun::star::uno::TypeClass_SEQUENCE, sReturnType0.pData,
      95             :                     0, 0,
      96         263 :                     1, the_Exceptions );
      97         263 :                 typelib_typedescription_register( (typelib_TypeDescription**)&pMethod );
      98             :             }
      99             :             {
     100             :                 typelib_Parameter_Init aParameters[1];
     101         263 :                 ::rtl::OUString sParamName0( "aName" );
     102         263 :                 ::rtl::OUString sParamType0( "string" );
     103         263 :                 aParameters[0].pParamName = sParamName0.pData;
     104         263 :                 aParameters[0].eTypeClass = (typelib_TypeClass)::com::sun::star::uno::TypeClass_STRING;
     105         263 :                 aParameters[0].pTypeName = sParamType0.pData;
     106         263 :                 aParameters[0].bIn = sal_True;
     107         263 :                 aParameters[0].bOut = sal_False;
     108         263 :                 ::rtl::OUString the_ExceptionName0( "com.sun.star.beans.UnknownPropertyException" );
     109         263 :                 ::rtl::OUString the_ExceptionName1( "com.sun.star.uno.RuntimeException" );
     110         263 :                 rtl_uString * the_Exceptions[] = { the_ExceptionName0.pData, the_ExceptionName1.pData };
     111         263 :                 ::rtl::OUString sReturnType1( "com.sun.star.beans.Property" );
     112         263 :                 ::rtl::OUString sMethodName1( "com.sun.star.beans.XPropertySetInfo::getPropertyByName" );
     113             :                 typelib_typedescription_newInterfaceMethod( &pMethod,
     114             :                     4, sal_False,
     115             :                     sMethodName1.pData,
     116             :                     (typelib_TypeClass)::com::sun::star::uno::TypeClass_STRUCT, sReturnType1.pData,
     117             :                     1, aParameters,
     118         263 :                     2, the_Exceptions );
     119         263 :                 typelib_typedescription_register( (typelib_TypeDescription**)&pMethod );
     120             :             }
     121             :             {
     122             :                 typelib_Parameter_Init aParameters[1];
     123         263 :                 ::rtl::OUString sParamName0( "Name" );
     124         263 :                 ::rtl::OUString sParamType0( "string" );
     125         263 :                 aParameters[0].pParamName = sParamName0.pData;
     126         263 :                 aParameters[0].eTypeClass = (typelib_TypeClass)::com::sun::star::uno::TypeClass_STRING;
     127         263 :                 aParameters[0].pTypeName = sParamType0.pData;
     128         263 :                 aParameters[0].bIn = sal_True;
     129         263 :                 aParameters[0].bOut = sal_False;
     130         263 :                 ::rtl::OUString the_ExceptionName0( "com.sun.star.uno.RuntimeException" );
     131         263 :                 rtl_uString * the_Exceptions[] = { the_ExceptionName0.pData };
     132         263 :                 ::rtl::OUString sReturnType2( "boolean" );
     133         263 :                 ::rtl::OUString sMethodName2( "com.sun.star.beans.XPropertySetInfo::hasPropertyByName" );
     134             :                 typelib_typedescription_newInterfaceMethod( &pMethod,
     135             :                     5, sal_False,
     136             :                     sMethodName2.pData,
     137             :                     (typelib_TypeClass)::com::sun::star::uno::TypeClass_BOOLEAN, sReturnType2.pData,
     138             :                     1, aParameters,
     139         263 :                     1, the_Exceptions );
     140         263 :                 typelib_typedescription_register( (typelib_TypeDescription**)&pMethod );
     141             :             }
     142         263 :             typelib_typedescription_release( (typelib_TypeDescription*)pMethod );
     143         263 :         }
     144             :     }
     145             :     else
     146             :     {
     147             :         OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
     148             :     }
     149         531 :     return rRet;
     150             : }
     151             : 
     152             : } } } }
     153             : 
     154         257 : inline ::com::sun::star::uno::Type const & SAL_CALL getCppuType(SAL_UNUSED_PARAMETER ::com::sun::star::uno::Reference< css::beans::XPropertySetInfo > const *) SAL_THROW(()) {
     155         257 :     return ::cppu::UnoType< ::com::sun::star::uno::Reference< css::beans::XPropertySetInfo > >::get();
     156             : }
     157             : 
     158         257 : ::com::sun::star::uno::Type const & css::beans::XPropertySetInfo::static_type(SAL_UNUSED_PARAMETER void *) {
     159         257 :     return ::getCppuType(static_cast< ::com::sun::star::uno::Reference< css::beans::XPropertySetInfo > * >(0));
     160             : }
     161             : 
     162             : #endif // INCLUDED_COM_SUN_STAR_BEANS_XPROPERTYSETINFO_HPP

Generated by: LCOV version 1.10