xref: /aoo42x/main/autodoc/inc/ary/idl/i_ce.hxx (revision 30acf5e8)
11c78a5d6SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
31c78a5d6SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
41c78a5d6SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
51c78a5d6SAndrew Rist  * distributed with this work for additional information
61c78a5d6SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
71c78a5d6SAndrew Rist  * to you under the Apache License, Version 2.0 (the
81c78a5d6SAndrew Rist  * "License"); you may not use this file except in compliance
91c78a5d6SAndrew Rist  * with the License.  You may obtain a copy of the License at
101c78a5d6SAndrew Rist  *
111c78a5d6SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
121c78a5d6SAndrew Rist  *
131c78a5d6SAndrew Rist  * Unless required by applicable law or agreed to in writing,
141c78a5d6SAndrew Rist  * software distributed under the License is distributed on an
151c78a5d6SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
161c78a5d6SAndrew Rist  * KIND, either express or implied.  See the License for the
171c78a5d6SAndrew Rist  * specific language governing permissions and limitations
181c78a5d6SAndrew Rist  * under the License.
191c78a5d6SAndrew Rist  *
201c78a5d6SAndrew Rist  *************************************************************/
211c78a5d6SAndrew Rist 
221c78a5d6SAndrew Rist 
23cdf0e10cSrcweir 
24cdf0e10cSrcweir #ifndef ARY_IDL_I_CE_HXX
25cdf0e10cSrcweir #define ARY_IDL_I_CE_HXX
26cdf0e10cSrcweir 
27cdf0e10cSrcweir // BASE CLASSES
28cdf0e10cSrcweir #include <ary/entity.hxx>
29cdf0e10cSrcweir // USED SERVICES
30cdf0e10cSrcweir #include <ary/doc/d_docu.hxx>
31cdf0e10cSrcweir #include <ary/idl/i_ce2s.hxx>
32cdf0e10cSrcweir #include <ary/idl/i_types4idl.hxx>
33cdf0e10cSrcweir 
34cdf0e10cSrcweir 
35cdf0e10cSrcweir 
36cdf0e10cSrcweir 
37cdf0e10cSrcweir 
38cdf0e10cSrcweir 
39cdf0e10cSrcweir namespace ary
40cdf0e10cSrcweir {
41cdf0e10cSrcweir namespace idl
42cdf0e10cSrcweir {
43cdf0e10cSrcweir 
44cdf0e10cSrcweir 
45cdf0e10cSrcweir /** @resp Base class for all IDL code entities.
46cdf0e10cSrcweir 
47*30acf5e8Spfg     A @->CodeEntity is a namespace, type, data or function, which occurs in
48cdf0e10cSrcweir     the parsed UNO IDL code and is described and/or commented within the
49cdf0e10cSrcweir     Autodoc repository.
50cdf0e10cSrcweir 
51cdf0e10cSrcweir     This is a storage base class, where more special classes are
52cdf0e10cSrcweir     derived from.
53cdf0e10cSrcweir */
54cdf0e10cSrcweir class CodeEntity : public ary::Entity
55cdf0e10cSrcweir {
56cdf0e10cSrcweir   public:
57cdf0e10cSrcweir     // LIFECYCLE
58cdf0e10cSrcweir     virtual             ~CodeEntity();
59cdf0e10cSrcweir 
60cdf0e10cSrcweir     // OPERATION
61cdf0e10cSrcweir 
62cdf0e10cSrcweir     // INQUIRY
CeId() const63cdf0e10cSrcweir     Ce_id               CeId() const            { return Ce_id(Id()); }
64cdf0e10cSrcweir     const String &      LocalName() const;
65cdf0e10cSrcweir     Ce_id               NameRoom() const;
66cdf0e10cSrcweir     Ce_id               Owner() const;
67cdf0e10cSrcweir     E_SightLevel        SightLevel() const;
68cdf0e10cSrcweir 
69cdf0e10cSrcweir     const ary::doc::Documentation &
70cdf0e10cSrcweir                         Docu() const;
71cdf0e10cSrcweir     const Ce_2s &       Secondaries() const;
72cdf0e10cSrcweir 
73cdf0e10cSrcweir     static const CodeEntity &
74cdf0e10cSrcweir                         Null_();
75cdf0e10cSrcweir     // ACCESS
76cdf0e10cSrcweir     void                Set_Docu(
77cdf0e10cSrcweir                             DYN ary::doc::Node &
78cdf0e10cSrcweir                                                 pass_data );
79cdf0e10cSrcweir     Ce_2s &             Secondaries();
80cdf0e10cSrcweir 
81cdf0e10cSrcweir   protected:
82cdf0e10cSrcweir                         CodeEntity();
83cdf0e10cSrcweir   private:
84cdf0e10cSrcweir     // Locals
85cdf0e10cSrcweir     virtual const String &  inq_LocalName() const = 0;
86cdf0e10cSrcweir     virtual Ce_id           inq_NameRoom() const = 0;
87cdf0e10cSrcweir     virtual Ce_id           inq_Owner() const = 0;
88cdf0e10cSrcweir     virtual E_SightLevel    inq_SightLevel() const = 0;
89cdf0e10cSrcweir 
90cdf0e10cSrcweir     // DATA
91cdf0e10cSrcweir 	ary::doc::Documentation
92cdf0e10cSrcweir 	                    aDocu;
93cdf0e10cSrcweir     Dyn<Ce_2s>          p2s;
94cdf0e10cSrcweir };
95cdf0e10cSrcweir 
96cdf0e10cSrcweir 
97cdf0e10cSrcweir 
98cdf0e10cSrcweir 
99cdf0e10cSrcweir // IMPLEMENTATION
100cdf0e10cSrcweir inline const String &
LocalName() const101cdf0e10cSrcweir CodeEntity::LocalName() const
102cdf0e10cSrcweir     { return inq_LocalName(); }
103cdf0e10cSrcweir 
104cdf0e10cSrcweir inline Ce_id
NameRoom() const105cdf0e10cSrcweir CodeEntity::NameRoom() const
106cdf0e10cSrcweir     { return inq_NameRoom(); }
107cdf0e10cSrcweir 
108cdf0e10cSrcweir inline Ce_id
Owner() const109cdf0e10cSrcweir CodeEntity::Owner() const
110cdf0e10cSrcweir     { return inq_Owner(); }
111cdf0e10cSrcweir 
112cdf0e10cSrcweir inline E_SightLevel
SightLevel() const113cdf0e10cSrcweir CodeEntity::SightLevel() const
114cdf0e10cSrcweir     { return inq_SightLevel(); }
115cdf0e10cSrcweir 
116cdf0e10cSrcweir inline const ary::doc::Documentation &
Docu() const117cdf0e10cSrcweir CodeEntity::Docu() const
118cdf0e10cSrcweir     { return aDocu; }
119cdf0e10cSrcweir 
120cdf0e10cSrcweir inline void
Set_Docu(DYN ary::doc::Node & pass_data)121cdf0e10cSrcweir CodeEntity::Set_Docu(DYN ary::doc::Node & pass_data)
122cdf0e10cSrcweir {
123cdf0e10cSrcweir     aDocu.Set_Data(pass_data);
124cdf0e10cSrcweir }
125cdf0e10cSrcweir 
126cdf0e10cSrcweir 
127cdf0e10cSrcweir 
128cdf0e10cSrcweir 
129cdf0e10cSrcweir }   // namespace idl
130cdf0e10cSrcweir }   // namespace ary
131cdf0e10cSrcweir #endif
132