00001 // /******************************************************************************\ 00002 // * 00003 // * File: TypeCodeElm.cpp 00004 // * Creation date: June 14, 2001 08:46 00005 // * Author: ClassBuilder 00006 // * XXXX 00007 // * Purpose: Method implementations of class 'TypeCodeElm' 00008 // * 00009 // * Modifications: @INSERT_MODIFICATIONS(* ) 00010 // * June 19, 2001 12:44 WERS 00011 // * Deleted member 'm_pVoid' 00012 // * Updated code of method 'TypeCodeElm' 00013 // * June 19, 2001 11:19 WERS 00014 // * Updated code of method 'TypeCodeElm' 00015 // * June 19, 2001 11:18 WERS 00016 // * Updated code of method 'TypeCodeElm' 00017 // * June 19, 2001 10:45 WERS 00018 // * Added member 'm_pVoid' 00019 // * Updated interface of method 'TypeCodeElm' 00020 // * June 15, 2001 16:03 WERS 00021 // * Updated code of method 'TypeCodeElm' 00022 // * June 14, 2001 10:00 WERS 00023 // * Updated interface of method 'TypeCodeElm' 00024 // * June 14, 2001 08:46 WERS 00025 // * Added method 'DestructorInclude' 00026 // * Added method 'ConstructorInclude' 00027 // * Added method '~TypeCodeElm' 00028 // * Added method 'TypeCodeElm' 00029 // * Added relation 'TypeCodeList <>-->> TypeCodeElm' 00030 // * Added member 'm_tc' 00031 // * 00032 // * 00033 // \******************************************************************************/ 00034 //@START_USER1 00039 /* -------------------------------------------------------------- 00040 Copyright (C) 2001 LifeLine Networks BV <soap2corba@lifeline.nl> 00041 00042 This program is free software; you can redistribute it and/or 00043 modify it under the terms of the GNU General Public License 00044 as published by the Free Software Foundation; either 00045 version 2 of the License, or (at your option) any later 00046 version. 00047 00048 This program is distributed in the hope that it will be useful, 00049 but WITHOUT ANY WARRANTY; without even the implied warranty of 00050 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00051 GNU General Public License for more details. 00052 00053 You should have received a copy of the GNU General Public License 00054 along with this program; if not, write to the Free Software 00055 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00056 -------------------------------------------------------------- */ 00057 //@END_USER1 00058 00059 00060 // Master include file 00061 #include "RecurStop.h" 00062 00063 00064 //@START_USER2 00065 //@END_USER2 00066 00067 00068 // Static members 00069 00070 00074 TypeCodeElm::TypeCodeElm(TypeCodeList* pTypeCodeList, 00075 CORBA::TypeCode_ptr ptc) //@INIT_180 00076 : m_tc(CORBA::TypeCode::_duplicate (ptc)) 00077 {//@CODE_180 00078 ConstructorInclude(pTypeCodeList); 00079 00080 // Put in your own code 00081 }//@CODE_180 00082 00083 00087 TypeCodeElm::~TypeCodeElm() 00088 {//@CODE_24 00089 DestructorInclude(); 00090 00091 // Put in your own code 00092 }//@CODE_24 00093 00094 00095 //{{AFX DO NOT EDIT CODE BELOW THIS LINE !!! 00096 00100 void TypeCodeElm::ConstructorInclude(TypeCodeList* pTypeCodeList) 00101 { 00102 // INIT_MULTI_OWNED_PASSIVE(TypeCodeList, TypeCodeList, TypeCodeElm, TypeCodeElm) 00103 assert(this); 00104 assert(pTypeCodeList); 00105 pTypeCodeList->_countTypeCodeElm++; 00106 00107 _refTypeCodeList = pTypeCodeList; 00108 00109 if (pTypeCodeList->_lastTypeCodeElm) 00110 { 00111 _nextTypeCodeList = (TypeCodeElm*)0; 00112 _prevTypeCodeList = pTypeCodeList->_lastTypeCodeElm; 00113 _prevTypeCodeList->_nextTypeCodeList = this; 00114 pTypeCodeList->_lastTypeCodeElm = this; 00115 } 00116 else 00117 { 00118 _prevTypeCodeList = (TypeCodeElm*)0; 00119 _nextTypeCodeList = (TypeCodeElm*)0; 00120 pTypeCodeList->_firstTypeCodeElm = pTypeCodeList->_lastTypeCodeElm = this; 00121 } 00122 } 00123 00124 00128 void TypeCodeElm::DestructorInclude() 00129 { 00130 // EXIT_MULTI_OWNED_PASSIVE(TypeCodeList, TypeCodeList, TypeCodeElm, TypeCodeElm) 00131 00132 assert(this); 00133 if (_refTypeCodeList) 00134 { 00135 TypeCodeList::TypeCodeElmIterator::Check(this); 00136 00137 _refTypeCodeList->_countTypeCodeElm--; 00138 00139 if (_nextTypeCodeList) 00140 _nextTypeCodeList->_prevTypeCodeList = _prevTypeCodeList; 00141 else 00142 _refTypeCodeList->_lastTypeCodeElm = _prevTypeCodeList; 00143 00144 if (_prevTypeCodeList) 00145 _prevTypeCodeList->_nextTypeCodeList = _nextTypeCodeList; 00146 else 00147 _refTypeCodeList->_firstTypeCodeElm = _nextTypeCodeList; 00148 00149 _prevTypeCodeList = (TypeCodeElm*)0; 00150 _nextTypeCodeList = (TypeCodeElm*)0; 00151 _refTypeCodeList = (TypeCodeList*)0; 00152 } 00153 } 00154 00155 00156 // Methods for the relation(s) of the class 00157 // METHODS_MULTI_OWNED_PASSIVE(TypeCodeList, TypeCodeList, TypeCodeElm, TypeCodeElm) 00158 00159 //}}AFX DO NOT EDIT CODE ABOVE THIS LINE !!! 00160 00161 //@START_USER3 00162