summaryrefslogtreecommitdiff
path: root/src/location/places/qplacesearchquery.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/location/places/qplacesearchquery.h')
-rw-r--r--src/location/places/qplacesearchquery.h60
1 files changed, 60 insertions, 0 deletions
diff --git a/src/location/places/qplacesearchquery.h b/src/location/places/qplacesearchquery.h
new file mode 100644
index 00000000..dbab1422
--- /dev/null
+++ b/src/location/places/qplacesearchquery.h
@@ -0,0 +1,60 @@
+#ifndef QPLACESEARCHQUERY_H
+#define QPLACESEARCHQUERY_H
+
+#include <QSharedDataPointer>
+#include "qplaceglobal.h"
+#include "qplacecategory.h"
+#include "qplacequery.h"
+#include "qplacegeoboundingbox.h"
+
+#include <QString>
+
+namespace QT_PLACES_NAMESPACE {
+
+class QPlaceSearchQueryPrivate;
+
+class Q_PLACES_EXPORT QPlaceSearchQuery : public QPlaceQuery
+{
+public:
+ enum RelevanceHint {
+ DistanceHint,
+ RatingHint,
+ AlphabetHint
+ };
+
+ QPlaceSearchQuery();
+ QPlaceSearchQuery(const QPlaceSearchQuery &other);
+
+ virtual ~QPlaceSearchQuery();
+
+ QPlaceSearchQuery &operator=(const QPlaceSearchQuery &other);
+
+ bool operator==(const QPlaceSearchQuery &other) const;
+ bool operator!=(const QPlaceSearchQuery &other) const {
+ return !(other == *this);
+ }
+
+ QString searchTerm() const;
+ void setSearchTerm(const QString &term);
+
+ QList<QPlaceCategory> categories();
+ void setCategory(const QPlaceCategory &category);
+
+ QPlaceGeoCoordinate searchCenter() const;
+ void setSearchCenter(const QPlaceGeoCoordinate &center);
+
+ QPlaceGeoBoundingBox boundingBox() const;
+ void setBoundingBox(const QPlaceGeoBoundingBox &boundingBox);
+
+ uint didYouMeanSuggestionNumber() const;
+ void setDidYouMeanSuggestionNumber(const uint &number);
+
+ void clear();
+
+private:
+ QSharedDataPointer<QPlaceSearchQueryPrivate> d;
+};
+
+} // QT_PLACES_NAMESPACE
+
+#endif // QPLACESEARCHQUERY_H