KGAPI2::Location

Search for usage in LXR

KGAPI2::Location Class Reference

#include <location.h>

Inheritance diagram for KGAPI2::Location:

Public Member Functions

 Location ()
 
 Location (const Location &other)
 
 Location (float latitude, float longitude)
 
 ~Location () override
 
qint32 accuracy () const
 
qint32 altitude () const
 
qint32 altitudeAccuracy () const
 
qint32 heading () const
 
void setAccuracy (qint32 accuracy)
 
void setAltitude (qint32 altitude)
 
void setAltitudeAccuracy (qint32 altitudeAccuracy)
 
void setHeading (qint32 heading)
 
void setSpeed (qint32 speed)
 
void setTimestamp (qulonglong timestamp)
 
qint32 speed () const
 
qulonglong timestamp () const
 
- Public Member Functions inherited from KGAPI2::Object
 Object ()
 
 Object (const Object &other)
 
virtual ~Object ()
 
QString etag () const
 
bool operator== (const Object &other) const
 
void setEtag (const QString &etag)
 
- Public Member Functions inherited from KContacts::Geo
 Geo (const Geo &other)
 
 Geo (float latitude, float longitude)
 
void clear ()
 
bool isValid () const
 
float latitude () const
 
float longitude () const
 
bool operator!= (const Geo &other) const
 
Geooperator= (const Geo &other)
 
bool operator== (const Geo &other) const
 
void setLatitude (float latitude)
 
void setLongitude (float longitude)
 
QString toString () const
 

Detailed Description

Represents a single record about geographical location provided by Google Latitude service.

Author
Jan Grulich grulj.nosp@m.a@gm.nosp@m.ail.c.nosp@m.om
Since
0.4

Definition at line 27 of file latitude/location.h.

Constructor & Destructor Documentation

◆ Location() [1/3]

Location::Location ( )

Constructor.

Definition at line 39 of file latitude/location.cpp.

◆ Location() [2/3]

Location::Location ( float latitude,
float longitude )

Constructor.

Parameters
latitude
longitude

Definition at line 53 of file latitude/location.cpp.

◆ Location() [3/3]

Location::Location ( const Location & other)

Copy constructor.

Definition at line 46 of file latitude/location.cpp.

◆ ~Location()

Location::~Location ( )
override

Destructor.

Definition at line 60 of file latitude/location.cpp.

Member Function Documentation

◆ accuracy()

qint32 Location::accuracy ( ) const
nodiscard

Returns accuracy of the latitude and longitude in meters.

Returns
Returns -1 when accuracy is not defined.

Definition at line 70 of file latitude/location.cpp.

◆ altitude()

qint32 Location::altitude ( ) const
nodiscard

Returns altitude of this location.

Returns
Returns 0 when altitude is not defined.

Definition at line 85 of file latitude/location.cpp.

◆ altitudeAccuracy()

qint32 Location::altitudeAccuracy ( ) const
nodiscard

Returns altitude accuracy.

Returns
Returns -1 when altitude accuracy is not defined.

Definition at line 90 of file latitude/location.cpp.

◆ heading()

qint32 Location::heading ( ) const
nodiscard

Returns direction of travel of the user when this location was recorded.

Returns
Returns -1 when heading is not defined.

Definition at line 80 of file latitude/location.cpp.

◆ setAccuracy()

void Location::setAccuracy ( qint32 accuracy)

Sets accuracy of this location.

Definition at line 100 of file latitude/location.cpp.

◆ setAltitude()

void Location::setAltitude ( qint32 altitude)

Sets altitude of this location.

Definition at line 115 of file latitude/location.cpp.

◆ setAltitudeAccuracy()

void Location::setAltitudeAccuracy ( qint32 altitudeAccuracy)

Sets altitude accuracy of this location.

Definition at line 120 of file latitude/location.cpp.

◆ setHeading()

void Location::setHeading ( qint32 heading)

Sets heading of this location.

Definition at line 110 of file latitude/location.cpp.

◆ setSpeed()

void Location::setSpeed ( qint32 speed)

Sets speed of this location.

Definition at line 105 of file latitude/location.cpp.

◆ setTimestamp()

void Location::setTimestamp ( qulonglong timestamp)

Sets timestamp of this location.

Definition at line 95 of file latitude/location.cpp.

◆ speed()

qint32 Location::speed ( ) const
nodiscard

Returns ground speed of the user at the time this location was recorded.

Returns
Returns -1 when speed is not defined.

Definition at line 75 of file latitude/location.cpp.

◆ timestamp()

qulonglong Location::timestamp ( ) const

Timestamp of when this location has been recorded.

Also serves as location unique ID

Definition at line 65 of file latitude/location.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 4 2024 16:36:14 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.