LCOV - code coverage report
Current view: top level - solver/unxlngi6.pro/inc/cppuhelper - compbase10.hxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 20 0.0 %
Date: 2012-08-25 Functions: 0 11 0.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 0 0 -

           Branch data     Line data    Source code
       1                 :            : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2                 :            : /*************************************************************************
       3                 :            :  *
       4                 :            :  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
       5                 :            :  *
       6                 :            :  * Copyright 2000, 2010 Oracle and/or its affiliates.
       7                 :            :  *
       8                 :            :  * OpenOffice.org - a multi-platform office productivity suite
       9                 :            :  *
      10                 :            :  * This file is part of OpenOffice.org.
      11                 :            :  *
      12                 :            :  * OpenOffice.org is free software: you can redistribute it and/or modify
      13                 :            :  * it under the terms of the GNU Lesser General Public License version 3
      14                 :            :  * only, as published by the Free Software Foundation.
      15                 :            :  *
      16                 :            :  * OpenOffice.org is distributed in the hope that it will be useful,
      17                 :            :  * but WITHOUT ANY WARRANTY; without even the implied warranty of
      18                 :            :  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      19                 :            :  * GNU Lesser General Public License version 3 for more details
      20                 :            :  * (a copy is included in the LICENSE file that accompanied this code).
      21                 :            :  *
      22                 :            :  * You should have received a copy of the GNU Lesser General Public License
      23                 :            :  * version 3 along with OpenOffice.org.  If not, see
      24                 :            :  * <http://www.openoffice.org/license.html>
      25                 :            :  * for a copy of the LGPLv3 License.
      26                 :            :  *
      27                 :            :  ************************************************************************/
      28                 :            : #ifndef _CPPUHELPER_COMPBASE10_HXX_
      29                 :            : #define _CPPUHELPER_COMPBASE10_HXX_
      30                 :            : 
      31                 :            : #include <cppuhelper/implbase10.hxx>
      32                 :            : #include <cppuhelper/compbase_ex.hxx>
      33                 :            : 
      34                 :            : namespace cppu
      35                 :            : {
      36                 :            : 
      37                 :            : // Suppress warnings about hidden functions in case any of the IfcN has
      38                 :            : // functions named dispose, addEventListener, or removeEventListener:
      39                 :            : #if defined __SUNPRO_CC
      40                 :            : #pragma disable_warn
      41                 :            : #endif
      42                 :            : 
      43                 :            :     /** Implementation helper supporting com::sun::star::lang::XTypeProvider and
      44                 :            :         com::sun::star::lang::XComponent.
      45                 :            : 
      46                 :            :         Upon disposing objects of this class, sub-classes receive a disposing()
      47                 :            :         call.  Objects of this class can be held weakly, i.e. by a
      48                 :            :         com::sun::star::uno::WeakReference.
      49                 :            : 
      50                 :            :         @attention
      51                 :            :         The life-cycle of the passed mutex reference has to be longer than objects of this class.
      52                 :            : 
      53                 :            :         @derive
      54                 :            :         Inherit from this class giving your interface(s) to be implemented as template argument(s).
      55                 :            :         Your sub class defines method implementations for these interface(s).
      56                 :            :     */
      57                 :            :     template< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5, class Ifc6, class Ifc7, class Ifc8, class Ifc9, class Ifc10 >
      58                 :          0 :     class SAL_NO_VTABLE SAL_DLLPUBLIC_TEMPLATE WeakComponentImplHelper10
      59                 :            :         : public WeakComponentImplHelperBase
      60                 :            :         , public ::com::sun::star::lang::XTypeProvider
      61                 :            :         , public Ifc1, public Ifc2, public Ifc3, public Ifc4, public Ifc5, public Ifc6, public Ifc7, public Ifc8, public Ifc9, public Ifc10
      62                 :            :     {
      63                 :            :         struct cd : public rtl::StaticAggregate< class_data, ImplClassData10< Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, WeakComponentImplHelper10<Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10> > > {};
      64                 :            :     public:
      65                 :          0 :         inline WeakComponentImplHelper10( ::osl::Mutex & rMutex ) throw ()
      66                 :          0 :             : WeakComponentImplHelperBase( rMutex )
      67                 :          0 :             {}
      68                 :          0 :         virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( ::com::sun::star::uno::Type const & rType ) throw (::com::sun::star::uno::RuntimeException)
      69                 :          0 :             { return WeakComponentImplHelper_query( rType, cd::get(), this, (WeakComponentImplHelperBase *)this ); }
      70                 :          0 :         virtual void SAL_CALL acquire() throw ()
      71                 :          0 :             { WeakComponentImplHelperBase::acquire(); }
      72                 :          0 :         virtual void SAL_CALL release() throw ()
      73                 :          0 :             { WeakComponentImplHelperBase::release(); }
      74                 :          0 :         virtual void SAL_CALL dispose()throw (::com::sun::star::uno::RuntimeException)
      75                 :          0 :             { WeakComponentImplHelperBase::dispose(); }
      76                 :          0 :         virtual void SAL_CALL addEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & xListener)throw (::com::sun::star::uno::RuntimeException)
      77                 :          0 :             { WeakComponentImplHelperBase::addEventListener(xListener); }
      78                 :          0 :         virtual void SAL_CALL removeEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & xListener)throw (::com::sun::star::uno::RuntimeException)
      79                 :          0 :             { WeakComponentImplHelperBase::removeEventListener(xListener); }
      80                 :          0 :         virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw (::com::sun::star::uno::RuntimeException)
      81                 :          0 :             { return WeakComponentImplHelper_getTypes( cd::get() ); }
      82                 :          0 :         virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw (::com::sun::star::uno::RuntimeException)
      83                 :          0 :             { return ImplHelper_getImplementationId( cd::get() ); }
      84                 :            :     };
      85                 :            : 
      86                 :            : #if defined __SUNPRO_CC
      87                 :            : #pragma enable_warn
      88                 :            : #endif
      89                 :            : 
      90                 :            :     /** Same as WeakComponentImplHelper10, except doesn't implement
      91                 :            :         addEventListener, removeEventListener and dispose.
      92                 :            : 
      93                 :            :         This requires derived classes to implement those three methods.
      94                 :            :         This makes it possible to implement classes which are required to
      95                 :            :         implement methods from multiple bases which have different
      96                 :            :         addEventListener/removeEventListener signatures without triggering
      97                 :            :         the g++ overloaded-virtual warning
      98                 :            :     */
      99                 :            :     template< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5, class Ifc6, class Ifc7, class Ifc8, class Ifc9, class Ifc10 >
     100                 :            :     class SAL_NO_VTABLE SAL_DLLPUBLIC_TEMPLATE PartialWeakComponentImplHelper10
     101                 :            :         : public WeakComponentImplHelperBase
     102                 :            :         , public ::com::sun::star::lang::XTypeProvider
     103                 :            :         , public Ifc1, public Ifc2, public Ifc3, public Ifc4, public Ifc5, public Ifc6, public Ifc7, public Ifc8, public Ifc9, public Ifc10
     104                 :            :     {
     105                 :            :         struct cd : public rtl::StaticAggregate< class_data, ImplClassData10< Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, PartialWeakComponentImplHelper10<Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10> > > {};
     106                 :            :     public:
     107                 :            :         inline PartialWeakComponentImplHelper10( ::osl::Mutex & rMutex ) throw ()
     108                 :            :             : WeakComponentImplHelperBase( rMutex )
     109                 :            :             {}
     110                 :            :         virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( ::com::sun::star::uno::Type const & rType ) throw (::com::sun::star::uno::RuntimeException)
     111                 :            :             { return WeakComponentImplHelper_query( rType, cd::get(), this, (WeakComponentImplHelperBase *)this ); }
     112                 :            :         virtual void SAL_CALL acquire() throw ()
     113                 :            :             { WeakComponentImplHelperBase::acquire(); }
     114                 :            :         virtual void SAL_CALL release() throw ()
     115                 :            :             { WeakComponentImplHelperBase::release(); }
     116                 :            :         virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw (::com::sun::star::uno::RuntimeException)
     117                 :            :             { return WeakComponentImplHelper_getTypes( cd::get() ); }
     118                 :            :         virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw (::com::sun::star::uno::RuntimeException)
     119                 :            :             { return ImplHelper_getImplementationId( cd::get() ); }
     120                 :            :     };
     121                 :            : 
     122                 :            :     /** Implementation helper supporting com::sun::star::lang::XTypeProvider and
     123                 :            :         com::sun::star::lang::XComponent.
     124                 :            : 
     125                 :            :         Upon disposing objects of this class, sub-classes receive a disposing()
     126                 :            :         call.  Objects of this class can be held weakly, i.e. by a
     127                 :            :         com::sun::star::uno::WeakReference.  Object of this class can be
     128                 :            :         aggregated, i.e. incoming queryInterface() calls are delegated.
     129                 :            : 
     130                 :            :         @attention
     131                 :            :         The life-cycle of the passed mutex reference has to be longer than objects of this class.
     132                 :            : 
     133                 :            :         @derive
     134                 :            :         Inherit from this class giving your interface(s) to be implemented as template argument(s).
     135                 :            :         Your sub class defines method implementations for these interface(s).
     136                 :            : 
     137                 :            :         @deprecated
     138                 :            :     */
     139                 :            :     template< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5, class Ifc6, class Ifc7, class Ifc8, class Ifc9, class Ifc10 >
     140                 :            :     class SAL_NO_VTABLE SAL_DLLPUBLIC_TEMPLATE WeakAggComponentImplHelper10
     141                 :            :         : public WeakAggComponentImplHelperBase
     142                 :            :         , public ::com::sun::star::lang::XTypeProvider
     143                 :            :         , public Ifc1, public Ifc2, public Ifc3, public Ifc4, public Ifc5, public Ifc6, public Ifc7, public Ifc8, public Ifc9, public Ifc10
     144                 :            :     {
     145                 :            :         struct cd : public rtl::StaticAggregate< class_data, ImplClassData10< Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, WeakAggComponentImplHelper10<Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10> > > {};
     146                 :            :     public:
     147                 :            :         inline WeakAggComponentImplHelper10( ::osl::Mutex & rMutex ) throw ()
     148                 :            :             : WeakAggComponentImplHelperBase( rMutex )
     149                 :            :             {}
     150                 :            :         virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( ::com::sun::star::uno::Type const & rType ) throw (::com::sun::star::uno::RuntimeException)
     151                 :            :             { return WeakAggComponentImplHelperBase::queryInterface( rType ); }
     152                 :            :         virtual ::com::sun::star::uno::Any SAL_CALL queryAggregation( ::com::sun::star::uno::Type const & rType ) throw (::com::sun::star::uno::RuntimeException)
     153                 :            :             { return WeakAggComponentImplHelper_queryAgg( rType, cd::get(), this, (WeakAggComponentImplHelperBase *)this ); }
     154                 :            :         virtual void SAL_CALL acquire() throw ()
     155                 :            :             { WeakAggComponentImplHelperBase::acquire(); }
     156                 :            :         virtual void SAL_CALL release() throw ()
     157                 :            :             { WeakAggComponentImplHelperBase::release(); }
     158                 :            :         virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw (::com::sun::star::uno::RuntimeException)
     159                 :            :             { return WeakAggComponentImplHelper_getTypes( cd::get() ); }
     160                 :            :         virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw (::com::sun::star::uno::RuntimeException)
     161                 :            :             { return ImplHelper_getImplementationId( cd::get() ); }
     162                 :            :     };
     163                 :            : }
     164                 :            : 
     165                 :            : #endif
     166                 :            : 
     167                 :            : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10