1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 #ifndef __com_sun_star_xml_sax_XFastAttributeList_idl__
20 #define __com_sun_star_xml_sax_XFastAttributeList_idl__
22 #include
<com
/sun
/star
/uno
/XInterface.idl
>
23 #include
<com
/sun
/star
/xml
/Attribute.idl
>
24 #include
<com
/sun
/star
/xml
/FastAttribute.idl
>
25 #include
<com
/sun
/star
/xml
/sax
/SAXException.idl
>
28 module com
{ module sun
{ module star
{ module xml
{ module sax
{
31 /** a container for the attributes of an XML element.
33 <br>Attributes are separated into known attributes and unknown attributes.
34 <p>Known attributes have a local name that is known to the XFastTokenHandler
35 registered at the XFastParser which created the sax event containing
36 this attributes. If an attribute also has a namespace, that must be registered
37 at the XFastParser, else this attribute is also unknown even if
38 the local name is known.
40 interface XFastAttributeList
: com
::sun
::star
::uno
::XInterface
42 /** checks if an attribute is available.<br>
45 contains the integer token from the XFastTokenHandler
46 registered at the XFastParser.<br>
48 If the attribute name has a namespace that was registered with the
49 XFastParser, Token contains the integer token of the
50 attributes local name from the XFastTokenHandler and
51 the integer token of the namespace combined with an arithmetic
55 `TRUE`, if the attribute is available
57 boolean hasAttribute
( [in] long Token
);
59 /** retrieves the token of an attribute value.<br>
62 contains the integer token from the XFastTokenHandler
63 registered at the XFastParser.<br>
65 If the attribute name has a namespace that was registered with the
66 XFastParser, Token contains the integer token of the
67 attributes local name from the XFastTokenHandler and
68 the integer token of the namespace combined with an arithmetic
72 The integer token of the value from the attribute or FastToken::Invalid
75 if the attribute is not available
78 long getValueToken
( [in] long Token
)
79 raises
( SAXException
);
81 /**retrieves the token of an attribute value.<br>
84 contains the integer token from the XFastTokenHandler
85 registered at the XFastParser.<br>
87 If the attribute name has a namespace that was registered with the
88 XFastParser, Token contains the integer token of the
89 attributes local name from the XFastTokenHandler and
90 the integer token of the namespace combined with an arithmetic
94 This value will be returned if the attribute is not available
97 If the attribute is available it returns the integer token of the value
98 from the attribute or FastToken::Invalid.
99 If not the value of <code>Default</code> is returned.
102 long getOptionalValueToken
( [in] long Token
, [in] long Default );
104 /** retrieves the value of an attribute.<br>
107 contains the integer token from the XFastTokenHandler
108 registered at the XFastParser.<br>
110 If the attribute name has a namespace that was registered with the
111 XFastParser, Token contains the integer token of the
112 attributes local name from the XFastTokenHandler and
113 the integer token of the namespace combined with an arithmetic
117 The string value from the attribute.
120 if the attribute is not available
123 string getValue
( [in] long Token
)
124 raises
( SAXException
);
126 /** retrieves the value of an attribute.<br>
129 contains the integer token from the XFastTokenHandler
130 registered at the XFastParser.<br>
132 If the attribute name has a namespace that was registered with the
133 XFastParser, Token contains the integer token of the
134 attributes local name from the XFastTokenHandler and
135 the integer token of the namespace combined with an arithmetic
139 The string value from the attribute or an empty string if the
140 attribute is not available.
142 string getOptionalValue
( [in] long Token
);
144 /** returns a sequence of attributes which names and or namespaces URLS
145 can not be translated to tokens.
147 sequence
< ::com
::sun
::star
::xml
::Attribute
> getUnknownAttributes
();
149 /** returns a sequence of attributes which names and or namespaces URLS
150 are translated to tokens.
152 sequence
< ::com
::sun
::star
::xml
::FastAttribute
> getFastAttributes
();
160 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */