1 /*************************************************************************
2  *
3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4  *
5  * Copyright 2000, 2010 Oracle and/or its affiliates.
6  *
7  * OpenOffice.org - a multi-platform office productivity suite
8  *
9  * This file is part of OpenOffice.org.
10  *
11  * OpenOffice.org is free software: you can redistribute it and/or modify
12  * it under the terms of the GNU Lesser General Public License version 3
13  * only, as published by the Free Software Foundation.
14  *
15  * OpenOffice.org is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU Lesser General Public License version 3 for more details
19  * (a copy is included in the LICENSE file that accompanied this code).
20  *
21  * You should have received a copy of the GNU Lesser General Public License
22  * version 3 along with OpenOffice.org.  If not, see
23  * <http://www.openoffice.org/license.html>
24  * for a copy of the LGPLv3 License.
25  *
26  ************************************************************************/
27 
28 #ifndef ADC_UIDL_PE_VARI2_HXX
29 #define ADC_UIDL_PE_VARI2_HXX
30 
31 
32 
33 // USED SERVICES
34 	// BASE CLASSES
35 #include <s2_luidl/parsenv2.hxx>
36 #include <s2_luidl/pestate.hxx>
37 	// COMPONENTS
38 	// PARAMETERS
39 
40 
41 namespace csi
42 {
43 namespace uidl
44 {
45 
46 
47 class PE_Type;
48 
49 
50 class PE_Variable : public UnoIDL_PE,
51 					public ParseEnvState
52 {
53   public:
54 						PE_Variable(
55 							ary::idl::Type_id &	i_rResult_Type,
56 							String &	        i_rResult_Name );
57 	virtual void	 	EstablishContacts(
58 							UnoIDL_PE *			io_pParentPE,
59 							ary::Repository &
60                                                 io_rRepository,
61 							TokenProcessing_Result &
62 												o_rResult );
63 	virtual				~PE_Variable();
64 
65 	virtual void	  	ProcessToken(
66 							const Token &		i_rToken );
67 
68 	virtual void		Process_Default();
69 	virtual void		Process_Identifier(
70 							const TokIdentifier &
71 												i_rToken );
72 	virtual void		Process_Punctuation(
73 							const TokPunctuation &
74 												i_rToken );
75 	virtual void		Process_BuiltInType(
76 							const TokBuiltInType &
77 												i_rToken );
78   private:
79 	enum E_State
80 	{
81 		e_none,
82 		expect_type,
83 		expect_name,
84 		expect_finish
85 	};
86 
87 	virtual void		InitData();
88 	virtual void		ReceiveData();
89 	virtual void		TransferData();
90 	virtual UnoIDL_PE &	MyPE();
91 
92     // DATA
93 	E_State             eState;
94 	ary::idl::Type_id *	pResult_Type;
95 	String *	        pResult_Name;
96 
97 	Dyn<PE_Type>		pPE_Type;
98 };
99 
100 
101 
102 }   // namespace uidl
103 }   // namespace csi
104 
105 
106 #endif
107 
108