merge the formfield patch from ooo-build
[ooovba.git] / autodoc / inc / ary / cpp / c_enum.hxx
blob1fb60c18d839fe821dc503119bfff4b473791398
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: c_enum.hxx,v $
10 * $Revision: 1.4 $
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 ************************************************************************/
31 #ifndef ARY_CPP_C_ENUM_HXX
32 #define ARY_CPP_C_ENUM_HXX
36 // USED SERVICES
37 // BASE CLASSES
38 #include <ary/cpp/c_ce.hxx>
39 #include <ary/arygroup.hxx>
40 // OTHER
41 #include <ary/cessentl.hxx>
42 #include <ary/cpp/c_types4cpp.hxx>
43 #include <ary/sequentialids.hxx>
49 namespace ary
51 namespace cpp
55 /** A C++ enum declaration.
57 class Enum : public CodeEntity,
58 public AryGroup
60 public:
61 enum E_ClassId { class_id = 1002 };
63 enum E_Slots
65 SLOT_Values = 1
68 // LIFECYCLE
69 Enum(
70 const String & i_sLocalName,
71 Ce_id i_nOwner,
72 E_Protection i_eProtection,
73 Lid i_nFile );
74 ~Enum();
76 // OPERATIONS
77 void Add_Value(
78 Ce_id i_nId );
80 // INQUIRY
81 E_Protection Protection() const { return eProtection; }
83 private:
84 // Interface csv::ConstProcessorClient
85 virtual void do_Accept(
86 csv::ProcessorIfc & io_processor ) const;
88 // Interface ary::cpp::CodeEntity
89 virtual const String &
90 inq_LocalName() const;
91 virtual Cid inq_Owner() const;
92 virtual Lid inq_Location() const;
94 // Interface ary::cpp::CppEntity
95 virtual ClassId get_AryClass() const;
97 // Interface ary::AryGroup
98 virtual Gid inq_Id_Group() const;
99 virtual const cpp::CppEntity &
100 inq_RE_Group() const;
101 virtual const group::SlotList &
102 inq_Slots() const;
103 virtual DYN Slot * inq_Create_Slot(
104 SlotAccessId i_nSlot ) const;
106 // DATA
107 CeEssentials aEssentials;
108 SequentialIds<Ce_id>
109 aValues;
110 E_Protection eProtection;
117 } // namespace cpp
118 } // namespace ary
119 #endif