Home · All Classes · Main Classes · Deprecated
Public Member Functions

MLocationDatabase Class Reference

List of all members.

Public Member Functions

 MLocationDatabase ()
virtual ~MLocationDatabase ()
QList< MCountrycountries ()
QList< MCitycities ()
QList< MCitycitiesInCountry (const QString &countryKey)
QList< MCitycitiesInTimeZone (const QString &timeZoneId)
QList< MCitymatchingCities (const QString &searchString)
MCity nearestCity (qreal latitude, qreal longitude)

Constructor & Destructor Documentation

MLocationDatabase::MLocationDatabase (  ) 
MLocationDatabase::~MLocationDatabase (  )  [virtual]

Member Function Documentation

QList< MCity > MLocationDatabase::cities (  ) 

returns a list with all known cities

QList< MCity > MLocationDatabase::citiesInCountry ( const QString countryKey  ) 

returns a list with all cities in a country

QList< MCity > MLocationDatabase::citiesInTimeZone ( const QString timeZoneId  ) 

returns a list with all cities in a time zone

Parameters:
timeZoneId the Olson id of the timezone

Time zone ids are “canonicalized” when comparing, i.e. citiesInTimeZone("US/Pacific") and citiesInTimeZone("America/Los_Angeles") will return the same list.

I.e. this lists all cities which have the same canonical timezone id as the id given as parameter.

It tries to put the “most important” city for this timezone id first in the list of cities returned. Currently it does this by putting a city first if it happens to have the same name as the part of the canonical timezone id after the last “/”.

For invalid time zone ids like "Oz/Emerald_City", an empty list is returned.

QList< MCountry > MLocationDatabase::countries (  ) 

returns a list with all known countries

QList< MCity > MLocationDatabase::matchingCities ( const QString searchString  ) 

returns a list with all cities that contain the given searchString

MCity MLocationDatabase::nearestCity ( qreal  latitude,
qreal  longitude 
)

returns the city with the nearest position to the given location.


Copyright © 2010 Nokia Corporation
MeeGo Touch