Qt Virtual Chart Table (QVCT)
CDeviceGpsdGps Class Reference

GPSD daemon (GPS mode) navigation device. More...

#include <devices/drivers/GpsdGps/CDeviceGpsdGps.hpp>

Inheritance diagram for CDeviceGpsdGps:
CDevice COverlayItem COverlayObject

Public Member Functions

 CDeviceGpsdGps (const QString &_rqsName)
 
virtual ~CDeviceGpsdGps ()
 
QVCT::EStatus setOperatingMode (CDevice::EOperatingMode _eOperatingMode)
 Sets the device's operating mode. More...
 
virtual CDeviceDriver::EDriver getDriver () const
 Returns the device's driver ID. More...
 
virtual int getCapabilities () const
 Returns the device's capabilities. More...
 
virtual void showDetail ()
 Displays the device's details (in the appropriate widget/view) More...
 
virtual void showEdit ()
 Displays the device's edit (configuration) widget/view. More...
 
void parseQVCT (const QDomElement &_rqDomElement)
 Retrieves the device's configuration from the given QVCT source (file) More...
 
void dumpQVCT (QXmlStreamWriter &_rqXmlStreamWriter) const
 Stores the device's configuration to the given QVCT destination (file) More...
 
void setHost (const QString &_rqsHost)
 
void setPort (int _iPort)
 
void setSource (const QString &_rqsSource)
 
QString getHost ()
 
int getPort ()
 
QString getSource ()
 
- Public Member Functions inherited from CDevice
virtual ~CDevice ()
 
virtual COverlayuseOverlay ()
 Returns this object's (base) overlay. More...
 
virtual EOperatingMode getOperatingMode ()
 Returns the device's operating mode. More...
 
- Public Member Functions inherited from COverlayItem
void setMultiSelected (bool _bMultiSelected)
 Sets this item's selection status. More...
 
bool isMultiSelected () const
 Returns this item's selection status. More...
 
- Public Member Functions inherited from COverlayObject
void setName (const QString &_rqsName)
 Sets this object's name. More...
 
QString getName () const
 Returns this object's name. More...
 
QString newChildName (const QString &_rqsName, int _iZeroPrefix=0, bool _bForceSuffix=false) const
 Returns a valid (non-duplicate) name for a new sibling of this object. More...
 
QString newChildName (const QString &_rqsName, int _iZeroPrefix, int _iSuffix) const
 Returns a suffixed (potentially duplicate) name for a new sibling of this object. More...
 

Private Slots

void slotProcessData (int)
 Slots to process device data. More...
 

Private Member Functions

QVCT::EStatus stop ()
 Start the device. More...
 
QVCT::EStatus pause ()
 Pause the device. More...
 
QVCT::EStatus start ()
 Stop the device. More...
 
CDevice::EOperatingMode status ()
 Returns the device's status (operating mode) More...
 

Private Attributes

QString qsHost
 Network host. More...
 
int iPort
 Network port. More...
 
QString qsSource
 Source (filter) More...
 
struct gps_data_t sGpsData
 GPSD data. More...
 
struct gps_data_t * psGpsData
 GPSD data pointer. More...
 
QSocketNotifier * pqSocketNotifier
 Socket notifier. More...
 
bool bPaused
 Pause status. More...
 

Additional Inherited Members

- Public Types inherited from CDevice
enum  ECapability { FIX = 1, SKYVIEW = 2 }
 Device capabilities. More...
 
enum  EOperatingMode { UNDEFINED, STOP, PAUSE, START }
 Device operating mode (stop, start, pause) More...
 
- Public Types inherited from COverlayObject
enum  EType {
  OVERLAY = 1001, CONTAINER = 1010, SUBCONTAINER = 1011, ITEM = 1100,
  SUBITEM1 = 1101, SUBITEM2 = 1102
}
 Overlay object type. More...
 
- Signals inherited from CDevice
void signalOperatingMode (CDevice::EOperatingMode _eOperatingMode)
 Signal emitted by the device when its operating mode changed. More...
 
void signalActivity ()
 Signal emitted by the device when activity occures. More...
 
void signalDataFix (const CDeviceDataFix &_roDeviceDataFix)
 Signal emitted by the device when an updated fix is available. More...
 
void signalDataSkyView (const CDeviceDataSkyView &_roDeviceDataSkyView)
 Signal emitted by the device when an updated sky view is available. More...
 
void signalError (const QString &_rqsErrorMessage)
 Signal emitted by the device when an error occured. More...
 
- Protected Member Functions inherited from CDevice
 CDevice (const QString &_rqsName)
 
- Protected Member Functions inherited from COverlayItem
 COverlayItem (COverlayObject::EType _eType, const QString &_rqsName)
 
virtual ~COverlayItem ()
 
- Protected Member Functions inherited from COverlayObject
 COverlayObject (EType _eType, const QString &_rqsName)
 
virtual ~COverlayObject ()
 
- Protected Attributes inherited from COverlayItem
bool bMultiSelected
 Item's selection status. More...
 
- Protected Attributes inherited from COverlayObject
QString qsName
 Object name. More...
 

Detailed Description

GPSD daemon (GPS mode) navigation device.

This class allows to interface with the GPSD daemon (via the network) and use the data corresponding to GPS activity.

Author
Cedric Dufour http://cedric.dufour.name

Definition at line 47 of file CDeviceGpsdGps.hpp.

Constructor & Destructor Documentation

◆ CDeviceGpsdGps()

CDeviceGpsdGps::CDeviceGpsdGps ( const QString &  _rqsName)

Definition at line 46 of file CDeviceGpsdGps.cpp.

◆ ~CDeviceGpsdGps()

CDeviceGpsdGps::~CDeviceGpsdGps ( )
virtual

Definition at line 56 of file CDeviceGpsdGps.cpp.

Member Function Documentation

◆ setOperatingMode()

QVCT::EStatus CDeviceGpsdGps::setOperatingMode ( CDevice::EOperatingMode  _eOperatingMode)
virtual

Sets the device's operating mode.

Implements CDevice.

Definition at line 66 of file CDeviceGpsdGps.cpp.

◆ getDriver()

virtual CDeviceDriver::EDriver CDeviceGpsdGps::getDriver ( ) const
inlinevirtual

Returns the device's driver ID.

Implements CDevice.

Definition at line 96 of file CDeviceGpsdGps.hpp.

◆ getCapabilities()

virtual int CDeviceGpsdGps::getCapabilities ( ) const
inlinevirtual

Returns the device's capabilities.

See also
ECapability

Implements CDevice.

Definition at line 97 of file CDeviceGpsdGps.hpp.

◆ showDetail()

void CDeviceGpsdGps::showDetail ( )
virtual

Displays the device's details (in the appropriate widget/view)

Implements CDevice.

Definition at line 93 of file CDeviceGpsdGps.cpp.

◆ showEdit()

void CDeviceGpsdGps::showEdit ( )
virtual

Displays the device's edit (configuration) widget/view.

Implements CDevice.

Definition at line 101 of file CDeviceGpsdGps.cpp.

◆ parseQVCT()

void CDeviceGpsdGps::parseQVCT ( const QDomElement &  _rqDomElement)
virtual

Retrieves the device's configuration from the given QVCT source (file)

Implements CDevice.

Definition at line 108 of file CDeviceGpsdGps.cpp.

◆ dumpQVCT()

void CDeviceGpsdGps::dumpQVCT ( QXmlStreamWriter &  _rqXmlStreamWriter) const
virtual

Stores the device's configuration to the given QVCT destination (file)

Implements CDevice.

Definition at line 117 of file CDeviceGpsdGps.cpp.

◆ slotProcessData

void CDeviceGpsdGps::slotProcessData ( int  )
privateslot

Slots to process device data.

Definition at line 142 of file CDeviceGpsdGps.cpp.

◆ setHost()

void CDeviceGpsdGps::setHost ( const QString &  _rqsHost)
inline

Definition at line 120 of file CDeviceGpsdGps.hpp.

◆ setPort()

void CDeviceGpsdGps::setPort ( int  _iPort)
inline

Definition at line 122 of file CDeviceGpsdGps.hpp.

◆ setSource()

void CDeviceGpsdGps::setSource ( const QString &  _rqsSource)
inline

Definition at line 124 of file CDeviceGpsdGps.hpp.

◆ getHost()

QString CDeviceGpsdGps::getHost ( )
inline

Definition at line 129 of file CDeviceGpsdGps.hpp.

◆ getPort()

int CDeviceGpsdGps::getPort ( )
inline

Definition at line 131 of file CDeviceGpsdGps.hpp.

◆ getSource()

QString CDeviceGpsdGps::getSource ( )
inline

Definition at line 133 of file CDeviceGpsdGps.hpp.

◆ stop()

QVCT::EStatus CDeviceGpsdGps::stop ( )
private

Start the device.

Definition at line 329 of file CDeviceGpsdGps.cpp.

◆ pause()

QVCT::EStatus CDeviceGpsdGps::pause ( )
private

Pause the device.

Definition at line 350 of file CDeviceGpsdGps.cpp.

◆ start()

QVCT::EStatus CDeviceGpsdGps::start ( )
private

Stop the device.

Definition at line 361 of file CDeviceGpsdGps.cpp.

◆ status()

CDevice::EOperatingMode CDeviceGpsdGps::status ( )
private

Returns the device's status (operating mode)

Definition at line 430 of file CDeviceGpsdGps.cpp.

Member Data Documentation

◆ qsHost

QString CDeviceGpsdGps::qsHost
private

Network host.

See also
setHost(), getHost()

Definition at line 58 of file CDeviceGpsdGps.hpp.

◆ iPort

int CDeviceGpsdGps::iPort
private

Network port.

See also
setPort(), getPort()

Definition at line 61 of file CDeviceGpsdGps.hpp.

◆ qsSource

QString CDeviceGpsdGps::qsSource
private

Source (filter)

See also
setSource(), getSource()

Definition at line 64 of file CDeviceGpsdGps.hpp.

◆ sGpsData

struct gps_data_t CDeviceGpsdGps::sGpsData
private

GPSD data.

See also
gps.h

Definition at line 67 of file CDeviceGpsdGps.hpp.

◆ psGpsData

struct gps_data_t* CDeviceGpsdGps::psGpsData
private

GPSD data pointer.

See also
gpsdclient.h

Definition at line 72 of file CDeviceGpsdGps.hpp.

◆ pqSocketNotifier

QSocketNotifier* CDeviceGpsdGps::pqSocketNotifier
private

Socket notifier.

Definition at line 74 of file CDeviceGpsdGps.hpp.

◆ bPaused

bool CDeviceGpsdGps::bPaused
private

Pause status.

Definition at line 76 of file CDeviceGpsdGps.hpp.


The documentation for this class was generated from the following files: