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_idl.hxx" 30*cdf0e10cSrcweir 31*cdf0e10cSrcweir /****************** I N C L U D E S **************************************/ 32*cdf0e10cSrcweir #include <tools/shl.hxx> 33*cdf0e10cSrcweir 34*cdf0e10cSrcweir #include <globals.hxx> 35*cdf0e10cSrcweir #include <database.hxx> 36*cdf0e10cSrcweir 37*cdf0e10cSrcweir /****************** G L O B A L S ****************************************/ 38*cdf0e10cSrcweir IdlDll * GetIdlApp() 39*cdf0e10cSrcweir { 40*cdf0e10cSrcweir if( !(*(IdlDll**)GetAppData(SHL_IDL)) ) 41*cdf0e10cSrcweir { 42*cdf0e10cSrcweir (*(IdlDll**)GetAppData(SHL_IDL)) = new IdlDll(); 43*cdf0e10cSrcweir // Temporaer, sonst nur wenn Compiler 44*cdf0e10cSrcweir //GetIdlApp()->pHashTable = new SvStringHashTable( 2801 ); 45*cdf0e10cSrcweir //GetIdlApp()->pGlobalNames = new SvGlobalHashNames(); 46*cdf0e10cSrcweir } 47*cdf0e10cSrcweir return (*(IdlDll**)GetAppData(SHL_IDL)); 48*cdf0e10cSrcweir } 49*cdf0e10cSrcweir 50*cdf0e10cSrcweir IdlDll::IdlDll() 51*cdf0e10cSrcweir : pHashTable( NULL ) 52*cdf0e10cSrcweir , pClassMgr( NULL ) 53*cdf0e10cSrcweir , pGlobalNames( NULL ) 54*cdf0e10cSrcweir 55*cdf0e10cSrcweir { 56*cdf0e10cSrcweir pClassMgr = new SvClassManager(); 57*cdf0e10cSrcweir // File OBJECT.HXX: 58*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaAttribute ); 59*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaClass ); 60*cdf0e10cSrcweir //File SLOT.HXX: 61*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaSlot ); 62*cdf0e10cSrcweir //File MODULE.HXX: 63*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaModule ); 64*cdf0e10cSrcweir //File BASOBJ.HXX: 65*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaObject ); 66*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaName ); 67*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaExtern ); 68*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaReference ); 69*cdf0e10cSrcweir //File TYPES.HXX: 70*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaType ); 71*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaTypeString ); 72*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaEnumValue ); 73*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaTypeEnum ); 74*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvMetaTypevoid ); 75*cdf0e10cSrcweir pClassMgr->SV_CLASS_REGISTER( SvClassElement ); 76*cdf0e10cSrcweir } 77*cdf0e10cSrcweir 78*cdf0e10cSrcweir IdlDll::~IdlDll() 79*cdf0e10cSrcweir { 80*cdf0e10cSrcweir delete pGlobalNames; 81*cdf0e10cSrcweir delete pClassMgr; 82*cdf0e10cSrcweir delete pHashTable; 83*cdf0e10cSrcweir } 84*cdf0e10cSrcweir 85*cdf0e10cSrcweir /************************************************************************* 86*cdf0e10cSrcweir |* 87*cdf0e10cSrcweir |* SvGlobalHashNames::SvGlobalHashNames() 88*cdf0e10cSrcweir |* 89*cdf0e10cSrcweir |* Beschreibung 90*cdf0e10cSrcweir |* Ersterstellung MM 08.08.91 91*cdf0e10cSrcweir |* Letzte Aenderung MM 08.08.91 92*cdf0e10cSrcweir |* 93*cdf0e10cSrcweir *************************************************************************/ 94*cdf0e10cSrcweir inline SvStringHashEntry * INS( const ByteString & rName ) 95*cdf0e10cSrcweir { 96*cdf0e10cSrcweir sal_uInt32 nIdx; 97*cdf0e10cSrcweir IDLAPP->pHashTable->Insert( rName, &nIdx ); 98*cdf0e10cSrcweir return (SvStringHashEntry * )IDLAPP->pHashTable->Get( nIdx ); 99*cdf0e10cSrcweir } 100*cdf0e10cSrcweir #define A_ENTRY( Name ) , MM_##Name( INS( #Name ) ) 101*cdf0e10cSrcweir 102*cdf0e10cSrcweir SvGlobalHashNames::SvGlobalHashNames() 103*cdf0e10cSrcweir : MM_Name( INS( "Name" ) ) 104*cdf0e10cSrcweir , MM_module( INS( "module" ) ) 105*cdf0e10cSrcweir , MM_interface( INS( "interface" ) ) 106*cdf0e10cSrcweir , MM_in( INS( "in" ) ) 107*cdf0e10cSrcweir , MM_out( INS( "out" ) ) 108*cdf0e10cSrcweir , MM_inout( INS( "inout" ) ) 109*cdf0e10cSrcweir , MM_String( INS( "String" ) ) 110*cdf0e10cSrcweir , MM_UCHAR( INS( "UCHAR" ) ) 111*cdf0e10cSrcweir , MM_USHORT( INS( "USHORT" ) ) 112*cdf0e10cSrcweir , MM_uuid( INS( "uuid" ) ) 113*cdf0e10cSrcweir , MM_HelpContext( INS( "HelpContext" ) ) 114*cdf0e10cSrcweir , MM_HelpText( INS( "HelpText" ) ) 115*cdf0e10cSrcweir , MM_void( INS( "void" ) ) 116*cdf0e10cSrcweir , MM_shell( INS( "shell" ) ) 117*cdf0e10cSrcweir , MM_Get( INS( "Get" ) ) 118*cdf0e10cSrcweir , MM_Set( INS( "Set" ) ) 119*cdf0e10cSrcweir , MM_SlotId( INS( "SlotId" ) ) 120*cdf0e10cSrcweir , MM_HasCoreId( INS( "HasCoreId" ) ) 121*cdf0e10cSrcweir , MM_Cachable( INS( "Cachable" ) ) 122*cdf0e10cSrcweir // , MM_Volatile( INS( "Volatile" ) ) 123*cdf0e10cSrcweir , MM_Toggle( INS( "Toggle" ) ) 124*cdf0e10cSrcweir , MM_AutoUpdate( INS( "AutoUpdate" ) ) 125*cdf0e10cSrcweir , MM_Synchron( INS( "Synchron" ) ) 126*cdf0e10cSrcweir , MM_Asynchron( INS( "Asynchron" ) ) 127*cdf0e10cSrcweir A_ENTRY(RecordPerSet) 128*cdf0e10cSrcweir A_ENTRY(RecordPerItem) 129*cdf0e10cSrcweir A_ENTRY(RecordManual) 130*cdf0e10cSrcweir A_ENTRY(NoRecord) 131*cdf0e10cSrcweir A_ENTRY(RecordAbsolute) 132*cdf0e10cSrcweir A_ENTRY(enum) 133*cdf0e10cSrcweir A_ENTRY(UINT16) 134*cdf0e10cSrcweir A_ENTRY(INT16) 135*cdf0e10cSrcweir A_ENTRY(UINT32) 136*cdf0e10cSrcweir A_ENTRY(INT32) 137*cdf0e10cSrcweir A_ENTRY(int) 138*cdf0e10cSrcweir A_ENTRY(BOOL) 139*cdf0e10cSrcweir A_ENTRY(char) 140*cdf0e10cSrcweir A_ENTRY(BYTE) 141*cdf0e10cSrcweir A_ENTRY(float) 142*cdf0e10cSrcweir A_ENTRY(double) 143*cdf0e10cSrcweir A_ENTRY(item) 144*cdf0e10cSrcweir A_ENTRY(PseudoSlots) 145*cdf0e10cSrcweir A_ENTRY(map) 146*cdf0e10cSrcweir A_ENTRY(Default) 147*cdf0e10cSrcweir A_ENTRY(HelpFile) 148*cdf0e10cSrcweir A_ENTRY(Version) 149*cdf0e10cSrcweir A_ENTRY(import) 150*cdf0e10cSrcweir A_ENTRY(SlotIdFile) 151*cdf0e10cSrcweir A_ENTRY(SvName) 152*cdf0e10cSrcweir A_ENTRY(SbxName) 153*cdf0e10cSrcweir A_ENTRY(ItemName) 154*cdf0e10cSrcweir A_ENTRY(OdlName) 155*cdf0e10cSrcweir A_ENTRY(include) 156*cdf0e10cSrcweir A_ENTRY(ExecMethod) 157*cdf0e10cSrcweir A_ENTRY(StateMethod) 158*cdf0e10cSrcweir A_ENTRY(GroupId) 159*cdf0e10cSrcweir A_ENTRY(HasDialog) 160*cdf0e10cSrcweir A_ENTRY(TypeLibFile) 161*cdf0e10cSrcweir A_ENTRY(Export) 162*cdf0e10cSrcweir A_ENTRY(Automation) 163*cdf0e10cSrcweir A_ENTRY(PseudoPrefix) 164*cdf0e10cSrcweir A_ENTRY(define) 165*cdf0e10cSrcweir A_ENTRY(MenuConfig) 166*cdf0e10cSrcweir A_ENTRY(ToolBoxConfig) 167*cdf0e10cSrcweir A_ENTRY(StatusBarConfig) 168*cdf0e10cSrcweir A_ENTRY(AccelConfig) 169*cdf0e10cSrcweir A_ENTRY(AllConfig) 170*cdf0e10cSrcweir A_ENTRY(FastCall) 171*cdf0e10cSrcweir A_ENTRY(SbxObject) 172*cdf0e10cSrcweir A_ENTRY(Container) 173*cdf0e10cSrcweir A_ENTRY(ImageRotation) 174*cdf0e10cSrcweir A_ENTRY(ImageReflection) 175*cdf0e10cSrcweir A_ENTRY(IsCollection) 176*cdf0e10cSrcweir A_ENTRY(ReadOnlyDoc) 177*cdf0e10cSrcweir A_ENTRY(ConfigName) 178*cdf0e10cSrcweir A_ENTRY(union) 179*cdf0e10cSrcweir A_ENTRY(struct) 180*cdf0e10cSrcweir A_ENTRY(typedef) 181*cdf0e10cSrcweir A_ENTRY(Readonly) 182*cdf0e10cSrcweir A_ENTRY(SlotType) 183*cdf0e10cSrcweir A_ENTRY(ModulePrefix) 184*cdf0e10cSrcweir A_ENTRY(DisableFlags) 185*cdf0e10cSrcweir A_ENTRY(Hidden) 186*cdf0e10cSrcweir A_ENTRY(Description) 187*cdf0e10cSrcweir A_ENTRY(UnoName) 188*cdf0e10cSrcweir {} 189*cdf0e10cSrcweir 190