1*cdf0e10cSrcweir /************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir * 5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir * 7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * This file is part of OpenOffice.org. 10*cdf0e10cSrcweir * 11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir * 15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir * 26*cdf0e10cSrcweir ************************************************************************/ 27*cdf0e10cSrcweir 28*cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove 29*cdf0e10cSrcweir #include "precompiled_testtools.hxx" 30*cdf0e10cSrcweir 31*cdf0e10cSrcweir #include "sal/config.h" 32*cdf0e10cSrcweir 33*cdf0e10cSrcweir #include "com/sun/star/lang/XInitialization.hpp" 34*cdf0e10cSrcweir #include "com/sun/star/lang/XComponent.hpp" 35*cdf0e10cSrcweir #include "com/sun/star/uno/Any.hxx" 36*cdf0e10cSrcweir #include "com/sun/star/uno/Exception.hpp" 37*cdf0e10cSrcweir #include "com/sun/star/uno/Reference.hxx" 38*cdf0e10cSrcweir #include "com/sun/star/uno/Sequence.hxx" 39*cdf0e10cSrcweir #include "com/sun/star/uno/Type.hxx" 40*cdf0e10cSrcweir #include "com/sun/star/uno/XComponentContext.hpp" 41*cdf0e10cSrcweir #include "com/sun/star/uno/XInterface.hpp" 42*cdf0e10cSrcweir #include "cppu/unotype.hxx" 43*cdf0e10cSrcweir #include "cppuhelper/factory.hxx" 44*cdf0e10cSrcweir #include "cppuhelper/implbase1.hxx" 45*cdf0e10cSrcweir #include "cppuhelper/implbase2.hxx" 46*cdf0e10cSrcweir #include "cppuhelper/implementationentry.hxx" 47*cdf0e10cSrcweir #include "cppuhelper/weak.hxx" 48*cdf0e10cSrcweir #include "rtl/string.h" 49*cdf0e10cSrcweir #include "rtl/ustring.h" 50*cdf0e10cSrcweir #include "rtl/ustring.hxx" 51*cdf0e10cSrcweir #include "sal/types.h" 52*cdf0e10cSrcweir #include "test/testtools/bridgetest/BadConstructorArguments.hpp" 53*cdf0e10cSrcweir #include "test/testtools/bridgetest/TestEnum.hpp" 54*cdf0e10cSrcweir #include "test/testtools/bridgetest/TestStruct.hpp" 55*cdf0e10cSrcweir #include "test/testtools/bridgetest/TestPolyStruct.hpp" 56*cdf0e10cSrcweir #include "test/testtools/bridgetest/TestPolyStruct2.hpp" 57*cdf0e10cSrcweir #include "test/testtools/bridgetest/XMultiBase1.hpp" 58*cdf0e10cSrcweir #include "uno/lbnames.h" 59*cdf0e10cSrcweir 60*cdf0e10cSrcweir namespace { 61*cdf0e10cSrcweir 62*cdf0e10cSrcweir namespace css = ::com::sun::star; 63*cdf0e10cSrcweir namespace ttb = ::test::testtools::bridgetest; 64*cdf0e10cSrcweir class Impl: public ::cppu::WeakImplHelper1< css::lang::XInitialization > { 65*cdf0e10cSrcweir public: 66*cdf0e10cSrcweir Impl() {} 67*cdf0e10cSrcweir 68*cdf0e10cSrcweir private: 69*cdf0e10cSrcweir Impl(Impl &); // not defined 70*cdf0e10cSrcweir void operator =(Impl &); // not defined 71*cdf0e10cSrcweir 72*cdf0e10cSrcweir virtual ~Impl() {} 73*cdf0e10cSrcweir 74*cdf0e10cSrcweir virtual void SAL_CALL initialize( 75*cdf0e10cSrcweir css::uno::Sequence< css::uno::Any > const & arguments) 76*cdf0e10cSrcweir throw (css::uno::Exception); 77*cdf0e10cSrcweir }; 78*cdf0e10cSrcweir 79*cdf0e10cSrcweir void Impl::initialize(css::uno::Sequence< css::uno::Any > const & arguments) 80*cdf0e10cSrcweir throw (css::uno::Exception) 81*cdf0e10cSrcweir { 82*cdf0e10cSrcweir ::sal_Bool arg0 = sal_Bool(); 83*cdf0e10cSrcweir ::sal_Int8 arg1 = sal_Int8(); 84*cdf0e10cSrcweir ::sal_Int16 arg2 = sal_Int16(); 85*cdf0e10cSrcweir ::sal_uInt16 arg3 = sal_uInt16(); 86*cdf0e10cSrcweir ::sal_Int32 arg4 = sal_Int32(); 87*cdf0e10cSrcweir ::sal_uInt32 arg5 = sal_uInt32(); 88*cdf0e10cSrcweir ::sal_Int64 arg6 = sal_Int64(); 89*cdf0e10cSrcweir ::sal_uInt64 arg7 = sal_uInt64(); 90*cdf0e10cSrcweir float arg8 = float(); 91*cdf0e10cSrcweir double arg9 = double(); 92*cdf0e10cSrcweir ::rtl::OUString arg11; 93*cdf0e10cSrcweir css::uno::Type arg12; 94*cdf0e10cSrcweir ::sal_Bool arg13 = sal_Bool(); 95*cdf0e10cSrcweir css::uno::Sequence< ::sal_Bool > arg14; 96*cdf0e10cSrcweir css::uno::Sequence< ::sal_Int8 > arg15; 97*cdf0e10cSrcweir css::uno::Sequence< ::sal_Int16 > arg16; 98*cdf0e10cSrcweir css::uno::Sequence< ::sal_uInt16 > arg17; 99*cdf0e10cSrcweir css::uno::Sequence< ::sal_Int32 > arg18; 100*cdf0e10cSrcweir css::uno::Sequence< ::sal_uInt32 > arg19; 101*cdf0e10cSrcweir css::uno::Sequence< ::sal_Int64 > arg20; 102*cdf0e10cSrcweir css::uno::Sequence< ::sal_uInt64 > arg21; 103*cdf0e10cSrcweir css::uno::Sequence< float > arg22; 104*cdf0e10cSrcweir css::uno::Sequence< double > arg23; 105*cdf0e10cSrcweir css::uno::Sequence< ::rtl::OUString > arg25; 106*cdf0e10cSrcweir css::uno::Sequence< css::uno::Type > arg26; 107*cdf0e10cSrcweir css::uno::Sequence< css::uno::Any > arg27; 108*cdf0e10cSrcweir ::sal_Bool arg27b = sal_Bool(); 109*cdf0e10cSrcweir css::uno::Sequence< css::uno::Sequence< ::sal_Bool > > arg28; 110*cdf0e10cSrcweir css::uno::Sequence< css::uno::Sequence< css::uno::Any > > arg29; 111*cdf0e10cSrcweir ::sal_Bool arg29b = sal_Bool(); 112*cdf0e10cSrcweir css::uno::Sequence< ::test::testtools::bridgetest::TestEnum > arg30; 113*cdf0e10cSrcweir css::uno::Sequence< ::test::testtools::bridgetest::TestStruct > arg31; 114*cdf0e10cSrcweir css::uno::Sequence< 115*cdf0e10cSrcweir ::test::testtools::bridgetest::TestPolyStruct< sal_Bool > > arg32; 116*cdf0e10cSrcweir css::uno::Sequence< 117*cdf0e10cSrcweir ::test::testtools::bridgetest::TestPolyStruct< css::uno::Any > > arg33; 118*cdf0e10cSrcweir ::sal_Bool arg33b = sal_Bool(); 119*cdf0e10cSrcweir css::uno::Sequence< css::uno::Reference< css::uno::XInterface > > arg34; 120*cdf0e10cSrcweir ::test::testtools::bridgetest::TestEnum arg35; 121*cdf0e10cSrcweir ::test::testtools::bridgetest::TestStruct arg36; 122*cdf0e10cSrcweir ::test::testtools::bridgetest::TestPolyStruct< ::sal_Bool > arg37; 123*cdf0e10cSrcweir ::test::testtools::bridgetest::TestPolyStruct< css::uno::Any > arg38; 124*cdf0e10cSrcweir ::sal_Bool arg38b = sal_Bool(); 125*cdf0e10cSrcweir css::uno::Reference< css::uno::XInterface > arg39; 126*cdf0e10cSrcweir if (!(arguments.getLength() == 40 127*cdf0e10cSrcweir && (arguments[0] >>= arg0) && arg0 128*cdf0e10cSrcweir && (arguments[1] >>= arg1) && arg1 == SAL_MIN_INT8 129*cdf0e10cSrcweir && (arguments[2] >>= arg2) && arg2 == SAL_MIN_INT16 130*cdf0e10cSrcweir && (arguments[3].getValueType() 131*cdf0e10cSrcweir == ::cppu::UnoType< ::cppu::UnoUnsignedShortType >::get()) 132*cdf0e10cSrcweir && (arguments[3] >>= arg3) && arg3 == SAL_MAX_UINT16 133*cdf0e10cSrcweir && (arguments[4] >>= arg4) && arg4 == SAL_MIN_INT32 134*cdf0e10cSrcweir && (arguments[5] >>= arg5) && arg5 == SAL_MAX_UINT32 135*cdf0e10cSrcweir && (arguments[6] >>= arg6) && arg6 == SAL_MIN_INT64 136*cdf0e10cSrcweir && (arguments[7] >>= arg7) && arg7 == SAL_MAX_UINT64 137*cdf0e10cSrcweir && (arguments[8] >>= arg8) && arg8 == 0.123f 138*cdf0e10cSrcweir && (arguments[9] >>= arg9) && arg9 == 0.456 139*cdf0e10cSrcweir && (arguments[10].getValueType() 140*cdf0e10cSrcweir == ::cppu::UnoType< ::cppu::UnoCharType >::get()) 141*cdf0e10cSrcweir && (*static_cast< ::sal_Unicode const * >(arguments[10].getValue()) 142*cdf0e10cSrcweir == 'X') 143*cdf0e10cSrcweir && (arguments[11] >>= arg11) 144*cdf0e10cSrcweir && arg11.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 145*cdf0e10cSrcweir && (arguments[12] >>= arg12) 146*cdf0e10cSrcweir && arg12 == ::cppu::UnoType< css::uno::Any >::get() 147*cdf0e10cSrcweir && (arguments[13] >>= arg13) && arg13 148*cdf0e10cSrcweir && (arguments[14] >>= arg14) && arg14.getLength() == 1 && arg14[0] 149*cdf0e10cSrcweir && (arguments[15] >>= arg15) && arg15.getLength() == 1 150*cdf0e10cSrcweir && arg15[0] == SAL_MIN_INT8 151*cdf0e10cSrcweir && (arguments[16] >>= arg16) && arg16.getLength() == 1 152*cdf0e10cSrcweir && arg16[0] == SAL_MIN_INT16 153*cdf0e10cSrcweir && (arguments[17].getValueType() 154*cdf0e10cSrcweir == ::cppu::UnoType< 155*cdf0e10cSrcweir ::cppu::UnoSequenceType < 156*cdf0e10cSrcweir ::cppu::UnoUnsignedShortType > >::get()) 157*cdf0e10cSrcweir && (arguments[17] >>= arg17) && arg17.getLength() == 1 158*cdf0e10cSrcweir && arg17[0] == SAL_MAX_UINT16 159*cdf0e10cSrcweir && (arguments[18] >>= arg18) && arg18.getLength() == 1 160*cdf0e10cSrcweir && arg18[0] == SAL_MIN_INT32 161*cdf0e10cSrcweir && (arguments[19] >>= arg19) && arg19.getLength() == 1 162*cdf0e10cSrcweir && arg19[0] == SAL_MAX_UINT32 163*cdf0e10cSrcweir && (arguments[20] >>= arg20) && arg20.getLength() == 1 164*cdf0e10cSrcweir && arg20[0] == SAL_MIN_INT64 165*cdf0e10cSrcweir && (arguments[21] >>= arg21) && arg21.getLength() == 1 166*cdf0e10cSrcweir && arg21[0] == SAL_MAX_UINT64 167*cdf0e10cSrcweir && (arguments[22] >>= arg22) && arg22.getLength() == 1 168*cdf0e10cSrcweir && arg22[0] == 0.123f 169*cdf0e10cSrcweir && (arguments[23] >>= arg23) && arg23.getLength() == 1 170*cdf0e10cSrcweir && arg23[0] == 0.456 171*cdf0e10cSrcweir && (arguments[24].getValueType() 172*cdf0e10cSrcweir == ::cppu::UnoType< 173*cdf0e10cSrcweir ::cppu::UnoSequenceType< ::cppu::UnoCharType > >::get()) 174*cdf0e10cSrcweir && (static_cast< css::uno::Sequence< ::sal_Unicode > const * >( 175*cdf0e10cSrcweir arguments[24].getValue())->getLength() 176*cdf0e10cSrcweir == 1) 177*cdf0e10cSrcweir && ((*static_cast< css::uno::Sequence< ::sal_Unicode > const * >( 178*cdf0e10cSrcweir arguments[24].getValue()))[0] 179*cdf0e10cSrcweir == 'X') 180*cdf0e10cSrcweir && (arguments[25] >>= arg25) && arg25.getLength() == 1 181*cdf0e10cSrcweir && arg25[0].equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 182*cdf0e10cSrcweir && (arguments[26] >>= arg26) && arg26.getLength() == 1 183*cdf0e10cSrcweir && arg26[0] == ::cppu::UnoType< css::uno::Any >::get() 184*cdf0e10cSrcweir && (arguments[27] >>= arg27) && arg27.getLength() == 1 185*cdf0e10cSrcweir && (arg27[0] >>= arg27b) && arg27b 186*cdf0e10cSrcweir && (arguments[28] >>= arg28) && arg28.getLength() == 1 187*cdf0e10cSrcweir && arg28[0].getLength() == 1 && arg28[0][0] 188*cdf0e10cSrcweir && (arguments[29] >>= arg29) && arg29.getLength() == 1 189*cdf0e10cSrcweir && arg29[0].getLength() == 1 && (arg29[0][0] >>= arg29b) && arg29b 190*cdf0e10cSrcweir && (arguments[30] >>= arg30) && arg30.getLength() == 1 191*cdf0e10cSrcweir && arg30[0] == ::test::testtools::bridgetest::TestEnum_TWO 192*cdf0e10cSrcweir && (arguments[31] >>= arg31) && arg31.getLength() == 1 193*cdf0e10cSrcweir && arg31[0].member == 10 194*cdf0e10cSrcweir && (arguments[32] >>= arg32) && arg32.getLength() == 1 195*cdf0e10cSrcweir && arg32[0].member 196*cdf0e10cSrcweir && (arguments[33] >>= arg33) && arg33.getLength() == 1 197*cdf0e10cSrcweir && (arg33[0].member >>= arg33b) && arg33b 198*cdf0e10cSrcweir && (arguments[34] >>= arg34) && arg34.getLength() == 1 199*cdf0e10cSrcweir && !arg34[0].is() 200*cdf0e10cSrcweir && (arguments[35] >>= arg35) 201*cdf0e10cSrcweir && arg35 == ::test::testtools::bridgetest::TestEnum_TWO 202*cdf0e10cSrcweir && (arguments[36] >>= arg36) && arg36.member == 10 203*cdf0e10cSrcweir && (arguments[37] >>= arg37) && arg37.member 204*cdf0e10cSrcweir && (arguments[38] >>= arg38) && (arg38.member >>= arg38b) && arg38b 205*cdf0e10cSrcweir && (arguments[39] >>= arg39) && !arg39.is())) 206*cdf0e10cSrcweir { 207*cdf0e10cSrcweir throw ::test::testtools::bridgetest::BadConstructorArguments(); 208*cdf0e10cSrcweir } 209*cdf0e10cSrcweir } 210*cdf0e10cSrcweir 211*cdf0e10cSrcweir 212*cdf0e10cSrcweir class Impl2: public ::cppu::WeakImplHelper2< 213*cdf0e10cSrcweir css::lang::XInitialization, ttb::XMultiBase1 > 214*cdf0e10cSrcweir { 215*cdf0e10cSrcweir public: 216*cdf0e10cSrcweir Impl2(): m_attr1(0.0) {} 217*cdf0e10cSrcweir 218*cdf0e10cSrcweir private: 219*cdf0e10cSrcweir Impl2(Impl &); // not defined 220*cdf0e10cSrcweir void operator =(Impl &); // not defined 221*cdf0e10cSrcweir 222*cdf0e10cSrcweir virtual ~Impl2() {} 223*cdf0e10cSrcweir 224*cdf0e10cSrcweir virtual void SAL_CALL initialize( 225*cdf0e10cSrcweir css::uno::Sequence< css::uno::Any > const & arguments) 226*cdf0e10cSrcweir throw (css::uno::Exception); 227*cdf0e10cSrcweir 228*cdf0e10cSrcweir //XMultiBase1 229*cdf0e10cSrcweir virtual double SAL_CALL getatt1() 230*cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 231*cdf0e10cSrcweir virtual void SAL_CALL setatt1( double _att1 ) 232*cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 233*cdf0e10cSrcweir virtual ::sal_Int32 SAL_CALL fn11( ::sal_Int32 arg ) 234*cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 235*cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL fn12( const ::rtl::OUString& arg ) 236*cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 237*cdf0e10cSrcweir 238*cdf0e10cSrcweir 239*cdf0e10cSrcweir double m_attr1; 240*cdf0e10cSrcweir }; 241*cdf0e10cSrcweir 242*cdf0e10cSrcweir void Impl2::initialize(css::uno::Sequence< css::uno::Any > const & arguments) 243*cdf0e10cSrcweir throw (css::uno::Exception) 244*cdf0e10cSrcweir { 245*cdf0e10cSrcweir ttb::TestPolyStruct< css::uno::Type > arg0; 246*cdf0e10cSrcweir ttb::TestPolyStruct< css::uno::Any > arg1; 247*cdf0e10cSrcweir css::uno::Any arg1b(sal_True); 248*cdf0e10cSrcweir ttb::TestPolyStruct< ::sal_Bool > arg2; 249*cdf0e10cSrcweir ttb::TestPolyStruct< ::sal_Int8 > arg3; 250*cdf0e10cSrcweir ttb::TestPolyStruct< ::sal_Int16 > arg4; 251*cdf0e10cSrcweir ttb::TestPolyStruct< ::sal_Int32 > arg5; 252*cdf0e10cSrcweir ttb::TestPolyStruct< ::sal_Int64 > arg6; 253*cdf0e10cSrcweir ttb::TestPolyStruct< ::sal_Unicode > arg7; 254*cdf0e10cSrcweir ttb::TestPolyStruct< ::rtl::OUString > arg8; 255*cdf0e10cSrcweir ttb::TestPolyStruct< float > arg9; 256*cdf0e10cSrcweir ttb::TestPolyStruct< double > arg10; 257*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Reference<css::uno::XInterface> > arg11; 258*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Reference< css::lang::XComponent> > arg12; 259*cdf0e10cSrcweir ttb::TestPolyStruct<ttb::TestEnum> arg13; 260*cdf0e10cSrcweir ttb::TestPolyStruct< 261*cdf0e10cSrcweir ttb::TestPolyStruct2<sal_Unicode, css::uno::Any> > arg14; 262*cdf0e10cSrcweir ttb::TestPolyStruct< ttb::TestPolyStruct2 < 263*cdf0e10cSrcweir ttb::TestPolyStruct2< sal_Unicode, css::uno::Any >, 264*cdf0e10cSrcweir ::rtl::OUString > > arg15; 265*cdf0e10cSrcweir ttb::TestPolyStruct2< ::rtl::OUString,ttb::TestPolyStruct2 < 266*cdf0e10cSrcweir ::sal_Unicode, ttb::TestPolyStruct < css::uno::Any > > > arg16; 267*cdf0e10cSrcweir ttb::TestPolyStruct2< ttb::TestPolyStruct2<sal_Unicode, css::uno::Any >, 268*cdf0e10cSrcweir ttb::TestPolyStruct<sal_Unicode> > arg17; 269*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence< css::uno::Type > > arg18; 270*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<css::uno::Any> > arg19; 271*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence< ::sal_Bool > > arg20; 272*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence< ::sal_Int8 > > arg21; 273*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence< ::sal_Int16 > > arg22; 274*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence< ::sal_Int32 > > arg23; 275*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence< ::sal_Int64 > > arg24; 276*cdf0e10cSrcweir // ttb::TestPolyStruct<css::uno::Sequence<::sal_Unicode> > arg25; 277*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence< ::rtl::OUString > > arg26; 278*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<float> > arg27; 279*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<double> > arg28; 280*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<css::uno::Reference<css::uno::XInterface> > > arg29; 281*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<css::uno::Reference<css::lang::XComponent> > > arg30; 282*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<ttb::TestEnum> > arg31; 283*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<ttb::TestPolyStruct2< 284*cdf0e10cSrcweir ::sal_Unicode, css::uno::Sequence<css::uno::Any> > > > arg32; 285*cdf0e10cSrcweir bool arg32a = false; 286*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<ttb::TestPolyStruct2< 287*cdf0e10cSrcweir ttb::TestPolyStruct< ::sal_Unicode>, css::uno::Sequence<css::uno::Any> > > > arg33; 288*cdf0e10cSrcweir ttb::TestPolyStruct<css::uno::Sequence<css::uno::Sequence< ::sal_Int32> > > arg34; 289*cdf0e10cSrcweir css::uno::Sequence<ttb::TestPolyStruct< ::sal_Int32> > arg35; 290*cdf0e10cSrcweir css::uno::Sequence<ttb::TestPolyStruct<ttb::TestPolyStruct2< ::sal_Unicode, css::uno::Any> > > arg36; 291*cdf0e10cSrcweir css::uno::Sequence<ttb::TestPolyStruct<ttb::TestPolyStruct2< 292*cdf0e10cSrcweir ttb::TestPolyStruct2< ::sal_Unicode,css::uno::Any >, ::rtl::OUString> > > arg37; 293*cdf0e10cSrcweir css::uno::Sequence<ttb::TestPolyStruct2< ::rtl::OUString, ttb::TestPolyStruct2< 294*cdf0e10cSrcweir ::sal_Unicode, ttb::TestPolyStruct<css::uno::Any> > > > arg38; 295*cdf0e10cSrcweir css::uno::Sequence<ttb::TestPolyStruct2<ttb::TestPolyStruct2< 296*cdf0e10cSrcweir ::sal_Unicode, css::uno::Any>, ttb::TestPolyStruct< ::sal_Unicode> > > arg39; 297*cdf0e10cSrcweir css::uno::Sequence<css::uno::Sequence<ttb::TestPolyStruct< ::sal_Unicode> > > arg40; 298*cdf0e10cSrcweir css::uno::Sequence<css::uno::Sequence<ttb::TestPolyStruct<ttb::TestPolyStruct2< ::sal_Unicode, css::uno::Any> > > >arg41; 299*cdf0e10cSrcweir css::uno::Sequence<css::uno::Sequence<ttb::TestPolyStruct< 300*cdf0e10cSrcweir ttb::TestPolyStruct2<ttb::TestPolyStruct2<sal_Unicode, css::uno::Any>, ::rtl::OUString> > > > arg42; 301*cdf0e10cSrcweir css::uno::Sequence<css::uno::Sequence<ttb::TestPolyStruct2< 302*cdf0e10cSrcweir ::rtl::OUString, ttb::TestPolyStruct2< ::sal_Unicode, ttb::TestPolyStruct<css::uno::Any> > > > > arg43; 303*cdf0e10cSrcweir css::uno::Sequence<css::uno::Sequence<ttb::TestPolyStruct2< 304*cdf0e10cSrcweir ttb::TestPolyStruct2< ::sal_Unicode, css::uno::Any>, ttb::TestPolyStruct< 305*cdf0e10cSrcweir ::sal_Unicode> > > > arg44; 306*cdf0e10cSrcweir 307*cdf0e10cSrcweir if (!(arguments.getLength() == 45 308*cdf0e10cSrcweir && (arguments[0] >>= arg0) && arg0.member == cppu::UnoType<sal_Int32>::get() 309*cdf0e10cSrcweir && (arguments[1] >>= arg1) && arg1.member == arg1b 310*cdf0e10cSrcweir && (arguments[2] >>= arg2) && arg2.member == sal_True 311*cdf0e10cSrcweir && (arguments[3] >>= arg3) && arg3.member == SAL_MIN_INT8 312*cdf0e10cSrcweir && (arguments[4] >>= arg4) && arg4.member == SAL_MIN_INT16 313*cdf0e10cSrcweir && (arguments[5] >>= arg5) && arg5.member == SAL_MIN_INT32 314*cdf0e10cSrcweir && (arguments[6] >>= arg6) && arg6.member == SAL_MIN_INT64 315*cdf0e10cSrcweir && (arguments[7] >>= arg7) && arg7.member == 'X' 316*cdf0e10cSrcweir && (arguments[8] >>= arg8) && arg8.member.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 317*cdf0e10cSrcweir && (arguments[9] >>= arg9) && arg9.member == 0.123f 318*cdf0e10cSrcweir && (arguments[10] >>= arg10) && arg10.member == 0.456 319*cdf0e10cSrcweir && (arguments[11] >>= arg11) 320*cdf0e10cSrcweir && (arguments[12] >>= arg12) 321*cdf0e10cSrcweir && (arguments[13] >>= arg13) && arg13.member == ttb::TestEnum_TWO 322*cdf0e10cSrcweir && (arguments[14] >>= arg14) && arg14.member.member1 == 'X' && arg14.member.member2 == arg1b 323*cdf0e10cSrcweir && (arguments[15] >>= arg15) && arg15.member.member1.member1 == 'X' 324*cdf0e10cSrcweir && arg15.member.member1.member2 == arg1b 325*cdf0e10cSrcweir && arg15.member.member2.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 326*cdf0e10cSrcweir && (arguments[16] >>= arg16) && arg16.member1.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 327*cdf0e10cSrcweir && arg16.member2.member1 == 'X' 328*cdf0e10cSrcweir && arg16.member2.member2.member == arg1b 329*cdf0e10cSrcweir && (arguments[17] >>= arg17) && arg17.member1.member1 == 'X' 330*cdf0e10cSrcweir && arg17.member1.member2 == arg1b 331*cdf0e10cSrcweir && arg17.member2.member == 'X' 332*cdf0e10cSrcweir && (arguments[18] >>= arg18) && arg18.member.getLength() == 1 333*cdf0e10cSrcweir && arg18.member[0] == ::cppu::UnoType<sal_Int32>::get() 334*cdf0e10cSrcweir && (arguments[19] >>= arg19) && arg19.member.getLength() == 1 335*cdf0e10cSrcweir && arg19.member[0] == arg1b 336*cdf0e10cSrcweir && (arguments[20] >>= arg20) && arg20.member.getLength() == 1 337*cdf0e10cSrcweir && arg20.member[0] == sal_True 338*cdf0e10cSrcweir && (arguments[21] >>= arg21) && arg21.member.getLength() == 1 339*cdf0e10cSrcweir && arg21.member[0] == SAL_MIN_INT8 340*cdf0e10cSrcweir && (arguments[22] >>= arg22) && arg22.member.getLength() == 1 341*cdf0e10cSrcweir && arg22.member[0] == SAL_MIN_INT16 342*cdf0e10cSrcweir && (arguments[23] >>= arg23) && arg23.member.getLength() == 1 343*cdf0e10cSrcweir && arg23.member[0] == SAL_MIN_INT32 344*cdf0e10cSrcweir && (arguments[24] >>= arg24) && arg24.member.getLength() == 1 345*cdf0e10cSrcweir && arg24.member[0] == SAL_MIN_INT64 346*cdf0e10cSrcweir && (arguments[25].getValueType() 347*cdf0e10cSrcweir == ::cppu::UnoType< ttb::TestPolyStruct< ::cppu::UnoSequenceType< 348*cdf0e10cSrcweir ::cppu::UnoCharType> > >::get()) 349*cdf0e10cSrcweir && (static_cast< ttb::TestPolyStruct<css::uno::Sequence< 350*cdf0e10cSrcweir ::sal_Unicode> > const *>(arguments[25].getValue())->member[0]) == 'X' 351*cdf0e10cSrcweir && (arguments[26] >>= arg26) && arg26.member.getLength() == 1 352*cdf0e10cSrcweir && arg26.member[0].equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 353*cdf0e10cSrcweir && (arguments[27] >>= arg27) && arg27.member.getLength() == 1 354*cdf0e10cSrcweir && arg27.member[0] == 0.123f 355*cdf0e10cSrcweir && (arguments[28] >>= arg28) && arg28.member.getLength() == 1 356*cdf0e10cSrcweir && arg28.member[0] == 0.456 357*cdf0e10cSrcweir && (arguments[29] >>= arg29) && arg29.member.getLength() == 1 358*cdf0e10cSrcweir && arg29.member[0] != NULL 359*cdf0e10cSrcweir && (arguments[30] >>= arg30) && arg30.member.getLength() == 1 360*cdf0e10cSrcweir && arg30.member[0] != NULL 361*cdf0e10cSrcweir && (arguments[31] >>= arg31) && arg31.member.getLength() == 1 362*cdf0e10cSrcweir && arg31.member[0] == ttb::TestEnum_TWO 363*cdf0e10cSrcweir && (arguments[32] >>= arg32) && arg32.member.getLength() == 1 364*cdf0e10cSrcweir && arg32.member[0].member1 == 'X' 365*cdf0e10cSrcweir && arg32.member[0].member2.getLength() == 1 366*cdf0e10cSrcweir && (arg32.member[0].member2[0] >>= arg32a) && arg32a == true 367*cdf0e10cSrcweir && (arguments[33] >>= arg33) && arg33.member.getLength() == 1 368*cdf0e10cSrcweir && arg33.member[0].member1.member == 'X' 369*cdf0e10cSrcweir && arg33.member[0].member2.getLength() == 1 370*cdf0e10cSrcweir && arg33.member[0].member2[0] == arg1b 371*cdf0e10cSrcweir && (arguments[34] >>= arg34) && arg34.member.getLength() == 1 372*cdf0e10cSrcweir && arg34.member[0].getLength() == 1 && arg34.member[0][0] == SAL_MIN_INT32 373*cdf0e10cSrcweir && (arguments[35] >>= arg35) && arg35.getLength() == 1 374*cdf0e10cSrcweir && arg35[0].member == SAL_MIN_INT32 375*cdf0e10cSrcweir && (arguments[36] >>= arg36) && arg36.getLength() == 1 376*cdf0e10cSrcweir && arg36[0].member.member1 == 'X' 377*cdf0e10cSrcweir && arg36[0].member.member2 == arg1b 378*cdf0e10cSrcweir && (arguments[37] >>= arg37) && arg37.getLength() == 1 379*cdf0e10cSrcweir && arg37[0].member.member1.member1 == 'X' 380*cdf0e10cSrcweir && arg37[0].member.member1.member2 == arg1b 381*cdf0e10cSrcweir && arg37[0].member.member2.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 382*cdf0e10cSrcweir && (arguments[38] >>= arg38) && arg38.getLength() == 1 383*cdf0e10cSrcweir && arg38[0].member1.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 384*cdf0e10cSrcweir && arg38[0].member2.member1 == 'X' 385*cdf0e10cSrcweir && arg38[0].member2.member2.member == arg1b 386*cdf0e10cSrcweir && (arguments[39] >>= arg39) && arg39.getLength() == 1 387*cdf0e10cSrcweir && arg39[0].member1.member1 == 'X' 388*cdf0e10cSrcweir && arg39[0].member1.member2 == arg1b 389*cdf0e10cSrcweir && arg39[0].member2.member == 'X' 390*cdf0e10cSrcweir && (arguments[40] >>= arg40) && arg40.getLength() == 1 391*cdf0e10cSrcweir && arg40[0].getLength() == 1 392*cdf0e10cSrcweir && arg40[0][0].member == 'X' 393*cdf0e10cSrcweir && (arguments[41] >>= arg41) && arg41.getLength() == 1 394*cdf0e10cSrcweir && arg41[0].getLength() == 1 395*cdf0e10cSrcweir && arg41[0][0].member.member1 == 'X' 396*cdf0e10cSrcweir && arg41[0][0].member.member2 == arg1b 397*cdf0e10cSrcweir && (arguments[42] >>= arg42) && arg42.getLength() == 1 398*cdf0e10cSrcweir && arg42[0].getLength() == 1 399*cdf0e10cSrcweir && arg42[0][0].member.member1.member1 == 'X' 400*cdf0e10cSrcweir && arg42[0][0].member.member1.member2 == arg1b 401*cdf0e10cSrcweir && arg42[0][0].member.member2.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 402*cdf0e10cSrcweir && (arguments[43] >>= arg43) && arg43.getLength() == 1 403*cdf0e10cSrcweir && arg43[0].getLength() == 1 404*cdf0e10cSrcweir && arg43[0][0].member1.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("test")) 405*cdf0e10cSrcweir && arg43[0][0].member2.member1 == 'X' 406*cdf0e10cSrcweir && arg43[0][0].member2.member2.member == arg1b 407*cdf0e10cSrcweir && (arguments[44] >>= arg44) && arg44.getLength() == 1 408*cdf0e10cSrcweir && arg44[0].getLength() == 1 409*cdf0e10cSrcweir && arg44[0][0].member1.member1 == 'X' 410*cdf0e10cSrcweir && arg44[0][0].member1.member2 == arg1b 411*cdf0e10cSrcweir && arg44[0][0].member2.member == 'X' 412*cdf0e10cSrcweir )) 413*cdf0e10cSrcweir { 414*cdf0e10cSrcweir throw ::test::testtools::bridgetest::BadConstructorArguments(); 415*cdf0e10cSrcweir } 416*cdf0e10cSrcweir 417*cdf0e10cSrcweir //check if interfaces work 418*cdf0e10cSrcweir arg11.member->acquire(); 419*cdf0e10cSrcweir arg11.member->release(); 420*cdf0e10cSrcweir arg12.member->acquire(); 421*cdf0e10cSrcweir arg12.member->release(); 422*cdf0e10cSrcweir arg29.member[0]->acquire(); 423*cdf0e10cSrcweir arg29.member[0]->release(); 424*cdf0e10cSrcweir 425*cdf0e10cSrcweir } 426*cdf0e10cSrcweir 427*cdf0e10cSrcweir //XMultiBase1 428*cdf0e10cSrcweir double Impl2::getatt1() 429*cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException) 430*cdf0e10cSrcweir { 431*cdf0e10cSrcweir return m_attr1; 432*cdf0e10cSrcweir } 433*cdf0e10cSrcweir 434*cdf0e10cSrcweir void Impl2::setatt1( double _att1 )throw (::com::sun::star::uno::RuntimeException) 435*cdf0e10cSrcweir { 436*cdf0e10cSrcweir m_attr1 = _att1; 437*cdf0e10cSrcweir } 438*cdf0e10cSrcweir 439*cdf0e10cSrcweir ::sal_Int32 Impl2::fn11( ::sal_Int32 arg ) 440*cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException) 441*cdf0e10cSrcweir { 442*cdf0e10cSrcweir return 11 * arg; 443*cdf0e10cSrcweir } 444*cdf0e10cSrcweir 445*cdf0e10cSrcweir ::rtl::OUString Impl2::fn12( const ::rtl::OUString& arg ) 446*cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException) 447*cdf0e10cSrcweir { 448*cdf0e10cSrcweir return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("12")) + arg; 449*cdf0e10cSrcweir } 450*cdf0e10cSrcweir 451*cdf0e10cSrcweir css::uno::Reference< css::uno::XInterface > SAL_CALL create( 452*cdf0e10cSrcweir css::uno::Reference< css::uno::XComponentContext > const &) 453*cdf0e10cSrcweir SAL_THROW((css::uno::Exception)) 454*cdf0e10cSrcweir { 455*cdf0e10cSrcweir return static_cast< ::cppu::OWeakObject * >(new Impl); 456*cdf0e10cSrcweir } 457*cdf0e10cSrcweir 458*cdf0e10cSrcweir ::rtl::OUString SAL_CALL getImplementationName() { 459*cdf0e10cSrcweir return ::rtl::OUString( 460*cdf0e10cSrcweir RTL_CONSTASCII_USTRINGPARAM( 461*cdf0e10cSrcweir "comp.test.testtools.bridgetest.Constructors")); 462*cdf0e10cSrcweir } 463*cdf0e10cSrcweir 464*cdf0e10cSrcweir css::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() { 465*cdf0e10cSrcweir css::uno::Sequence< ::rtl::OUString > s(1); 466*cdf0e10cSrcweir s[0] = ::rtl::OUString( 467*cdf0e10cSrcweir RTL_CONSTASCII_USTRINGPARAM("test.testtools.bridgetest.Constructors")); 468*cdf0e10cSrcweir return s; 469*cdf0e10cSrcweir } 470*cdf0e10cSrcweir 471*cdf0e10cSrcweir css::uno::Reference< css::uno::XInterface > SAL_CALL create2( 472*cdf0e10cSrcweir css::uno::Reference< css::uno::XComponentContext > const &) 473*cdf0e10cSrcweir SAL_THROW((css::uno::Exception)) 474*cdf0e10cSrcweir { 475*cdf0e10cSrcweir return static_cast< ::cppu::OWeakObject * >(new Impl2); 476*cdf0e10cSrcweir } 477*cdf0e10cSrcweir 478*cdf0e10cSrcweir ::rtl::OUString SAL_CALL getImplementationName2() { 479*cdf0e10cSrcweir return ::rtl::OUString( 480*cdf0e10cSrcweir RTL_CONSTASCII_USTRINGPARAM( 481*cdf0e10cSrcweir "comp.test.testtools.bridgetest.Constructors2")); 482*cdf0e10cSrcweir } 483*cdf0e10cSrcweir 484*cdf0e10cSrcweir css::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames2() { 485*cdf0e10cSrcweir css::uno::Sequence< ::rtl::OUString > s(1); 486*cdf0e10cSrcweir s[0] = ::rtl::OUString( 487*cdf0e10cSrcweir RTL_CONSTASCII_USTRINGPARAM("test.testtools.bridgetest.Constructors2")); 488*cdf0e10cSrcweir return s; 489*cdf0e10cSrcweir } 490*cdf0e10cSrcweir 491*cdf0e10cSrcweir ::cppu::ImplementationEntry entries[] = { 492*cdf0e10cSrcweir { &create, &getImplementationName, &getSupportedServiceNames, 493*cdf0e10cSrcweir &::cppu::createSingleComponentFactory, 0, 0 }, 494*cdf0e10cSrcweir { &create2, &getImplementationName2, &getSupportedServiceNames2, 495*cdf0e10cSrcweir &::cppu::createSingleComponentFactory, 0, 0 }, 496*cdf0e10cSrcweir { 0, 0, 0, 0, 0, 0 } }; 497*cdf0e10cSrcweir } 498*cdf0e10cSrcweir 499*cdf0e10cSrcweir extern "C" void * SAL_CALL component_getFactory( 500*cdf0e10cSrcweir char const * implName, void * serviceManager, void * registryKey) 501*cdf0e10cSrcweir { 502*cdf0e10cSrcweir return ::cppu::component_getFactoryHelper( 503*cdf0e10cSrcweir implName, serviceManager, registryKey, entries); 504*cdf0e10cSrcweir } 505*cdf0e10cSrcweir 506*cdf0e10cSrcweir extern "C" void SAL_CALL component_getImplementationEnvironment( 507*cdf0e10cSrcweir char const ** envTypeName, uno_Environment **) 508*cdf0e10cSrcweir { 509*cdf0e10cSrcweir *envTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME; 510*cdf0e10cSrcweir } 511