En esta página

QMetaClassInfo Class

La clase QMetaClassInfo proporciona información adicional sobre una clase. Más...

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

Funciones públicas

const char *name() const
const char *value() const

Descripción detallada

Los elementos de información de clase son simples pares nombre-valor que se especifican utilizando Q_CLASSINFO() en el código fuente. La información puede recuperarse utilizando name() y value(). Por ejemplo:

class MyClass : public QObject
{
    Q_OBJECT
    Q_CLASSINFO("author", "Sabrina Schweinsteiger")
    Q_CLASSINFO("url", "http://doc.moosesoft.co.uk/1.0/")

public:
    //...
};

Este mecanismo es gratuito para que lo utilices en tus aplicaciones Qt.

Nota: También es utilizado por el Active Qt, Qt D-Bus, Qt Qmly Qt Remote Objects . Es posible que algunas teclas se activen al utilizar estos módulos.

Véase también QMetaObject.

Documentación de las funciones miembro

const char *QMetaClassInfo::name() const

Devuelve el nombre de este elemento.

Véase también value().

const char *QMetaClassInfo::value() const

Devuelve el valor de este elemento.

Véase también name().

© 2026 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.