Typedefs | |
typedef struct _Elocation_Accuracy | Elocation_Accuracy |
typedef struct _Elocation_Address | Elocation_Address |
typedef struct _Elocation_Postion | Elocation_Position |
typedef struct _Elocation_Velocity | Elocation_Velocity |
typedef struct _Elocation_Requirements | Elocation_Requirements |
typedef struct _Elocation_Provider | Elocation_Provider |
Functions | |
EAPI Elocation_Address * | elocation_address_new (void) |
Create a new address object to operate on. More... | |
EAPI void | elocation_address_free (Elocation_Address *address) |
Free an address object. More... | |
EAPI Elocation_Position * | elocation_position_new (void) |
Create a new position object to operate on. More... | |
EAPI void | elocation_position_free (Elocation_Position *position) |
Free an position object. More... | |
EAPI Eina_Bool | elocation_address_get (Elocation_Address *address) |
Get the current address information. More... | |
EAPI Eina_Bool | elocation_position_get (Elocation_Position *position) |
Get the current position information. More... | |
EAPI Eina_Bool | elocation_status_get (int *status) |
Get the current status. More... | |
EAPI Eina_Bool | elocation_requirements_set (Elocation_Requirements *requirements) |
Set the requirements. More... | |
EAPI Eina_Bool | elocation_position_to_address (Elocation_Position *position_shadow, Elocation_Address *address_shadow) |
Convert position to address. More... | |
EAPI Eina_Bool | elocation_address_to_position (Elocation_Address *address_shadow, Elocation_Position *position_shadow) |
Convert address to position. More... | |
EAPI Eina_Bool | elocation_freeform_address_to_position (const char *freeform_address, Elocation_Position *position_shadow) |
Convert free form address tring to position. More... | |
EAPI Eina_Bool | elocation_landmarks_get (Elocation_Position *position_shadow, Elocation_Address *address_shadow) |
Request a landmark position. More... | |
EAPI Eina_Bool | elocation_init (void) |
Initialize the elocation subsystem. More... | |
EAPI void | elocation_shutdown (void) |
Cleanup and shutdown the elocation subsystem. More... | |
EAPI int | ELOCATION_EVENT_STATUS |
Available location events that are emitted from the library. More... | |
EAPI int | ELOCATION_EVENT_POSITION |
Position changed. | |
EAPI int | ELOCATION_EVENT_ADDRESS |
Address changed. | |
EAPI int | ELOCATION_EVENT_VELOCITY |
Velocity changed. | |
EAPI int | ELOCATION_EVENT_GEOCODE |
Reply for geocode translation arrived. | |
EAPI int | ELOCATION_EVENT_REVERSEGEOCODE |
Reply for geocode translation arrived. | |
EAPI int | ELOCATION_EVENT_NMEA |
NMEA update. | |
EAPI int | ELOCATION_EVENT_SATELLITE |
Satellite info changed. | |
EAPI int | ELOCATION_EVENT_POI |
POI reply. | |
EAPI int | ELOCATION_EVENT_META_READY |
Meta provider is ready to be used. | |
enum | Elocation_Accuracy_Level |
enum | Elocation_Resource_Flags { , ELOCATION_RESOURCE_NETWORK = 1 << 0, ELOCATION_RESOURCE_CELL = 1 << 1, ELOCATION_RESOURCE_GPS = 1 << 2, ELOCATION_RESOURCE_ALL = (1 << 10) - 1 } |
enum | GeocluePositionFields |
enum | GeoclueNetworkStatus |
enum | GeoclueStatus |
enum | GeoclueVelocityFields |
Detailed Description
Typedef Documentation
- Since
- 1.8
Information about the accuracy of the reported location. For details about the level of accuracy see Elocation_Accuracy_Level. It also covers horizontal and vertical accuracy. The values depend on the used provider and may very in quality.
- Since
- 1.8
Location information in textual form. Depending on the used provider this can cover only the country or a detailed address with postcode and street. The level of detail varies depending on the used provider. A timestamp is available to calculate the age of the address data.
- Since
- 1.8
Location information based on the GPS grid. Latitude, longitude and altitude. A timestamp is available to calculate the age of the address data.
- Since
- 1.8
Data structure to hold information about a GeoClue provider.
- Since
- 1.8
Requirement settings for the location provider. Requirements can be a level of accuracy or allowed resources like network access or GPS. See Elocation_Resource_Flags for all available resource flags.
Based on this setting the best provider is chosen between the available providers of GeoClue.
- Since
- 1.8
Velocity information. So far this interface is only offered with GPS based providers. It offers information about speed, direction and climb. A timestamp is available to calculate the age of the address data.
FIXME: check units and formats of this values coming in from GeoClue
Enumeration Type Documentation
- Since
- 1.8
Different location accuracy levels from country level up to detailed, e.g. GPS, information.
- Since
- 1.8
Flags for available system resources to be used for locating. So far they cover physical resources like network connection, cellular network connection and GPS.
enum GeoclueNetworkStatus |
- Since
- 1.8
Status of the network connectivity for GeoClue. Needed for all providers that access external data to determine the location. For example GeoIP or GeoCode providers.
- Since
- 1.8
Bitmask to indicate which of the supplied positions fields are valid.
enum GeoclueStatus |
- Since
- 1.8
Status of a GeoClue provider.
- Since
- 1.8
Bitmask to indicate which of the supplied velocity fields are valid.
Function Documentation
EAPI void elocation_address_free | ( | Elocation_Address * | address | ) |
Free an address object.
- Parameters
-
address Address object to be freed.
Destroys an address object created with elocation_address_new. Should be used during the cleanup of the application or whenever the address object is no longer needed.
- Since
- 1.8
EAPI Eina_Bool elocation_address_get | ( | Elocation_Address * | address | ) |
Get the current address information.
- Parameters
-
address Address struct to be filled with information.
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
Request the latest address. The requested to the underling components might be asynchronous so better check the timestamp if the data has changed. To get events when the address changes one can also subscribe to the ELOCATION_EVENT_ADDRESS ecore event which will have the address object as event.
- Since
- 1.8
EAPI Elocation_Address* elocation_address_new | ( | void | ) |
Create a new address object to operate on.
- Returns
- Address object.
The returned address object is safe to be operated on. It can be used for all other elocation functions. Once finished with it it need to be destroyed with a call to elocation_address_free.
- Since
- 1.8
EAPI Eina_Bool elocation_address_to_position | ( | Elocation_Address * | address_shadow, |
Elocation_Position * | position_shadow | ||
) |
Convert address to position.
- Parameters
-
address_shadow Address input position_shadow Position output
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
Use a GeoCode provider to translate from a given textual form representation of a location to a representation as GPS coordinates.
- Since
- 1.8
EAPI Eina_Bool elocation_freeform_address_to_position | ( | const char * | freeform_address, |
Elocation_Position * | position_shadow | ||
) |
Convert free form address tring to position.
- Parameters
-
freeform_address Address string in free form position_shadow Position output
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
Similar GeoCode translation from textual form to GPS coordinates as elocation_address_to_position but in this case the address is a simple string which hopefully contains enough information for the provider to understand and translate.
Useful for an easy search interface in an application but also more error prone regarding correct results.
- Since
- 1.8
EAPI Eina_Bool elocation_init | ( | void | ) |
Initialize the elocation subsystem.
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
This function must be called before using any of the Elocation functionality in your application to make sure it it setup correctly for usage.
- Since
- 1.8
References ELOCATION_EVENT_ADDRESS, ELOCATION_EVENT_GEOCODE, ELOCATION_EVENT_META_READY, ELOCATION_EVENT_NMEA, ELOCATION_EVENT_POI, ELOCATION_EVENT_POSITION, ELOCATION_EVENT_REVERSEGEOCODE, ELOCATION_EVENT_SATELLITE, ELOCATION_EVENT_STATUS, and ELOCATION_EVENT_VELOCITY.
EAPI Eina_Bool elocation_landmarks_get | ( | Elocation_Position * | position_shadow, |
Elocation_Address * | address_shadow | ||
) |
Request a landmark position.
- Parameters
-
position_shadow Position ouput address_shadow Address input
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
Request a landmark position also known as Point Of Interest (POI) from GeoClue.
- Since
- 1.8
EAPI void elocation_position_free | ( | Elocation_Position * | position | ) |
Free an position object.
- Parameters
-
position Position object to be freed.
Destroys a position object created with elocation_address_new. Should be used during the cleanup of the application or whenever the location object is no longer needed.
- Since
- 1.8
EAPI Eina_Bool elocation_position_get | ( | Elocation_Position * | position | ) |
Get the current position information.
- Parameters
-
position Position struct to be filled with information.
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
Request the latest position. The requested to the underling components might be asynchronous so better check the timestamp if the data has changed. To get events when the position changes one can also subscribe to the ELOCATION_EVENT_POSITION ecore event which will have the position object as event.
- Since
- 1.8
EAPI Elocation_Position* elocation_position_new | ( | void | ) |
Create a new position object to operate on.
- Returns
- Position object.
The returned address object is safe to be operated on. It can be used for all other elocation functions. Once finished with it it need to be destroyed with a call to elocation_address_free.
- Since
- 1.8
EAPI Eina_Bool elocation_position_to_address | ( | Elocation_Position * | position_shadow, |
Elocation_Address * | address_shadow | ||
) |
Convert position to address.
- Parameters
-
position_shadow Position input address_shadow Address output
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
Use a GeoCode provider to translate from a given GPS coordinate representation of a location to a representation in textual form.
- Since
- 1.8
EAPI Eina_Bool elocation_requirements_set | ( | Elocation_Requirements * | requirements | ) |
Set the requirements.
- Parameters
-
requirements Requirements
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
Set the requirements for selecting a provider.
- Since
- 1.8
EAPI void elocation_shutdown | ( | void | ) |
Cleanup and shutdown the elocation subsystem.
This function must be called when the application is no longer using any of the Elocation functionality to allow the subsystem to shutdown cleanly.
- Since
- 1.8
EAPI Eina_Bool elocation_status_get | ( | int * | status | ) |
Get the current status.
- Parameters
-
status Status
- Returns
- EINA_TRUE for success and EINA_FALSE for failure.
- Since
- 1.8
Variable Documentation
EAPI int ELOCATION_EVENT_STATUS |
Available location events that are emitted from the library.
- Since
- 1.8
Ecore events emitted by the library. Applications can register ecore event handlers to react on such events. After the initial query this can be used to keep track of changes and update your UI or data accordingly.Status changed
Referenced by elocation_init().