Qt:Документация 4.3.2/qxmlstreamattribute

Материал из Wiki.crossplatform.ru

Перейти к: навигация, поиск
40px Внимание: Актуальная версия перевода документации находится здесь

__NOTOC__

Image:qt-logo.png

Главная · Все классы · Основные классы · Классы по группам · Модули · Функции

Image:trolltech-logo.png

Содержание

[править] QXmlStreamAttribute Class Reference
[модуль QtXml ]

The QXmlStreamAttribute class represents a single XML attribute More...

 #include <QXmlStreamAttribute>

Note: All the functions in this class are reentrant.

This class was introduced in Qt 4.3.

[править] Открытые функции


[править] Подробное описание

The QXmlStreamAttribute class represents a single XML attribute

An attribute consists of an optionally empty namespaceUri(), a name(), a value(), and an isDefault() attribute.

The raw XML attribute name is returned as qualifiedName().


[править] Описание функций-членов

[править]
QXmlStreamAttribute::QXmlStreamAttribute ()

Creates an empty attribute.

[править]
QXmlStreamAttribute::QXmlStreamAttribute ( const QString & qualifiedName, const QString & value )

Constructs an attribute with qualified name qualifiedName and value value.

[править]
QXmlStreamAttribute::QXmlStreamAttribute ( const QString & namespaceUri, const QString & name, const QString & value )

Constructs an attribute in the namespace described with namespaceUri with name and value value.

[править]
QXmlStreamAttribute::QXmlStreamAttribute ( const QXmlStreamAttribute & other )

Creates a copy of other.

[править]
QXmlStreamAttribute::~QXmlStreamAttribute ()

Destructs an attribute.

[править]
bool QXmlStreamAttribute::isDefault () const

Returns true if the parser added this attribute with a default value following an ATTLIST declaration in the DTD; otherwise returns false.

[править]
QStringRef QXmlStreamAttribute::name () const

Returns the attribute's local name.

[править]
QStringRef QXmlStreamAttribute::namespaceUri () const

Returns the attribute's resolved namespaceUri, or an empty string reference if the attribute does not have a defined namespace.

[править]
QStringRef QXmlStreamAttribute::qualifiedName () const

Returns the attribute's qualified name.

A qualified name is the raw name of an attribute in the XML data. It consists of the namespace prefix, followed by colon, followed by the attribute's local name. Since the namespace prefix is not unique (the same prefix can point to different namespaces and different prefixes can point to the same namespace), you shouldn't use qualifiedName(), but the resolved namespaceUri() and the attribute's local name().

[править]
QStringRef QXmlStreamAttribute::value () const

Returns the attribute's value.

[править]
bool QXmlStreamAttribute::operator!= ( const QXmlStreamAttribute & other ) const

Compares this attribute with other and returns true if they are not equal; otherwise returns false.

[править]
QXmlStreamAttribute & QXmlStreamAttribute::operator= ( const QXmlStreamAttribute & other )

Assigns other to this attribute.

[править]
bool QXmlStreamAttribute::operator== ( const QXmlStreamAttribute & other ) const

Compares this attribute with other and returns true if they are equal; otherwise returns false.


Copyright © 2007 Trolltech Trademarks
Qt 4.3.2