merge the formfield patch from ooo-build
[ooovba.git] / autodoc / source / display / html / hd_chlst.hxx
bloba80b37c52843cf609fd0449d598039d9d1257523
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: hd_chlst.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 ADC_DISPLAY_HTML_HD_CHLST_HXX
32 #define ADC_DISPLAY_HTML_HD_CHLST_HXX
34 // BASE CLASSES
35 #include <ary/ary_disp.hxx>
36 #include <cosv/tpl/processor.hxx>
38 // USED SERVICES
39 #include <ary/cpp/c_types4cpp.hxx>
40 #include "hdimpl.hxx"
44 namespace ary
46 namespace cpp
48 class Namespace;
49 class Class;
50 class Enum;
51 class Typedef;
52 class Function;
53 class Variable;
54 class EnumValue;
56 namespace info
58 class DocuText;
62 class Docu_Display;
63 class ProtectionArea;
65 class ChildList_Display : public ary::Display,
66 public csv::ConstProcessor<ary::cpp::Namespace>,
67 public csv::ConstProcessor<ary::cpp::Class>,
68 public csv::ConstProcessor<ary::cpp::Enum>,
69 public csv::ConstProcessor<ary::cpp::Typedef>,
70 public csv::ConstProcessor<ary::cpp::Function>,
71 public csv::ConstProcessor<ary::cpp::Variable>,
72 public csv::ConstProcessor<ary::cpp::EnumValue>,
73 private HtmlDisplay_Impl
75 public:
76 struct Area_Result
78 bool & rChildrenExist;
79 csi::xml::Element & rOut;
81 Area_Result(
82 bool & o_rChildrenExist,
83 csi::xml::Element & o_rOut )
84 : rChildrenExist(o_rChildrenExist),
85 rOut(o_rOut) {}
89 ChildList_Display(
90 OuputPage_Environment &
91 io_rEnv );
92 ChildList_Display(
93 OuputPage_Environment &
94 io_rEnv,
95 const ary::cpp::Class &
96 i_rClass );
97 ChildList_Display(
98 OuputPage_Environment &
99 io_rEnv,
100 const ary::cpp::Enum &
101 i_rEnum );
103 virtual ~ChildList_Display();
105 void Run_Simple(
106 Area_Result & o_rResult,
107 ary::SlotAccessId i_nSlot,
108 const char * i_sListLabel,
109 const char * i_sListTitle );
110 void Run_GlobalClasses(
111 Area_Result & o_rResult,
112 ary::SlotAccessId i_nSlot,
113 const char * i_sListLabel,
114 const char * i_sListTitle,
115 ary::cpp::E_ClassKey
116 i_eFilter );
117 void Run_Members(
118 Area_Result & o_rResult_public,
119 Area_Result & o_rResult_protected,
120 Area_Result & o_rResult_private,
121 ary::SlotAccessId i_nSlot,
122 const char * i_sListLabel_public,
123 const char * i_sListLabel_protected,
124 const char * i_sListLabel_private,
125 const char * i_sListTitle );
126 void Run_MemberClasses(
127 Area_Result & o_rResult_public,
128 Area_Result & o_rResult_protected,
129 Area_Result & o_rResult_private,
130 ary::SlotAccessId i_nSlot,
131 const char * i_sListLabel_public,
132 const char * i_sListLabel_protected,
133 const char * i_sListLabel_private,
134 const char * i_sListTitle,
135 ary::cpp::E_ClassKey
136 i_eFilter );
137 private:
138 // Interface csv::ConstProcessor<>:
139 virtual void do_Process(
140 const ary::cpp::Namespace &
141 i_rData );
142 /** i_rData is shown only, if it passes two filters:
143 it must have the right protection, checked with pFilter,
144 and the right class key (class,struct,union), checked with
145 pClassFilter. A not exsting filter allows i_rData to be
146 displayed.
148 virtual void do_Process(
149 const ary::cpp::Class &
150 i_rData );
151 virtual void do_Process(
152 const ary::cpp::Enum &
153 i_rData );
154 virtual void do_Process(
155 const ary::cpp::Typedef &
156 i_rData );
157 virtual void do_Process(
158 const ary::cpp::Function &
159 i_rData );
160 virtual void do_Process(
161 const ary::cpp::Variable &
162 i_rData );
163 virtual void do_Process(
164 const ary::cpp::EnumValue &
165 i_rData );
166 private:
167 // Interface ary::Display:
168 virtual void do_StartSlot();
169 virtual void do_FinishSlot();
170 virtual const ary::cpp::Gate *
171 inq_Get_ReFinder() const;
172 // Locals
173 struct S_AreaCo;
174 void Write_ListItem(
175 const String & i_sLeftText,
176 const char * i_sLink,
177 const ary::info::DocuText &
178 i_rRightText,
179 csi::xml::Element & rOut );
180 const ary::AryGroup &
181 ActiveParent();
182 ProtectionArea & GetArea();
183 ProtectionArea & GetArea(
184 ary::cpp::E_Protection
185 i_eProtection );
186 void SetClassesFilter(
187 ary::cpp::E_ClassKey
188 i_eFilter )
189 { peClassesFilter = new ary::cpp::E_ClassKey(i_eFilter); }
190 void UnsetClassesFilter() { peClassesFilter = 0; }
192 // DATA
193 Dyn<Docu_Display> pShortDocu_Display;
194 const ary::cpp::Class *
195 pActiveParentClass;
196 const ary::cpp::Enum *
197 pActiveParentEnum;
199 Dyn<S_AreaCo> pSglArea;
200 Dyn<S_AreaCo> aMemberAreas[3];
202 Dyn<ary::cpp::E_ClassKey>
203 peClassesFilter;
209 #endif