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: parsenv2.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 <s2_luidl/parsenv2.hxx>
35 // NOT FULLY DEFINED SERVICES
36 #include <ary/ary.hxx>
37 #include <ary/getncast.hxx>
38 #include <ary/qualiname.hxx>
39 #include <ary/doc/d_oldidldocu.hxx>
40 #include <ary/idl/i_gate.hxx>
41 #include <ary/idl/i_ce.hxx>
42 #include <ary/idl/i_enum.hxx>
43 #include <ary/idl/i_enumvalue.hxx>
44 #include <ary/idl/i_module.hxx>
45 #include <ary/idl/ip_ce.hxx>
46 #include <parser/parserinfo.hxx>
47 #include <adc_msg.hxx>
48 #include <s2_luidl/uidl_tok.hxx>
49 #include <x_parse2.hxx>
60 UnoIDL_PE::~UnoIDL_PE()
65 UnoIDL_PE::EstablishContacts( UnoIDL_PE
* io_pParentPE
,
66 ary::Repository
& io_rRepository
,
67 TokenProcessing_Result
& o_rResult
)
69 pRepository
= &io_rRepository
;
70 aMyNode
.EstablishContacts(io_pParentPE
, io_rRepository
.Gate_Idl(), o_rResult
);
74 //UnoIDL_PE::EstablishContacts( UnoIDL_PE * io_pParentPE,
75 // ary::idl::Gate & io_rGate,
76 // TokenProcessing_Result & o_rResult )
78 // aMyNode.EstablishContacts(io_pParentPE, io_rGate, o_rResult);
82 UnoIDL_PE::Enter( E_EnvStackAction i_eWayOfEntering
)
84 switch (i_eWayOfEntering
)
96 throw X_AutodocParser(X_AutodocParser::x_Any
);
97 // no break because of throw
104 UnoIDL_PE::Leave( E_EnvStackAction i_eWayOfLeaving
)
106 switch (i_eWayOfLeaving
)
117 throw X_AutodocParser(X_AutodocParser::x_Any
);
118 // no break because of throw
125 UnoIDL_PE::SetDocu( DYN
ary::doc::OldIdlDocu
* let_dpDocu
)
131 UnoIDL_PE::SetPublished()
135 pDocu
= new ary::doc::OldIdlDocu
;
137 pDocu
->SetPublished();
141 UnoIDL_PE::SetOptional()
145 pDocu
= new ary::doc::OldIdlDocu
;
147 pDocu
->SetOptional();
151 UnoIDL_PE::PassDocuAt( ary::idl::CodeEntity
& io_rCe
)
155 io_rCe
.Set_Docu(*pDocu
.Release());
157 else if // KORR_FUTURE
158 // Re-enable doc-warning for Enum Values, as soon as there is a
159 // @option -no-doc-for-enumvalues.
160 ( NOT
ary::is_type
<ary::idl::Module
>(io_rCe
)
161 AND NOT
ary::is_type
<ary::idl::Enum
>(io_rCe
) )
163 TheMessages().Out_MissingDoc(
165 ParseInfo().CurFile(),
166 ParseInfo().CurLine() );
171 UnoIDL_PE::InitData()
173 // Needs not anything to do.
177 UnoIDL_PE::ReceiveData()
179 // Needs not anything to do.
182 const ary::idl::Module
&
183 UnoIDL_PE::CurNamespace() const
186 return Parent()->CurNamespace();
190 return *(const ary::idl::Module
*)0;
195 UnoIDL_PE::ParseInfo() const
198 return Parent()->ParseInfo();
202 return *(const ParserInfo
*)0;
206 UnoIDL_PE::UnoIDL_PE()