Maps SDK for C++ 1.0.0
Loading...
Searching...
No Matches
gem::Landmark Class Reference

Landmark object. More...

Inheritance diagram for gem::Landmark:
Collaboration diagram for gem::Landmark:

Public Member Functions

 Landmark (const Landmark &)=default
 Default copy constructor.
 Landmark (Landmark &&)=default
 Default move constructor noexcept is deduced.
Landmark & operator= (const Landmark &lmk)=default
 Default copy assignment.
Landmark & operator= (Landmark &&lmk)=default
 Default move assignment noexcept is deduced.
 Landmark (const String &name, const Coordinates &coordinates)
 Constructor taking name and coordinates.
int getLandmarkId () const noexcept
 Get the landmark ID.
int getLandmarkStoreId () const noexcept
 If the landmark store is set then it returns the landmark store ID (>0).
int getLandmarkStoreType () const noexcept
 If the landmark store is set then it returns the landmark store type( see ELandmarkStoreType ) (>0).
const CoordinatesRef getCoordinates () const noexcept
 Get the centroid coordinates.
CoordinatesRef getCoordinates () noexcept
 Get direct access to the coordinates attached to this landmark (centroid coordinates).
Landmark & setCoordinates (Coordinates const &coords) noexcept
 Set the centroid coordinates.
const EntranceLocationsRef getEntrances () const noexcept
 Get the entrance locations.
EntranceLocationsRef getEntrances () noexcept
 Get direct access to the entrance locations.
GeographicArea getGeographicArea () const noexcept
 Get geographic area.
Landmark & setGeographicArea (GeographicArea const &ga) noexcept
 Set geographic area.
const ImageRef getImage () const noexcept
 Get the landmark image.
Landmark & setImage (Image const &img) noexcept
 Set the image of this landmark.
const ImageRef getExtraImage () const noexcept
 Get the landmark extra image.
Landmark & setExtraImage (Image const &img) noexcept
 Set the landmark extra image.
const AddressInfoRef getAddress () const noexcept
 Get the address of this landmark.
AddressInfoRef getAddress () noexcept
 Get direct access to the address info attached to this landmark.
Landmark & setAddress (AddressInfo const &addr) noexcept
 Set the address of this landmark.
const StringRef getName () const noexcept
 Get the name of this landmark.
Landmark & setName (String const &name) noexcept
 Set the name of this landmark.
const StringRef getDescription () const noexcept
 Get the description of this landmark.
Landmark & setDescription (String const &desc) noexcept
 Set the description of this landmark.
const StringRef getAuthor () const noexcept
 Get the author of this landmark.
Landmark & setAuthor (String const &auth) noexcept
 Set the author of this landmark.
int getProviderId () const noexcept
 Get provider id of this landmark.
Landmark & setProviderId (int providerId) noexcept
 Set provider id of this landmark.
const TimeRef getTimeStamp () const noexcept
 Get the timestamp.
Landmark & setTimeStamp (Time const &time) noexcept
 Set the timestamp.
const ContactInfoRef getContactInfo () const noexcept
 Get const ref contact info attached to this landmark Phone numbers & descriptions, email addresses & descriptions, URLs & descriptions.
ContactInfoRef getContactInfo () noexcept
 Get direct access to the contact info attached to this landmark.
Landmark & setContactInfo (ContactInfo const &ci) noexcept
 Set the contact info.
const StringListRef getExtraInfo () const noexcept
 Get extra info.
StringListRef getExtraInfo () noexcept
 Get direct access to the extra info attached to this landmark.
Landmark & setExtraInfo (StringList const &list) noexcept
 Set extra info.
Landmark & addExtraInfo (String const &info) noexcept
 Add extra info.
String findExtraInfo (const String &startStr) const noexcept
 Find extra info.
int getCategories (LandmarkCategoryList &categories) const noexcept
 Get landmark categories list.
LandmarkCategoryList getCategories () const noexcept
 Get landmark categories list.
void detachFromStore () noexcept
 Detach the landmark from the parent landmark store.
RectangleGeographicArea getContourGeograficArea (bool relevantOnly=true) const noexcept
 Get contour rectangle geographic area.
const OverlayItemRef getOverlayItem () const noexcept
 Get the overlay item attached to a landmark.
GeofenceProximityArea getGeofenceItem () const noexcept
 Get the geofence item attached to a landmark.

Detailed Description

Landmark object.

Implements share-read / copy-on-write Api object over ILandmark.

Constructor & Destructor Documentation

◆ Landmark()

gem::Landmark::Landmark ( const String & name,
const Coordinates & coordinates )
inline

Constructor taking name and coordinates.

Parameters
nameLandmark name
coordinatesLandmark coordinates

Member Function Documentation

◆ addExtraInfo()

Landmark & gem::Landmark::addExtraInfo ( String const & info)
inlinenoexcept

Add extra info.

Parameters
infoExtra info to add
Returns
reference to this object

◆ detachFromStore()

void gem::Landmark::detachFromStore ( )
inlinenoexcept

Detach the landmark from the parent landmark store.

After this call, the getLandmarkStoreId() will return -1

◆ findExtraInfo()

String gem::Landmark::findExtraInfo ( const String & startStr) const
inlinenoexcept

Find extra info.

Parameters
startStrStart string
Returns
Extra info string

◆ getAddress() [1/2]

const AddressInfoRef gem::Landmark::getAddress ( ) const
inlinenoexcept

Get the address of this landmark.

On return the parameter fields are set to the correct values. Some of them (or all) may be empty.

Returns
AddressInfoRef for the landmark address

◆ getAddress() [2/2]

AddressInfoRef gem::Landmark::getAddress ( )
inlinenoexcept

Get direct access to the address info attached to this landmark.

Returns
AddressInfoRef for the landmark address

◆ getAuthor()

const StringRef gem::Landmark::getAuthor ( ) const
inlinenoexcept

Get the author of this landmark.

On return the parameter is set to the field value. It may be empty.

Returns
StringRef for the landmark author

◆ getCategories() [1/2]

LandmarkCategoryList gem::Landmark::getCategories ( ) const
inlinenoexcept

Get landmark categories list.

Returns
LandmarkCategoryList object

◆ getCategories() [2/2]

int gem::Landmark::getCategories ( LandmarkCategoryList & categories) const
inlinenoexcept

Get landmark categories list.

Parameters
[out]categoriesLandmarkCategoryList object
Returns
error::KGeneral On error.

◆ getContactInfo() [1/2]

const ContactInfoRef gem::Landmark::getContactInfo ( ) const
inlinenoexcept

Get const ref contact info attached to this landmark Phone numbers & descriptions, email addresses & descriptions, URLs & descriptions.

Returns
ContactInfoRef for the landmark contact info

◆ getContactInfo() [2/2]

ContactInfoRef gem::Landmark::getContactInfo ( )
inlinenoexcept

Get direct access to the contact info attached to this landmark.

Returns
ContactInfoRef for the landmark contact info

◆ getContourGeograficArea()

RectangleGeographicArea gem::Landmark::getContourGeograficArea ( bool relevantOnly = true) const
inlinenoexcept

Get contour rectangle geographic area.

Parameters
relevantOnlyIf true, it will return the relevant contour bounding box if it exists, otherwise the full contour bounding box
Returns
RectangleGeographicArea object

◆ getCoordinates() [1/2]

const CoordinatesRef gem::Landmark::getCoordinates ( ) const
inlinenoexcept

Get the centroid coordinates.

On return the parameter is set to the actual value. The coordinates may be invalid. This aspect needs to be checked by the API user.

Returns
CoordinatesRef for the landmark (read only)

◆ getCoordinates() [2/2]

CoordinatesRef gem::Landmark::getCoordinates ( )
inlinenoexcept

Get direct access to the coordinates attached to this landmark (centroid coordinates).

Returns
CoordinatesRef for the landmark (read/write)

◆ getDescription()

const StringRef gem::Landmark::getDescription ( ) const
inlinenoexcept

Get the description of this landmark.

On return the parameter is set to the field value. It may be empty.

Returns
StringRef for the landmark description

◆ getEntrances() [1/2]

const EntranceLocationsRef gem::Landmark::getEntrances ( ) const
inlinenoexcept

Get the entrance locations.

Returns
Locations & access type for entrances to the landmark.

◆ getEntrances() [2/2]

EntranceLocationsRef gem::Landmark::getEntrances ( )
inlinenoexcept

Get direct access to the entrance locations.

Returns
Locations & access type for entrances to the landmark.

◆ getExtraImage()

const ImageRef gem::Landmark::getExtraImage ( ) const
inlinenoexcept

Get the landmark extra image.

If no extra image is set, an empty object is returned

Returns
ImageRef for the landmark extra image

◆ getExtraInfo() [1/2]

const StringListRef gem::Landmark::getExtraInfo ( ) const
inlinenoexcept

Get extra info.

(read only)

Returns
StringListRef for the landmark extra info

◆ getExtraInfo() [2/2]

StringListRef gem::Landmark::getExtraInfo ( )
inlinenoexcept

Get direct access to the extra info attached to this landmark.

Returns
StringListRef for the landmark extra info

◆ getGeofenceItem()

GeofenceProximityArea gem::Landmark::getGeofenceItem ( ) const
inlinenoexcept

Get the geofence item attached to a landmark.

E.g. if the landmark is a result of a search in geofences

Returns
If exists, return a valid geofence item. Call bool(result) to check the result validity

◆ getGeographicArea()

GeographicArea gem::Landmark::getGeographicArea ( ) const
inlinenoexcept

Get geographic area.

Returns
GeographicArea object

◆ getImage()

const ImageRef gem::Landmark::getImage ( ) const
inlinenoexcept

Get the landmark image.

The API user is responsible to check if the image is valid.

Returns
ImageRef for the landmark image

◆ getLandmarkId()

int gem::Landmark::getLandmarkId ( ) const
inlinenoexcept

Get the landmark ID.

Returns
landmark id
error::KGeneral ( -1 ) if it does not have an associated ID, i.e. the landmark doesn't belong to a landmark store

◆ getLandmarkStoreId()

int gem::Landmark::getLandmarkStoreId ( ) const
inlinenoexcept

If the landmark store is set then it returns the landmark store ID (>0).

Returns
error::KGeneral On error.

◆ getLandmarkStoreType()

int gem::Landmark::getLandmarkStoreType ( ) const
inlinenoexcept

If the landmark store is set then it returns the landmark store type( see ELandmarkStoreType ) (>0).

Returns
error::KGeneral On error.

◆ getName()

const StringRef gem::Landmark::getName ( ) const
inlinenoexcept

Get the name of this landmark.

On return the parameter is set to the field value. It may be empty.

Returns
StringRef for the landmark name

◆ getOverlayItem()

const OverlayItemRef gem::Landmark::getOverlayItem ( ) const
inlinenoexcept

Get the overlay item attached to a landmark.

E.g. if the landmark is a result of a search in overlays

Returns
If exists, return a valid overlay item. Call bool(result) to check the result validity

◆ getProviderId()

int gem::Landmark::getProviderId ( ) const
inlinenoexcept

Get provider id of this landmark.

Returns
provider id

◆ getTimeStamp()

const TimeRef gem::Landmark::getTimeStamp ( ) const
inlinenoexcept

Get the timestamp.

If no value is set by the user, the timestamp will be set to the current time when the landmark is inserted in a landmark store

Returns
TimeRef for the landmark timestamp

◆ operator=() [1/2]

Landmark & gem::Landmark::operator= ( const Landmark & lmk)
default

Default copy assignment.

Parameters
lmkLandmark object to copy from
Returns
reference to this object

◆ operator=() [2/2]

Landmark & gem::Landmark::operator= ( Landmark && lmk)
default

Default move assignment noexcept is deduced.

Parameters
lmkLandmark object to move from
Returns
reference to this object

◆ setAddress()

Landmark & gem::Landmark::setAddress ( AddressInfo const & addr)
inlinenoexcept

Set the address of this landmark.

Parameters
addrAddressInfo object
Returns
reference to this object

◆ setAuthor()

Landmark & gem::Landmark::setAuthor ( String const & auth)
inlinenoexcept

Set the author of this landmark.

Parameters
authLandmark author
Returns
reference to this object

◆ setContactInfo()

Landmark & gem::Landmark::setContactInfo ( ContactInfo const & ci)
inlinenoexcept

Set the contact info.

Phone numbers & descriptions, email addresses & descriptions, URLs & descriptions

Parameters
ciContactInfo object
Returns
reference to this object

◆ setCoordinates()

Landmark & gem::Landmark::setCoordinates ( Coordinates const & coords)
inlinenoexcept

Set the centroid coordinates.

Parameters
coordsCoordinates to set
Returns
reference to this object

◆ setDescription()

Landmark & gem::Landmark::setDescription ( String const & desc)
inlinenoexcept

Set the description of this landmark.

Parameters
descLandmark description
Returns
reference to this object

◆ setExtraImage()

Landmark & gem::Landmark::setExtraImage ( Image const & img)
inlinenoexcept

Set the landmark extra image.

Parameters
imgImage to set
Returns
reference to this object

◆ setExtraInfo()

Landmark & gem::Landmark::setExtraInfo ( StringList const & list)
inlinenoexcept

Set extra info.

Parameters
listStringList object
Returns
reference to this object

◆ setGeographicArea()

Landmark & gem::Landmark::setGeographicArea ( GeographicArea const & ga)
inlinenoexcept

Set geographic area.

Parameters
gaGeographicArea object
Returns
reference to this object

◆ setImage()

Landmark & gem::Landmark::setImage ( Image const & img)
inlinenoexcept

Set the image of this landmark.

Parameters
imgImage to set
Returns
reference to this object

◆ setName()

Landmark & gem::Landmark::setName ( String const & name)
inlinenoexcept

Set the name of this landmark.

Parameters
nameLandmark name
Returns
reference to this object

◆ setProviderId()

Landmark & gem::Landmark::setProviderId ( int providerId)
inlinenoexcept

Set provider id of this landmark.

Parameters
providerIdprovider id
Returns
reference to this object

◆ setTimeStamp()

Landmark & gem::Landmark::setTimeStamp ( Time const & time)
inlinenoexcept

Set the timestamp.

Parameters
timeTime object
Returns
reference to this object