AppCore
Loading...
Searching...
No Matches
Snapshot.h
Go to the documentation of this file.
1#ifndef SNAPSHOT_H
2#define SNAPSHOT_H
3
4// SYSTEM INCLUDES
5#include <string>
6#include <vector>
7
8// BASE INCLUDES
9#include "../ETicketIssueLogicDefines.h"
10
11class QDomDocument;
12class QDomElement;
13
14namespace EM
15{
16 namespace TicketIssueLogic
17 {
19 {
21
22 class DataClass;
23 DataClass *d;
24
26
27 public:
29 {
30 TypeUndefined = 0,
31 TypeOneWayTicket = 1,
32 TypeTimeTicket = 2
33 };
34
35 void SetCardUID( const std::string &uid );
36 void SetTicketNumber( const unsigned long ticketNumber );
37 void SetTimeStamp( const unsigned long timeStamp );
38
39 const std::string& GetCardUID() const;
40 unsigned long GetTicketNumber() const;
41 SnapshotType GetSnapshotType() const;
42 unsigned long GetTimeStamp() const;
43
50 virtual bool Serialize( QDomDocument &doc, QDomElement &newElement ) const;
51
57 virtual bool Deserialize( const QDomElement &xmlElement );
58
66 static bool Check( const QDomElement &xmlElement, const std::string &cardUID, const unsigned long ticketNumber, const SnapshotType type );
67
74 static bool ExtractTimeStamp( const QDomElement &xmlElement, unsigned long &timeStamp );
75
76 protected:
77 Snapshot( const SnapshotType type );
78 virtual ~Snapshot();
79
80 };
81 }
82}
83
84#endif //SNAPSHOT_H
virtual void Deserialize(char *buffer)
virtual void Serialize(char *buffer)
#define DLL_API
Definition ECardFacadeDefines.h:8
Definition Snapshot.h:19
SnapshotType
Definition Snapshot.h:29
SYSTEM INCLUDES.
Definition CardFacadeManagerXML.h:7