gltools::GlToolsCallbacks Class Reference

Defines callbacks required by GlTools class. More...

#include <gltoolsapi.h>

Inheritance diagram for gltools::GlToolsCallbacks:
Collaboration diagram for gltools::GlToolsCallbacks:

List of all members.

Public Member Functions

virtual ~GlToolsCallbacks ()
 Define virtual destructor.
virtual int OnNmeaOpen (const plain_char *pcName)=0
 Request to Create/Open the NMEA output/request writer.
virtual void OnNmeaClose (int writer)=0
 Request to close the NMEA output/request writer.
virtual void OnNmeaWrite (int writer, const plain_char *pcNmea, short sBuffSize)=0
 Request to write NMEA to the output.
virtual void OnNmeaCustom (int writer, const GL_FIX_STATUS &fixStatus)=0
 Gives opportunity to generate a custom NMEA message per position fix.
virtual int OnPutPendingEvent (GlToolsCbOnPendingEvent cb)=0
 Request to call cb() function during the next event processing cycle.
virtual short OnGetSyncInTime (GL_TIME *pstGlTime, UTC_TIME *pstUtcTime)=0
 Query the status of the sync in time.
virtual unsigned long OnRandomSleep (unsigned long)
 Sleep for random number of seconds.
virtual void OnNmeaFactTest (int, const GL_FACT_TEST_STATUS *)
 Deprecated function.

Detailed Description

Defines callbacks required by GlTools class.


Member Function Documentation

virtual short gltools::GlToolsCallbacks::OnGetSyncInTime ( GL_TIME pstGlTime,
UTC_TIME pstUtcTime 
) [pure virtual]

Query the status of the sync in time.

Parameters:
pstGlTime[out] GL time
pstUtcTime[out] UTC time
Returns:
0 - success
virtual void gltools::GlToolsCallbacks::OnNmeaClose ( int  writer) [pure virtual]

Request to close the NMEA output/request writer.

Parameters:
writerHandle to request writer implementation obtained from call to GpsHalNmeaOpen().
virtual void gltools::GlToolsCallbacks::OnNmeaCustom ( int  writer,
const GL_FIX_STATUS fixStatus 
) [pure virtual]

Gives opportunity to generate a custom NMEA message per position fix.

Parameters:
writerId of NMEA writer implementation obtained from call to GpsHalNmeaOpen().
fixStatusreference to structure with detailed position fix information, see GL_FIX_STATUS.
virtual int gltools::GlToolsCallbacks::OnNmeaOpen ( const plain_char *  pcName) [pure virtual]

Request to Create/Open the NMEA output/request writer.

Parameters:
pcNameOne of the request types defined here.
Returns:
-1 if failed, all other values are considered successful and returns "writer" value which is used in all other NMEA functions
Precondition:
pcNmea != NULL
virtual void gltools::GlToolsCallbacks::OnNmeaWrite ( int  writer,
const plain_char *  pcNmea,
short  sBuffSize 
) [pure virtual]

Request to write NMEA to the output.

Parameters:
writerId of writer implementation obtained from call to GpsHalNmeaOpen().
pcNmeaStorage location of properly formatted, valid NMEA sentence
sBuffSizelength of NMEA sentence
Precondition:
pcNmea != NULL
virtual int gltools::GlToolsCallbacks::OnPutPendingEvent ( GlToolsCbOnPendingEvent  cb) [pure virtual]

Request to call cb() function during the next event processing cycle.

Return values:
Return0 on success
virtual unsigned long gltools::GlToolsCallbacks::OnRandomSleep ( unsigned long  ) [inline, virtual]

Sleep for random number of seconds.

Parameters:
maxSecMaximum number of seconds to sleep.
Return values:
Returnnumber of seconds spent in sleep or ~0ul RANDOM_SLEEP_NOT_SUPPORTED if RandomSleep() feature is not available.

The documentation for this class was generated from the following file:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Defines