Maps SDK for C++ 1.0.0
Loading...
Searching...
No Matches
gem::sense::ICompass Class Referenceabstract

Definition of Compass interface. More...

Inheritance diagram for gem::sense::ICompass:
Collaboration diagram for gem::sense::ICompass:

Public Types

enum class  EAccuracy { Unknown = 0 , Low , Medium , High }
 Values that represent the accuracy of the compass. More...

Public Member Functions

virtual double getHeading () const =0
 Get magnetic heading, 0 representing magnetic north.
virtual EAccuracy getAccuracy () const =0
EDataType getType () const override final
 Get data type.
virtual LargeInteger getAcquisitionTimestamp () const =0
Time getTime () const
template<typename TDerivedType>
StrongPointer< TDerivedType > cast ()
 Cast to a derived type.

Static Public Member Functions

static bool isSameType (const IData *ptr)
 Check if two data elements have the same type.

Detailed Description

Definition of Compass interface.

Member Enumeration Documentation

◆ EAccuracy

Values that represent the accuracy of the compass.

Enumerator
Unknown 

The compass accuracy is unknown.

Low 

Low accuracy; the direction may be unreliable.

Medium 

Medium accuracy; the direction is somewhat reliable, but not precise.

High 

High accuracy; the direction is very reliable and precise.

Member Function Documentation

◆ cast()

template<typename TDerivedType>
StrongPointer< TDerivedType > gem::sense::IData::cast ( )
inlineinherited

Cast to a derived type.

Returns
The requested derived type as a shared pointer.

◆ getAccuracy()

virtual EAccuracy gem::sense::ICompass::getAccuracy ( ) const
pure virtual
Returns
Heading accuracy

◆ getAcquisitionTimestamp()

virtual LargeInteger gem::sense::IData::getAcquisitionTimestamp ( ) const
pure virtualinherited
Returns
Acquisition timestamp in milliseconds since 1970 ( epoch )

Implemented in gem::sense::MockPosition.

◆ getHeading()

virtual double gem::sense::ICompass::getHeading ( ) const
pure virtual

Get magnetic heading, 0 representing magnetic north.

Returns
Magnetic heading in degrees

◆ getTime()

Time gem::sense::IData::getTime ( ) const
inlineinherited
Returns
System acquisition time

◆ getType()

EDataType gem::sense::IDataWithType< DerivedType >::getType ( ) const
inlinefinaloverridevirtualinherited

Get data type.

Returns
The data type.

Implements gem::sense::IData.

◆ isSameType()

bool gem::sense::IDataWithType< DerivedType >::isSameType ( const IData * ptr)
inlinestaticinherited

Check if two data elements have the same type.

Parameters
ptrThe other IData pointer to check against.
Returns
True if of same type, false if not.