QPlaceRatings Class
La clase `QPlaceRatings` contiene información sobre las valoraciones de un lugar. Más...
| Header: | #include <QPlaceRatings> |
| qmake: | QT += location |
Propiedades
Funciones públicas
| QPlaceRatings() | |
| QPlaceRatings(const QPlaceRatings &other) | |
| QPlaceRatings(QPlaceRatings &&other) | |
| ~QPlaceRatings() | |
| qreal | average() const |
| int | count() const |
| bool | isEmpty() const |
| qreal | maximum() const |
| void | setAverage(qreal average) |
| void | setCount(int count) |
| void | setMaximum(qreal max) |
| QPlaceRatings & | operator=(const QPlaceRatings &other) |
Personas no afiliadas relacionadas
| bool | operator!=(const QPlaceRatings &lhs, const QPlaceRatings &rhs) |
| bool | operator==(const QPlaceRatings &lhs, const QPlaceRatings &rhs) |
Descripción detallada
La información sobre valoraciones se utiliza para describir la calidad que se atribuye a un lugar. Normalmente, esta información se representa mediante un número de estrellas. La función average() devuelve un valor agregado de las valoraciones sobre un máximo posible, tal y como lo proporciona la función maximum().
Documentación de la propiedad
average : qreal
Esta propiedad contiene el valor medio de las valoraciones individuales.
Funciones de acceso:
| qreal | average() const |
| void | setAverage(qreal average) |
count : int
Esta propiedad contiene el número total de valoraciones individuales.
Funciones de acceso:
| int | count() const |
| void | setCount(int count) |
maximum : qreal
Esta propiedad tiene el valor máximo posible.
Funciones de acceso:
| qreal | maximum() const |
| void | setMaximum(qreal max) |
Documentación de las funciones de miembro
QPlaceRatings::QPlaceRatings()
Crea un nuevo objeto de valoraciones.
[noexcept] QPlaceRatings::QPlaceRatings(const QPlaceRatings &other)
Crea una copia de other.
[constexpr noexcept default] QPlaceRatings::QPlaceRatings(QPlaceRatings &&other)
Crea una instancia de ` QPlaceRatings` mediante la construcción «move».
[noexcept] QPlaceRatings::~QPlaceRatings()
Elimina el objeto «ratings».
bool QPlaceRatings::isEmpty() const
Devuelve «true» si todos los campos de las valoraciones del lugar son 0; en caso contrario, devuelve «false».
[noexcept] QPlaceRatings &QPlaceRatings::operator=(const QPlaceRatings &other)
Asigna ` other ` a este objeto de valoraciones y devuelve una referencia a dicho objeto.
Elementos no miembros relacionados
[noexcept] bool operator!=(const QPlaceRatings &lhs, const QPlaceRatings &rhs)
Devuelve «true» si « lhs » no es igual a « rhs »; en caso contrario, devuelve «false».
[noexcept] bool operator==(const QPlaceRatings &lhs, const QPlaceRatings &rhs)
Devuelve «true» si « lhs » es igual a « rhs »; en caso contrario, devuelve «false».
© 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.