1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: d_token.hxx,v $
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 CSI_DSAPI_D_TOKEN_HXX
32 #define CSI_DSAPI_D_TOKEN_HXX
35 #include <ary_i/ci_text2.hxx>
36 #include <ary_i/ci_atag2.hxx>
43 class DocumentationDisplay
;
54 using ary::inf::DocumentationDisplay
;
57 class DT_Dsapi
: public ary::inf::DocuToken
60 virtual void DisplayAt(
61 DocumentationDisplay
&
62 o_rDisplay
) const = 0;
63 virtual bool IsWhiteOnly() const;
68 class DT_TextToken
: public DT_Dsapi
71 explicit DT_TextToken(
72 const char * i_sText
)
74 explicit DT_TextToken(
75 const String
& i_sText
)
77 virtual ~DT_TextToken();
79 virtual void DisplayAt(
80 DocumentationDisplay
&
82 const char * GetText() const { return sText
; }
83 const String
& GetTextStr() const { return sText
; }
85 String
& Access_Text() { return sText
; }
87 virtual bool IsWhiteOnly() const;
93 class DT_White
: public DT_Dsapi
99 virtual void DisplayAt(
100 DocumentationDisplay
&
102 virtual bool IsWhiteOnly() const;
106 class DT_MLTag
: public DT_Dsapi
118 class DT_MupType
: public DT_MLTag
121 explicit DT_MupType( /// Constructor for End-Tag
122 bool ) /// Must be there, but is not evaluated.
124 explicit DT_MupType( /// Constructor for Begin-Tag
125 const String
& i_sScope
)
126 : sScope(i_sScope
), bIsBegin(true) {}
127 virtual ~DT_MupType();
129 virtual void DisplayAt(
130 DocumentationDisplay
&
132 const String
& Scope() const { return sScope
; }
133 bool IsBegin() const { return bIsBegin
; }
140 class DT_MupMember
: public DT_MLTag
143 explicit DT_MupMember( /// Constructor for End-Tag
144 bool ) /// Must be there, but is not evaluated.
146 DT_MupMember( /// Constructor for Begin-Tag
147 const String
& i_sScope
)
148 : sScope(i_sScope
), bIsBegin(true) {}
149 virtual ~DT_MupMember();
151 virtual void DisplayAt(
152 DocumentationDisplay
&
154 const String
& Scope() const { return sScope
; }
155 bool IsBegin() const { return bIsBegin
; }
162 class DT_MupConst
: public DT_Dsapi
166 const char * i_sConstText
)
167 : sConstText(i_sConstText
) {}
168 virtual ~DT_MupConst();
170 virtual void DisplayAt(
171 DocumentationDisplay
&
173 const char * GetText() const { return sConstText
; }
176 String sConstText
; /// Without HTML.
180 class DT_Style
: public DT_MLTag
184 const char * i_sPlainHtmlTag
,
186 : sText(i_sPlainHtmlTag
), bNewLine(i_bNewLine
) {}
189 virtual void DisplayAt(
190 DocumentationDisplay
&
192 const char * GetText() const { return sText
; }
193 bool IsStartOfNewLine() const
196 String sText
; /// With HTML.
201 class DT_EOL
: public DT_Dsapi
207 virtual void DisplayAt(
208 DocumentationDisplay
&
210 virtual bool IsWhiteOnly() const;
214 class DT_AtTag
: public ary::inf::AtTag2
218 DYN
ary::inf::DocuToken
&
220 { aText
.AddToken(let_drToken
); }
222 const char * i_sName
)
223 { sTitle
= i_sName
; }
227 const char * i_sTitle
)
228 : ary::inf::AtTag2(i_sTitle
) {}
231 class DT_StdAtTag
: public DT_AtTag
234 explicit DT_StdAtTag(
235 const char * i_sTitle
)
236 : DT_AtTag(i_sTitle
) {}
237 virtual ~DT_StdAtTag();
239 virtual void DisplayAt(
240 DocumentationDisplay
&
244 class DT_SeeAlsoAtTag
: public DT_AtTag
247 DT_SeeAlsoAtTag() : DT_AtTag("") {}
248 virtual ~DT_SeeAlsoAtTag();
250 virtual void DisplayAt(
251 DocumentationDisplay
&
253 const String
& LinkText() const { return sTitle
; } // Missbrauch von sTitle
256 class DT_ParameterAtTag
: public DT_AtTag
259 DT_ParameterAtTag() : DT_AtTag("") {}
260 virtual ~DT_ParameterAtTag();
263 const char * i_sTitle
);
264 virtual void DisplayAt(
265 DocumentationDisplay
&
269 class DT_SinceAtTag
: public DT_AtTag
272 DT_SinceAtTag() : DT_AtTag("Since version") {}
273 virtual ~DT_SinceAtTag();
275 virtual void DisplayAt(
276 DocumentationDisplay
&