KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > openccm > ast > lib > ProxyHomeDeclImpl


1 /*====================================================================
2
3 OpenCCM: The Open CORBA Component Model Platform
4 Copyright (C) 2000-2004 INRIA & USTL - LIFL - GOAL
5 Contact: openccm@objectweb.org
6
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Lesser General Public
9 License as published by the Free Software Foundation; either
10 version 2.1 of the License, or any later version.
11
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Lesser General Public License for more details.
16
17 You should have received a copy of the GNU Lesser General Public
18 License along with this library; if not, write to the Free Software
19 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
20 USA
21
22 Initial developer(s): Philippe Merle, Christophe Demarey.
23 Contributor(s): ______________________________________.
24
25 ====================================================================*/

26
27 package org.objectweb.openccm.ast.lib;
28
29 // Package dependencies.
30
import org.objectweb.openccm.ast.api.DeclarationKind;
31 import org.objectweb.openccm.ast.api.Declaration;
32 import org.objectweb.openccm.ast.api.StringList;
33 import org.objectweb.openccm.ast.api.DelegationList;
34
35 /**
36  * ProxyHomeDeclImpl is a wrapper class for
37  * CIDL segment declarations.
38  *
39  *
40  * Inherits from:
41  *
42  * - DeclarationImpl as they are IDL declarations,
43  *
44  * - ProxyHomeDecl: OMG IDL for ProxyHomeDecl.
45  *
46  *
47  * @author <a HREF="mailto:Philippe.Merle@lifl.fr">Philippe Merle</a>
48  * <a HREF="mailto:Christophe.Demarey@lifl.fr">Christophe Demarey</a>
49  *
50  * @version 0.2
51  */

52
53 public class ProxyHomeDeclImpl
54      extends DeclarationImpl
55   implements org.objectweb.openccm.ast.api.ProxyHomeDecl
56 {
57     // ==================================================================
58
//
59
// Internal state.
60
//
61
// ==================================================================
62

63     /** The list of abstract operations. */
64     private StringListImpl operations_;
65
66     /** The list of home delegations. */
67     private DelegationListImpl home_delegation_;
68
69     // ==================================================================
70
//
71
// Constructor.
72
//
73
// ==================================================================
74

75     /**
76      * The constructor with the parent scope.
77      *
78      * @param rep The repository of the declaration.
79      * @param parent The parent scope of the declaration.
80      */

81     protected
82     ProxyHomeDeclImpl(Repository rep,
83                       ScopeImpl parent)
84     {
85         // Call the DeclarationImpl constructor.
86
super(rep, parent);
87
88         // Init internal state.
89
operations_ = new StringListImpl();
90         home_delegation_ = new DelegationListImpl();
91     }
92
93     // ==================================================================
94
//
95
// Internal methods.
96
//
97
// ==================================================================
98

99     // ==================================================================
100
//
101
// Methods for the inherited DeclarationImpl class.
102
//
103
// ==================================================================
104

105     /**
106      * Obtain its CORBA 3.0 Contained reference.
107      *
108      * @return The Contained object associated with the any declaration.
109      */

110     protected org.omg.CORBA.Contained JavaDoc
111     getContained()
112     {
113        return null;
114     }
115
116     // ==================================================================
117
//
118
// Public methods.
119
//
120
// ==================================================================
121

122     // ==================================================================
123
//
124
// Methods for OMG IDL org.objectweb.openccm.ast.api.WithDependencies
125
//
126
// ==================================================================
127

128     /**
129      * Obtain the declaration external dependencies.
130      *
131      * Note: for scopes, contained objects are not considered
132      * as dependencies.
133      *
134      * @return The list of dependencies as an array of Declaration.
135      */

136     public Declaration[]
137     getDependencies()
138     {
139         // TO DO
140
return null;
141     };
142
143     // ==================================================================
144
//
145
// Methods for OMG IDL org.objectweb.openccm.ast.api.Declaration
146
//
147
// ==================================================================
148

149     /**
150      * Obtain its DeclarationKind.
151      *
152      * This method is implemented into DeclarationImpl subclasses.
153      *
154      * @return The DeclarationKind of the object.
155      */

156     public long
157     getDeclKind()
158     {
159       return DeclarationKind.dk_proxy_home;
160     }
161
162     /**
163       * Obtain its category (IDL, PSDL, CIDL).
164       *
165       * @return The category of the declaration.
166       */

167     public org.objectweb.openccm.ast.api.DeclarationCategory
168     getCategory()
169     {
170         return org.objectweb.openccm.ast.api.DeclarationCategory.dc_cidl;
171     }
172
173     // ==================================================================
174
//
175
// Methods for OMG IDL org.objectweb.openccm.ast.api.ProxyHomeDecl
176
//
177
// ==================================================================
178

179     /**
180      * Obtain the list of abstract operations.
181      *
182      * @return The list of abstract operations.
183      */

184     public StringList
185     getAbstractOperationList()
186     {
187         return operations_;
188     }
189
190     /**
191      * Obtain the list of home delegations.
192      *
193      * @return The list of home delegations.
194      */

195     public DelegationList
196     getHomeDelegationList()
197     {
198         return home_delegation_;
199     }
200 }
201
Popular Tags