- class QPlaceCategory¶
The
QPlaceCategory
class represents a category that aQPlace
can be associated with. More…Synopsis¶
Methods¶
def
__init__()
def
categoryId()
def
icon()
def
isEmpty()
def
name()
def
__ne__()
def
__eq__()
def
setCategoryId()
def
setIcon()
def
setName()
def
swap()
Note
This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE
Detailed Description¶
Categories are used to search for places based on the categories they are associated with. The list/tree of available categories can be obtained from
QPlaceManager
. ThesetCategories()
function can be used to limit the search results to places with the specified categories.If the
QGeoServiceProvider
supports it, categories can be created and removed. This functionality is available in theQPlaceManager
class.- __init__()¶
Constructs a category.
- __init__(other)
- Parameters:
other –
QPlaceCategory
Constructs a category which is a copy of
other
.- categoryId()¶
- Return type:
str
Returns the identifier of the category. The category identifier is a string which uniquely identifies this category within a particular
QPlaceManager
. The identifier is only meaningful to theQPlaceManager
that generated it and is not transferable between managers.See also
- icon()¶
- Return type:
Returns the icon associated with the category.
See also
- isEmpty()¶
- Return type:
bool
Returns a boolean indicating whether the all the fields of the place category are empty or not.
- name()¶
- Return type:
str
Returns the name of category.
See also
- __ne__(rhs)¶
- Parameters:
rhs –
QPlaceCategory
- Return type:
bool
Returns true if
lhs
is not equal torhs
; otherwise returns false.- __eq__(rhs)¶
- Parameters:
rhs –
QPlaceCategory
- Return type:
bool
Returns true if
lhs
is equal torhs
; otherwise returns false.- setCategoryId(identifier)¶
- Parameters:
identifier – str
Sets the
identifier
of the category.See also
- setIcon(icon)¶
- Parameters:
icon –
QPlaceIcon
Sets the
icon
of the category.See also
- setName(name)¶
- Parameters:
name – str
Sets the
name
of the category.See also
- swap(other)¶
- Parameters:
other –
QPlaceCategory