1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: icprivow.cxx,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
32 #include <icprivow.hxx>
35 // NOT FULLY DEFINED SERVICES
36 #include <ary/cpp/c_namesp.hxx>
37 #include <ary/cpp/c_class.hxx>
46 //****************** Owner_Namespace ********************//
47 Owner_Namespace::Owner_Namespace()
53 Owner_Namespace::SetAnotherNamespace( ary::cpp::Namespace
& io_rScope
)
59 Owner_Namespace::HasClass( const String
& i_sLocalName
)
61 return pScope
->Search_LocalClass(i_sLocalName
).IsValid();
65 Owner_Namespace::do_Add_Class( const String
& i_sLocalName
,
68 csv_assert(pScope
!= 0);
69 pScope
->Add_LocalClass(i_sLocalName
, i_nId
);
73 Owner_Namespace::do_Add_Enum( const String
& i_sLocalName
,
76 csv_assert(pScope
!= 0);
77 pScope
->Add_LocalEnum(i_sLocalName
, i_nId
);
81 Owner_Namespace::do_Add_Typedef( const String
& i_sLocalName
,
84 csv_assert(pScope
!= 0);
85 pScope
->Add_LocalTypedef(i_sLocalName
, i_nId
);
89 Owner_Namespace::do_Add_Operation( const String
& i_sLocalName
,
93 csv_assert(pScope
!= 0);
94 pScope
->Add_LocalOperation(i_sLocalName
, i_nId
);
98 Owner_Namespace::do_Add_Variable( const String
& i_sLocalName
,
103 csv_assert(pScope
!= 0);
105 pScope
->Add_LocalConstant(i_sLocalName
, i_nId
);
107 pScope
->Add_LocalVariable(i_sLocalName
, i_nId
);
112 Owner_Namespace::inq_CeId() const
114 csv_assert(pScope
!= 0);
115 return pScope
->CeId();
119 //****************** Owner_Class ********************//
121 Owner_Class::Owner_Class()
127 Owner_Class::SetAnotherClass( ary::cpp::Class
& io_rScope
)
133 Owner_Class::HasClass( const String
& )
139 Owner_Class::do_Add_Class( const String
& i_sLocalName
,
142 csv_assert(pScope
!= 0);
143 pScope
->Add_LocalClass(i_sLocalName
, i_nId
);
147 Owner_Class::do_Add_Enum( const String
& i_sLocalName
,
150 csv_assert(pScope
!= 0);
151 pScope
->Add_LocalEnum(i_sLocalName
, i_nId
);
155 Owner_Class::do_Add_Typedef( const String
& i_sLocalName
,
158 csv_assert(pScope
!= 0);
159 pScope
->Add_LocalTypedef(i_sLocalName
, i_nId
);
163 Owner_Class::do_Add_Operation( const String
& i_sLocalName
,
167 csv_assert(pScope
!= 0);
169 pScope
->Add_LocalStaticOperation(i_sLocalName
, i_nId
);
171 pScope
->Add_LocalOperation(i_sLocalName
, i_nId
);
175 Owner_Class::do_Add_Variable( const String
& i_sLocalName
,
180 csv_assert(pScope
!= 0);
182 pScope
->Add_LocalStaticData(i_sLocalName
, i_nId
);
184 pScope
->Add_LocalData(i_sLocalName
, i_nId
);
188 Owner_Class::inq_CeId() const
190 csv_assert(pScope
!= 0);
191 return pScope
->CeId();