QXmlStreamAttribute Class

QXmlStreamAttribute 클래스는 단일 XML 어트리뷰트를 나타냅니다. 더 보기...

Header: #include <QXmlStreamAttribute>
CMake: find_package(Qt6 REQUIRED COMPONENTS Core)
target_link_libraries(mytarget PRIVATE Qt6::Core)
qmake: QT += core

이 클래스는 동등 비교가 가능합니다.

참고: 이 클래스의 모든 함수는 재인용됩니다.

공용 함수

QXmlStreamAttribute()
QXmlStreamAttribute(const QString &qualifiedName, const QString &value)
QXmlStreamAttribute(const QString &namespaceUri, const QString &name, const QString &value)
bool isDefault() const
QStringView name() const
QStringView namespaceUri() const
QStringView prefix() const
QStringView qualifiedName() const
QStringView value() const
bool operator!=(const QXmlStreamAttribute &lhs, const QXmlStreamAttribute &rhs)
bool operator==(const QXmlStreamAttribute &lhs, const QXmlStreamAttribute &rhs)

상세 설명

어트리뷰트는 선택적으로 비어 있는 namespaceUri(), name(), value() 및 isDefault() 어트리뷰트로 구성됩니다.

원시 XML 어트리뷰트 이름은 qualifiedName()로 반환됩니다.

멤버 함수 문서

QXmlStreamAttribute::QXmlStreamAttribute()

빈 어트리뷰트를 생성합니다.

QXmlStreamAttribute::QXmlStreamAttribute(const QString &qualifiedName, const QString &value)

정규화된 이름 qualifiedName 과 값 value 으로 속성을 구성합니다.

QXmlStreamAttribute::QXmlStreamAttribute(const QString &namespaceUri, const QString &name, const QString &value)

namespaceUri name 및 값 으로 설명된 네임스페이스에 속성을 구성합니다. value

bool QXmlStreamAttribute::isDefault() const

구문 분석기가 DTD의 ATTLIST 선언에 따라 기본값으로 이 속성을 추가한 경우 true 을 반환하고, 그렇지 않으면 false 을 반환합니다.

QStringView QXmlStreamAttribute::name() const

속성의 로컬 이름을 반환합니다.

QStringView QXmlStreamAttribute::namespaceUri() const

속성의 확인된 네임스페이스Uri를 반환하거나 속성에 정의된 네임스페이스가 없는 경우 빈 문자열 참조를 반환합니다.

QStringView QXmlStreamAttribute::prefix() const

속성의 네임스페이스 접두사를 반환합니다.

name() 및 qualifiedName()도 참조하세요 .

QStringView QXmlStreamAttribute::qualifiedName() const

속성의 정규화된 이름을 반환합니다.

정규화된 이름은 XML 데이터에 있는 속성의 원시 이름입니다. 네임스페이스 prefix()와 콜론, 그리고 속성의 로컬 name()로 구성됩니다. 네임스페이스 접두사는 고유하지 않으므로(동일한 접두사가 다른 네임스페이스를 가리킬 수 있고 다른 접두사가 동일한 네임스페이스를 가리킬 수 있음), qualifiedName()을 사용하지 말고 확인된 namespaceUri()과 속성의 로컬 name()을 사용해야 합니다.

QStringView QXmlStreamAttribute::value() const

속성의 값을 반환합니다.

관련 비회원

[noexcept] bool operator!=(const QXmlStreamAttribute &lhs, const QXmlStreamAttribute &rhs)

lhs 속성을 rhs 과 비교하여 같지 않으면 true 을 반환하고, 그렇지 않으면 false 을 반환합니다.

[noexcept] bool operator==(const QXmlStreamAttribute &lhs, const QXmlStreamAttribute &rhs)

lhs 속성을 rhs 과 비교하여 같으면 true 을 반환하고, 그렇지 않으면 false 을 반환합니다.

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.