Garmin Fleet Management Controller
2.19.0
|
Data structure to hold details of an A603 stop that the server needs to keep. More...
#include <StopListItem.h>
Public Types | |
typedef uint32 | key_type |
Public Member Functions | |
StopListItem () | |
Constructor. More... | |
void | commitName () |
Commit the item name. More... | |
CString | getCurrentName () const |
Get the current name of this item. More... | |
const key_type & | getId () const |
Get item's ID. More... | |
stop_status_status_type | getStopStatus () const |
Get the stop status. More... | |
BOOL | isValid () const |
Check whether this item is valid. More... | |
virtual void | readFromStream (std::istream &aStream) |
Read a ClientListItem from an input stream. More... | |
void | setCurrentName (CString aName) |
Set the current name of the stop. More... | |
void | setId (const key_type &aId) |
Set item's ID. More... | |
void | setParent (FileBackedMap< StopListItem > *aParent) |
Set the parent. More... | |
void | setParent (FileBackedMap< ClientListItem > *aParent) |
Set the parent. More... | |
void | setStopStatus (stop_status_status_type aStatus) |
Set the stop status. More... | |
void | setUpdateName (CString aName) |
Set pending name. More... | |
void | setValid (BOOL aValid=TRUE) |
Set this item as valid. More... | |
virtual void | writeToStream (std::ofstream &aStream) const |
Write a ClientListItem to an output stream. More... | |
Protected Member Functions | |
virtual void | save () |
Save this item. More... | |
Protected Attributes | |
CString | mCurrentName |
The last name acknowledged by the client. More... | |
key_type | mId |
The unique ID of this item. More... | |
BOOL | mIsValid |
True if this list item is mIsValid. More... | |
CString | mUpdateName |
The last name entered by the user. More... | |
Private Attributes | |
FileBackedMap< StopListItem > * | mParent |
The map that this item belongs to, or NULL if none. More... | |
stop_status_status_type | mStopStatus |
The last known stop status for this stop. More... | |
Data structure to hold details of an A603 stop that the server needs to keep.
Definition at line 21 of file StopListItem.h.
typedef uint32 StopListItem::key_type |
Definition at line 24 of file StopListItem.h.
StopListItem::StopListItem | ( | ) |
Constructor.
Definition at line 16 of file StopListItem.cpp.
References INVALID_STOP_STATUS, and mStopStatus.
|
inherited |
Commit the item name.
Commit the item name and set the ClientListItem as valid
Definition at line 29 of file ClientListItem.cpp.
References ClientListItem::mCurrentName, ClientListItem::mUpdateName, and ClientListItem::setValid().
Referenced by FmiApplicationLayer::rx().
|
inherited |
Get the current name of this item.
Definition at line 39 of file ClientListItem.cpp.
References ClientListItem::mCurrentName.
Referenced by CDriverIdAndStatusDlg::OnLbnSelchangeStatuslist(), FmiApplicationLayer::procDriverStatusUpdate(), CSendSensorDlg::RefreshList(), and FmiApplicationLayer::rx().
|
inherited |
Get item's ID.
Get the unique ID of this item
Definition at line 49 of file ClientListItem.cpp.
References ClientListItem::mId.
Referenced by FmiApplicationLayer::rx().
stop_status_status_type StopListItem::getStopStatus | ( | ) | const |
Get the stop status.
Definition at line 31 of file StopListItem.cpp.
References mStopStatus, and setStopStatus().
Referenced by CStopListDlg::OnEventStopListChanged().
|
inherited |
Check whether this item is valid.
Definition at line 58 of file ClientListItem.cpp.
References ClientListItem::mIsValid, and ClientListItem::readFromStream().
Referenced by CFileTransferDlg::AddPSRtoStopList(), CAobrdDriversDlg::OnBnClickedSet(), FmiApplicationLayer::procDriverStatusUpdate(), and FmiApplicationLayer::rx().
|
virtual |
Read a ClientListItem from an input stream.
Read id and current name from the input stream, and updates the member variables appropriately.
aStream | The stream to read from |
Reimplemented from ClientListItem.
Definition at line 21 of file StopListItem.cpp.
References INVALID_STOP_STATUS, mStopStatus, and ClientListItem::readFromStream().
|
protectedvirtualinherited |
Save this item.
Invokes parent to save all items
Reimplemented in AobrdDriverItem, WaypointListItem, and DriverLoginItem.
Definition at line 172 of file ClientListItem.cpp.
References ClientListItem::mParent, and FileBackedMap< T >::save().
Referenced by ClientListItem::setValid().
void StopListItem::setCurrentName | ( | CString | aName | ) |
Set the current name of the stop.
aName | The new name of the stop |
Definition at line 65 of file StopListItem.cpp.
References ClientListItem::mCurrentName.
Referenced by CFileTransferDlg::AddPSRtoStopList(), CMapViewerDlg::addStopToCatalog(), CStopNewDlg::OnBnClickedOk(), FmiApplicationLayer::sendA603Stop(), CMapViewerDlg::sendRouteToDevice(), and setParent().
|
inherited |
Set item's ID.
aId | The item's ID |
Definition at line 101 of file ClientListItem.cpp.
References ClientListItem::mId, and ClientListItem::setParent().
Referenced by CSendSensorDlg::OnBnClickedCreate(), CStopNewDlg::OnBnClickedOk(), ClientListItem::readFromStream(), SensorListItem::readFromStream(), and FmiApplicationLayer::sendCannedMessage().
void StopListItem::setParent | ( | FileBackedMap< StopListItem > * | aParent | ) |
Set the parent.
aParent | The FileBackedMap that contains this item |
Definition at line 53 of file StopListItem.cpp.
References mParent, and setCurrentName().
Referenced by setStopStatus().
|
inherited |
Set the parent.
aParent | The FileBackedMap that contains this item |
Definition at line 113 of file ClientListItem.cpp.
References ClientListItem::mParent, and ClientListItem::setUpdateName().
Referenced by ClientListItem::setId().
void StopListItem::setStopStatus | ( | stop_status_status_type | aStatus | ) |
Set the stop status.
aStatus | The new stop status |
Definition at line 41 of file StopListItem.cpp.
References mStopStatus, and setParent().
Referenced by CFileTransferDlg::AddPSRtoStopList(), CMapViewerDlg::addStopToCatalog(), getStopStatus(), CStopNewDlg::OnBnClickedOk(), FmiApplicationLayer::rx(), FmiApplicationLayer::sendA603Stop(), and CMapViewerDlg::sendRouteToDevice().
|
inherited |
Set pending name.
Set the pending name of this ClientListItem. This does not become the item's name until commitName is called.
aName | The pending name to set |
Definition at line 127 of file ClientListItem.cpp.
References ClientListItem::mUpdateName, and ClientListItem::setValid().
Referenced by FmiApplicationLayer::sendCannedMessage(), FmiApplicationLayer::sendCannedResponse(), FmiApplicationLayer::sendCreateWaypointCat(), FmiApplicationLayer::sendDriverStatusListItem(), FmiApplicationLayer::sendWaypoint(), and ClientListItem::setParent().
|
inherited |
Set this item as valid.
Set the valid flag. If this item is part of a FileBackedMap, save the map.
aValid | If TRUE, the item is valid. |
Definition at line 141 of file ClientListItem.cpp.
References ClientListItem::mIsValid, ClientListItem::save(), and ClientListItem::writeToStream().
Referenced by CFileTransferDlg::AddPSRtoStopList(), CMapViewerDlg::addStopToCatalog(), ClientListItem::commitName(), CSendSensorDlg::OnBnClickedCreate(), CStopNewDlg::OnBnClickedOk(), SensorListItem::readFromStream(), FmiApplicationLayer::rx(), FmiApplicationLayer::sendA603Stop(), FmiApplicationLayer::sendDeleteWaypointCat(), CMapViewerDlg::sendRouteToDevice(), AobrdDriverItem::setCarrierID(), AobrdDriverItem::setCarrierName(), AobrdDriverItem::setFirstName(), AobrdDriverItem::setLastName(), AobrdDriverItem::setLoadTypeRuleset(), AobrdDriverItem::setLongTermRuleset(), DriverLoginItem::setPassword(), AobrdDriverItem::setPassword(), AobrdDriverItem::setTimeZone(), and ClientListItem::setUpdateName().
|
virtualinherited |
Write a ClientListItem to an output stream.
Append id and current name to the output stream.
aStream | The stream to write to |
Reimplemented in AobrdDriverItem, DriverLoginItem, and WaypointListItem.
Definition at line 155 of file ClientListItem.cpp.
References ClientListItem::mCurrentName, and ClientListItem::mId.
Referenced by ClientListItem::setValid(), WaypointListItem::writeToStream(), and SensorListItem::writeToStream().
|
protectedinherited |
The last name acknowledged by the client.
Definition at line 75 of file ClientListItem.h.
Referenced by ClientListItem::ClientListItem(), ClientListItem::commitName(), ClientListItem::getCurrentName(), ClientListItem::readFromStream(), setCurrentName(), SensorListItem::setCurrentName(), and ClientListItem::writeToStream().
|
protectedinherited |
The unique ID of this item.
Definition at line 84 of file ClientListItem.h.
Referenced by ClientListItem::getId(), ClientListItem::readFromStream(), ClientListItem::setId(), and ClientListItem::writeToStream().
|
protectedinherited |
True if this list item is mIsValid.
Definition at line 81 of file ClientListItem.h.
Referenced by ClientListItem::ClientListItem(), ClientListItem::isValid(), InboxListItem::readFromStream(), DriverLoginItem::readFromStream(), ClientListItem::readFromStream(), AobrdDriverItem::readFromStream(), and ClientListItem::setValid().
|
private |
The map that this item belongs to, or NULL if none.
Definition at line 59 of file StopListItem.h.
Referenced by setParent().
|
private |
The last known stop status for this stop.
Definition at line 56 of file StopListItem.h.
Referenced by getStopStatus(), readFromStream(), setStopStatus(), and StopListItem().
|
protectedinherited |
The last name entered by the user.
Definition at line 78 of file ClientListItem.h.
Referenced by ClientListItem::ClientListItem(), ClientListItem::commitName(), ClientListItem::readFromStream(), and ClientListItem::setUpdateName().