UDK 3.2.7 C/C++ API Reference
|
00001 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ 00002 /************************************************************************* 00003 * 00004 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 00005 * 00006 * Copyright 2000, 2010 Oracle and/or its affiliates. 00007 * 00008 * OpenOffice.org - a multi-platform office productivity suite 00009 * 00010 * This file is part of OpenOffice.org. 00011 * 00012 * OpenOffice.org is free software: you can redistribute it and/or modify 00013 * it under the terms of the GNU Lesser General Public License version 3 00014 * only, as published by the Free Software Foundation. 00015 * 00016 * OpenOffice.org is distributed in the hope that it will be useful, 00017 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00019 * GNU Lesser General Public License version 3 for more details 00020 * (a copy is included in the LICENSE file that accompanied this code). 00021 * 00022 * You should have received a copy of the GNU Lesser General Public License 00023 * version 3 along with OpenOffice.org. If not, see 00024 * <http://www.openoffice.org/license.html> 00025 * for a copy of the LGPLv3 License. 00026 * 00027 ************************************************************************/ 00028 #ifndef _CPPUHELPER_IMPLBASE11_HXX_ 00029 #define _CPPUHELPER_IMPLBASE11_HXX_ 00030 00031 #include <cppuhelper/implbase_ex.hxx> 00032 #include <rtl/instance.hxx> 00033 00034 namespace cppu 00035 { 00037 00038 struct class_data11 00039 { 00040 sal_Int16 m_nTypes; 00041 sal_Bool m_storedTypeRefs; 00042 sal_Bool m_storedId; 00043 sal_Int8 m_id[ 16 ]; 00044 type_entry m_typeEntries[ 11 + 1 ]; 00045 }; 00046 00047 template< typename Ifc1, typename Ifc2, typename Ifc3, typename Ifc4, typename Ifc5, typename Ifc6, typename Ifc7, typename Ifc8, typename Ifc9, typename Ifc10, typename Ifc11, typename Impl > 00048 struct ImplClassData11 00049 { 00050 class_data* operator ()() 00051 { 00052 static class_data11 s_cd = 00053 { 00054 11 +1, sal_False, sal_False, 00055 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, 00056 { 00057 { { Ifc1::static_type }, ((sal_IntPtr)(Ifc1 *) (Impl *) 16) - 16 }, 00058 { { Ifc2::static_type }, ((sal_IntPtr)(Ifc2 *) (Impl *) 16) - 16 }, 00059 { { Ifc3::static_type }, ((sal_IntPtr)(Ifc3 *) (Impl *) 16) - 16 }, 00060 { { Ifc4::static_type }, ((sal_IntPtr)(Ifc4 *) (Impl *) 16) - 16 }, 00061 { { Ifc5::static_type }, ((sal_IntPtr)(Ifc5 *) (Impl *) 16) - 16 }, 00062 { { Ifc6::static_type }, ((sal_IntPtr)(Ifc6 *) (Impl *) 16) - 16 }, 00063 { { Ifc7::static_type }, ((sal_IntPtr)(Ifc7 *) (Impl *) 16) - 16 }, 00064 { { Ifc8::static_type }, ((sal_IntPtr)(Ifc8 *) (Impl *) 16) - 16 }, 00065 { { Ifc9::static_type }, ((sal_IntPtr)(Ifc9 *) (Impl *) 16) - 16 }, 00066 { { Ifc10::static_type }, ((sal_IntPtr)(Ifc10 *) (Impl *) 16) - 16 }, 00067 { { Ifc11::static_type }, ((sal_IntPtr)(Ifc11 *) (Impl *) 16) - 16 }, 00068 { { com::sun::star::lang::XTypeProvider::static_type }, ((sal_IntPtr)(com::sun::star::lang::XTypeProvider *) (Impl *) 16) - 16 } 00069 } 00070 }; 00071 return reinterpret_cast< class_data * >(&s_cd); 00072 } 00073 }; 00074 00076 00085 template< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5, class Ifc6, class Ifc7, class Ifc8, class Ifc9, class Ifc10, class Ifc11 > 00086 class SAL_NO_VTABLE SAL_DLLPUBLIC_TEMPLATE ImplHelper11 00087 : public com::sun::star::lang::XTypeProvider 00088 , public Ifc1, public Ifc2, public Ifc3, public Ifc4, public Ifc5, public Ifc6, public Ifc7, public Ifc8, public Ifc9, public Ifc10, public Ifc11 00089 { 00090 struct cd : public rtl::StaticAggregate< class_data, ImplClassData11< Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11, ImplHelper11<Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11> > > {}; 00091 public: 00092 virtual com::sun::star::uno::Any SAL_CALL queryInterface( com::sun::star::uno::Type const & rType ) throw (com::sun::star::uno::RuntimeException) 00093 { return ImplHelper_query( rType, cd::get(), this ); } 00094 virtual com::sun::star::uno::Sequence< com::sun::star::uno::Type > SAL_CALL getTypes() throw (com::sun::star::uno::RuntimeException) 00095 { return ImplHelper_getTypes( cd::get() ); } 00096 virtual com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw (com::sun::star::uno::RuntimeException) 00097 { return ImplHelper_getImplementationId( cd::get() ); } 00098 00099 #if !defined _MSC_VER // public -> protected changes mangled names there 00100 protected: 00101 #endif 00102 ~ImplHelper11() throw () {} 00103 }; 00112 template< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5, class Ifc6, class Ifc7, class Ifc8, class Ifc9, class Ifc10, class Ifc11 > 00113 class SAL_NO_VTABLE SAL_DLLPUBLIC_TEMPLATE WeakImplHelper11 00114 : public OWeakObject 00115 , public com::sun::star::lang::XTypeProvider 00116 , public Ifc1, public Ifc2, public Ifc3, public Ifc4, public Ifc5, public Ifc6, public Ifc7, public Ifc8, public Ifc9, public Ifc10, public Ifc11 00117 { 00118 struct cd : public rtl::StaticAggregate< class_data, ImplClassData11< Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11, WeakImplHelper11<Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11> > > {}; 00119 public: 00120 virtual com::sun::star::uno::Any SAL_CALL queryInterface( com::sun::star::uno::Type const & rType ) throw (com::sun::star::uno::RuntimeException) 00121 { return WeakImplHelper_query( rType, cd::get(), this, (OWeakObject *)this ); } 00122 virtual void SAL_CALL acquire() throw () 00123 { OWeakObject::acquire(); } 00124 virtual void SAL_CALL release() throw () 00125 { OWeakObject::release(); } 00126 virtual com::sun::star::uno::Sequence< com::sun::star::uno::Type > SAL_CALL getTypes() throw (com::sun::star::uno::RuntimeException) 00127 { return WeakImplHelper_getTypes( cd::get() ); } 00128 virtual com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw (com::sun::star::uno::RuntimeException) 00129 { return ImplHelper_getImplementationId( cd::get() ); } 00130 }; 00144 template< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5, class Ifc6, class Ifc7, class Ifc8, class Ifc9, class Ifc10, class Ifc11 > 00145 class SAL_NO_VTABLE SAL_DLLPUBLIC_TEMPLATE WeakAggImplHelper11 00146 : public OWeakAggObject 00147 , public com::sun::star::lang::XTypeProvider 00148 , public Ifc1, public Ifc2, public Ifc3, public Ifc4, public Ifc5, public Ifc6, public Ifc7, public Ifc8, public Ifc9, public Ifc10, public Ifc11 00149 { 00150 struct cd : public rtl::StaticAggregate< class_data, ImplClassData11< Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11, WeakAggImplHelper11<Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11> > > {}; 00151 public: 00152 virtual com::sun::star::uno::Any SAL_CALL queryInterface( com::sun::star::uno::Type const & rType ) throw (com::sun::star::uno::RuntimeException) 00153 { return OWeakAggObject::queryInterface( rType ); } 00154 virtual com::sun::star::uno::Any SAL_CALL queryAggregation( com::sun::star::uno::Type const & rType ) throw (com::sun::star::uno::RuntimeException) 00155 { return WeakAggImplHelper_queryAgg( rType, cd::get(), this, (OWeakAggObject *)this ); } 00156 virtual void SAL_CALL acquire() throw () 00157 { OWeakAggObject::acquire(); } 00158 virtual void SAL_CALL release() throw () 00159 { OWeakAggObject::release(); } 00160 virtual com::sun::star::uno::Sequence< com::sun::star::uno::Type > SAL_CALL getTypes() throw (com::sun::star::uno::RuntimeException) 00161 { return WeakAggImplHelper_getTypes( cd::get() ); } 00162 virtual com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw (com::sun::star::uno::RuntimeException) 00163 { return ImplHelper_getImplementationId( cd::get() ); } 00164 }; 00181 template< class BaseClass, class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5, class Ifc6, class Ifc7, class Ifc8, class Ifc9, class Ifc10, class Ifc11 > 00182 class SAL_NO_VTABLE SAL_DLLPUBLIC_TEMPLATE ImplInheritanceHelper11 00183 : public BaseClass 00184 , public Ifc1, public Ifc2, public Ifc3, public Ifc4, public Ifc5, public Ifc6, public Ifc7, public Ifc8, public Ifc9, public Ifc10, public Ifc11 00185 { 00186 struct cd : public rtl::StaticAggregate< class_data, ImplClassData11< Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11, ImplInheritanceHelper11<BaseClass, Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11> > > {}; 00187 protected: 00188 template< typename T1 > 00189 explicit ImplInheritanceHelper11(T1 const & arg1): BaseClass(arg1) {} 00190 template< typename T1, typename T2 > 00191 ImplInheritanceHelper11(T1 const & arg1, T2 const & arg2): 00192 BaseClass(arg1, arg2) {} 00193 template< typename T1, typename T2, typename T3 > 00194 ImplInheritanceHelper11( 00195 T1 const & arg1, T2 const & arg2, T3 const & arg3): 00196 BaseClass(arg1, arg2, arg3) {} 00197 template< typename T1, typename T2, typename T3, typename T4 > 00198 ImplInheritanceHelper11( 00199 T1 const & arg1, T2 const & arg2, T3 const & arg3, T4 const & arg4): 00200 BaseClass(arg1, arg2, arg3, arg4) {} 00201 template< 00202 typename T1, typename T2, typename T3, typename T4, typename T5 > 00203 ImplInheritanceHelper11( 00204 T1 const & arg1, T2 const & arg2, T3 const & arg3, T4 const & arg4, 00205 T5 const & arg5): 00206 BaseClass(arg1, arg2, arg3, arg4, arg5) {} 00207 template< 00208 typename T1, typename T2, typename T3, typename T4, typename T5, 00209 typename T6 > 00210 ImplInheritanceHelper11( 00211 T1 const & arg1, T2 const & arg2, T3 const & arg3, T4 const & arg4, 00212 T5 const & arg5, T6 const & arg6): 00213 BaseClass(arg1, arg2, arg3, arg4, arg5, arg6) {} 00214 public: 00215 ImplInheritanceHelper11() {} 00216 virtual com::sun::star::uno::Any SAL_CALL queryInterface( com::sun::star::uno::Type const & rType ) throw (com::sun::star::uno::RuntimeException) 00217 { 00218 com::sun::star::uno::Any aRet( ImplHelper_queryNoXInterface( rType, cd::get(), this ) ); 00219 if (aRet.hasValue()) 00220 return aRet; 00221 return BaseClass::queryInterface( rType ); 00222 } 00223 virtual void SAL_CALL acquire() throw () 00224 { BaseClass::acquire(); } 00225 virtual void SAL_CALL release() throw () 00226 { BaseClass::release(); } 00227 virtual com::sun::star::uno::Sequence< com::sun::star::uno::Type > SAL_CALL getTypes() throw (com::sun::star::uno::RuntimeException) 00228 { return ImplInhHelper_getTypes( cd::get(), BaseClass::getTypes() ); } 00229 virtual com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw (com::sun::star::uno::RuntimeException) 00230 { return ImplHelper_getImplementationId( cd::get() ); } 00231 }; 00249 template< class BaseClass, class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5, class Ifc6, class Ifc7, class Ifc8, class Ifc9, class Ifc10, class Ifc11 > 00250 class SAL_NO_VTABLE SAL_DLLPUBLIC_TEMPLATE AggImplInheritanceHelper11 00251 : public BaseClass 00252 , public Ifc1, public Ifc2, public Ifc3, public Ifc4, public Ifc5, public Ifc6, public Ifc7, public Ifc8, public Ifc9, public Ifc10, public Ifc11 00253 { 00254 struct cd : public rtl::StaticAggregate< class_data, ImplClassData11< Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11, AggImplInheritanceHelper11<BaseClass, Ifc1, Ifc2, Ifc3, Ifc4, Ifc5, Ifc6, Ifc7, Ifc8, Ifc9, Ifc10, Ifc11> > > {}; 00255 protected: 00256 template< typename T1 > 00257 explicit AggImplInheritanceHelper11(T1 const & arg1): BaseClass(arg1) {} 00258 template< typename T1, typename T2 > 00259 AggImplInheritanceHelper11(T1 const & arg1, T2 const & arg2): 00260 BaseClass(arg1, arg2) {} 00261 template< typename T1, typename T2, typename T3 > 00262 AggImplInheritanceHelper11( 00263 T1 const & arg1, T2 const & arg2, T3 const & arg3): 00264 BaseClass(arg1, arg2, arg3) {} 00265 template< typename T1, typename T2, typename T3, typename T4 > 00266 AggImplInheritanceHelper11( 00267 T1 const & arg1, T2 const & arg2, T3 const & arg3, T4 const & arg4): 00268 BaseClass(arg1, arg2, arg3, arg4) {} 00269 template< 00270 typename T1, typename T2, typename T3, typename T4, typename T5 > 00271 AggImplInheritanceHelper11( 00272 T1 const & arg1, T2 const & arg2, T3 const & arg3, T4 const & arg4, 00273 T5 const & arg5): 00274 BaseClass(arg1, arg2, arg3, arg4, arg5) {} 00275 template< 00276 typename T1, typename T2, typename T3, typename T4, typename T5, 00277 typename T6 > 00278 AggImplInheritanceHelper11( 00279 T1 const & arg1, T2 const & arg2, T3 const & arg3, T4 const & arg4, 00280 T5 const & arg5, T6 const & arg6): 00281 BaseClass(arg1, arg2, arg3, arg4, arg5, arg6) {} 00282 public: 00283 AggImplInheritanceHelper11() {} 00284 virtual com::sun::star::uno::Any SAL_CALL queryInterface( com::sun::star::uno::Type const & rType ) throw (com::sun::star::uno::RuntimeException) 00285 { return BaseClass::queryInterface( rType ); } 00286 virtual com::sun::star::uno::Any SAL_CALL queryAggregation( com::sun::star::uno::Type const & rType ) throw (com::sun::star::uno::RuntimeException) 00287 { 00288 com::sun::star::uno::Any aRet( ImplHelper_queryNoXInterface( rType, cd::get(), this ) ); 00289 if (aRet.hasValue()) 00290 return aRet; 00291 return BaseClass::queryAggregation( rType ); 00292 } 00293 virtual void SAL_CALL acquire() throw () 00294 { BaseClass::acquire(); } 00295 virtual void SAL_CALL release() throw () 00296 { BaseClass::release(); } 00297 virtual com::sun::star::uno::Sequence< com::sun::star::uno::Type > SAL_CALL getTypes() throw (com::sun::star::uno::RuntimeException) 00298 { return ImplInhHelper_getTypes( cd::get(), BaseClass::getTypes() ); } 00299 virtual com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw (com::sun::star::uno::RuntimeException) 00300 { return ImplHelper_getImplementationId( cd::get() ); } 00301 }; 00302 } 00303 00304 #endif 00305 00306 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */