KPublicTransport::CoverageArea
#include <coveragearea.h>
Public Types | |
enum | Type { Realtime , Regular , Any } |
Properties | |
QStringList | regions |
Type | type |
QStringList | uicCompanyCodes |
QStringList | vdvOrganizationIds |
Public Member Functions | |
bool | coversLocation (const Location &loc) const |
bool | hasNationWideCoverage (const QString &country) const |
bool | isEmpty () const |
bool | isGlobal () const |
Static Public Member Functions | |
static CoverageArea | fromJson (const QJsonObject &obj) |
Detailed Description
Describes the area a specific KPublicTransport::Backend can provide information for.
Definition at line 21 of file coveragearea.h.
Member Enumeration Documentation
◆ Type
Coverage quality as defined by the Transport API Repository format.
Definition at line 26 of file coveragearea.h.
Property Documentation
◆ regions
|
readwrite |
ISO 3166-1/2 codes of covered regions.
Note that actual coverage might be small (e.g. just a city inside the given region).
Definition at line 37 of file coveragearea.h.
◆ type
|
readwrite |
Definition at line 32 of file coveragearea.h.
◆ uicCompanyCodes
|
readwrite |
UIC company codes of operators covered by this backend.
Definition at line 40 of file coveragearea.h.
◆ vdvOrganizationIds
|
readwrite |
VDV organization ids of operators covered by this backend.
Definition at line 42 of file coveragearea.h.
Member Function Documentation
◆ coversLocation()
bool CoverageArea::coversLocation | ( | const Location & | loc | ) | const |
Checks whether loc
is covered by this area.
Definition at line 86 of file coveragearea.cpp.
◆ fromJson()
|
static |
Read a single coverage area information from a JSON object in Transport API Repository format.
Definition at line 120 of file coveragearea.cpp.
◆ hasNationWideCoverage()
bool CoverageArea::hasNationWideCoverage | ( | const QString & | country | ) | const |
Checks whether this includes the entire country country
.
Definition at line 115 of file coveragearea.cpp.
◆ isEmpty()
bool CoverageArea::isEmpty | ( | ) | const |
Checks whether this coverage area is empty.
coversLocation() would always return false
for empty areas.
Definition at line 67 of file coveragearea.cpp.
◆ isGlobal()
bool CoverageArea::isGlobal | ( | ) | const |
Returns true
if this area covers the entire world.
Definition at line 72 of file coveragearea.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 16:59:57 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.