/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
module com { module sun { module star { module xml { module sax {
/** a container for the attributes of an XML element.
Attributes are separated into known attributes and unknown attributes.
Known attributes have a local name that is known to the XFastTokenHandler
registered at the XFastParser which created the sax event containing
this attributes. If an attribute also has a namespace, that must be registered
at the XFastParser, else this attribute is also unknown even if
the local name is known.
*/
interface XFastAttributeList: com::sun::star::uno::XInterface
{
/** checks if an attribute is available.
@param Token
contains the integer token from the XFastTokenHandler
registered at the XFastParser.
If the attribute name has a namespace that was registered with the
XFastParser, Token contains the integer token of the
attributes local name from the XFastTokenHandler and
the integer token of the namespace combined with an arithmetic
or operation.
@returns
`TRUE`, if the attribute is available
*/
boolean hasAttribute( [in] long Token );
/** retrieves the token of an attribute value.
@param Token
contains the integer token from the XFastTokenHandler
registered at the XFastParser.
If the attribute name has a namespace that was registered with the
XFastParser, Token contains the integer token of the
attributes local name from the XFastTokenHandler and
the integer token of the namespace combined with an arithmetic
or operation.
@returns
The integer token of the value from the attribute or FastToken::Invalid
@throws SAXEXception
if the attribute is not available
*/
long getValueToken( [in] long Token )
raises( SAXException );
/**retrieves the token of an attribute value.
@param Token
contains the integer token from the XFastTokenHandler
registered at the XFastParser.
If the attribute name has a namespace that was registered with the
XFastParser, Token contains the integer token of the
attributes local name from the XFastTokenHandler and
the integer token of the namespace combined with an arithmetic
or operation.
@param Default
This value will be returned if the attribute is not available
@returns
If the attribute is available it returns the integer token of the value
from the attribute or FastToken::Invalid.
If not the value of Default
is returned.
*/
long getOptionalValueToken( [in] long Token, [in] long Default );
/** retrieves the value of an attribute.
@param Token
contains the integer token from the XFastTokenHandler
registered at the XFastParser.
If the attribute name has a namespace that was registered with the
XFastParser, Token contains the integer token of the
attributes local name from the XFastTokenHandler and
the integer token of the namespace combined with an arithmetic
or operation.
@returns
The string value from the attribute.
@throws SAXEXception
if the attribute is not available
*/
string getValue( [in] long Token )
raises( SAXException );
/** retrieves the value of an attribute.
@param Token
contains the integer token from the XFastTokenHandler
registered at the XFastParser.
If the attribute name has a namespace that was registered with the
XFastParser, Token contains the integer token of the
attributes local name from the XFastTokenHandler and
the integer token of the namespace combined with an arithmetic
or operation.
@returns
The string value from the attribute or an empty string if the
attribute is not available.
*/
string getOptionalValue( [in] long Token );
/** returns a sequence of attributes which names and or namespaces URLS
can not be translated to tokens.
*/
sequence< ::com::sun::star::xml::Attribute > getUnknownAttributes();
/** returns a sequence of attributes which names and or namespaces URLS
are translated to tokens.
*/
sequence< ::com::sun::star::xml::FastAttribute > getFastAttributes();
};
}; }; }; }; };
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */