AppCore
Loading...
Searching...
No Matches
Functions | Variables
cardeventreader.h File Reference
#include "appcore/cardevent/cardeventidxfilemanager.h"
#include "appcore/cardevent/cardeventdatfilemanager.h"
#include "appcore/cardevent/eventpurse.h"
#include "appcore/cardevent/EventPrepaidTicket.h"
#include "appcore/cardevent/eventblacklist.h"
#include "appcore/cardevent/EventPrepaidTicketZone.h"
#include "appcore/cardevent/EventPrepaidTicketRange.h"
#include "appcore/cardevent/deletedevent.h"
#include "appcore/cardevent/EventProlongPrepaidTicket.h"
#include <stdint.h>
Include dependency graph for cardeventreader.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

 ~CardEventReader ()
 
void Init (__ESTRING path)
 
CardEventCol __EDATAPTR GetEvents (long long SNR)
 
CardEventCol __EDATAPTR GetEvents (__EBYTEARR __EDATAPTR idx_dat_FileBuffer)
 
static void GetIdxDatMemPtrs (__EBYTEARR __EDATAPTR idx_dat_FileBuffer, __EBYTEARR __EDATAPTR __EVALREF idxFileBuffer, __EBYTEARR __EDATAPTR __EVALREF datFileBuffer, uint32_t __EVALREF idxFileSize, uint32_t __EVALREF datFileSize)
 
unsigned long GetValidFrom ()
 
unsigned long GetValidTo ()
 
unsigned long GetMaxCardEventID ()
 
char GetEventFileVersion ()
 
static char GetEventFileVersion (__ESTRING path)
 
long GetEventsCount ()
 
char GetFileType ()
 

Variables

__ECLASS CardEventReaderPr
 
__EPUBLIC __ECLASS LIBCARDEVENT_API CardEventReader
 The main class of cardevent library. It provides functionality for manipulating with event files.
 

Function Documentation

◆ GetEventFileVersion() [1/2]

char GetEventFileVersion ( )

Returns event file version

Returns
char - event file version

◆ GetEventFileVersion() [2/2]

static char GetEventFileVersion ( __ESTRING  path)
static

Returns event file version Function provided for convenience

Parameters
path: string - absolute path to event files without any extension. ( e.g. /tmp/events )
Returns
char - event file version

◆ GetEvents() [1/2]

CardEventCol __EDATAPTR GetEvents ( __EBYTEARR __EDATAPTR  idx_dat_FileBuffer)

Looks for events

Parameters
idx_dat_FileBuffer: data stream - event file data
Returns
CardEventCol - collection of events for specified card

◆ GetEvents() [2/2]

CardEventCol __EDATAPTR GetEvents ( long long  SNR)

Looks for events

Parameters
SNR: long long - card serial number (or -1 for all events)
Returns
CardEventCol - collection of events for specified card

◆ GetEventsCount()

long GetEventsCount ( )

Returns event count

Returns
long : event count

◆ GetFileType()

char GetFileType ( )

Returns file type for internal use

See also
CardEventCreator::SetFileType
Returns
char - file type

◆ GetIdxDatMemPtrs()

static void GetIdxDatMemPtrs ( __EBYTEARR __EDATAPTR  idx_dat_FileBuffer,
__EBYTEARR __EDATAPTR __EVALREF  idxFileBuffer,
__EBYTEARR __EDATAPTR __EVALREF  datFileBuffer,
uint32_t __EVALREF  idxFileSize,
uint32_t __EVALREF  datFileSize 
)
static

Splits combined event file to .idx and .dat parts

Parameters
idx_dat_FileBuffer: data stream - combined event file data
idxFileBuffer: data stream [output] - index event file data
datFileBuffer: data stream [output] - event file data
idxFileSize: unsigned long [output] - size of index event file
datFileSize: unsigned long [output] - size of event file

◆ GetMaxCardEventID()

unsigned long GetMaxCardEventID ( )

Returns the highest event ID in event file

Returns
unsigned long - event ID

◆ GetValidFrom()

unsigned long GetValidFrom ( )

Returns beginning of event file validity

Returns
unsigned long - event file validity as unix timestamp (number of seconds since January 1st, 1970)

◆ GetValidTo()

unsigned long GetValidTo ( )

Returns end of event file validity

Returns
unsigned long - event file validity as unix timestamp (number of seconds since January 1st, 1970)

◆ Init()

void Init ( __ESTRING  path)

Initialize the reader

Parameters
path: string - absolute path to event files without any extension. ( e.g. /tmp/events )

◆ ~CardEventReader()

Variable Documentation

◆ CardEventReader

Initial value:
{
private:
__ECLASS CardEventReaderPr
Definition cardeventreader.h:15
#define __EDATAPTR
Definition managed_defines.h:14

The main class of cardevent library. It provides functionality for manipulating with event files.

Before using it has to be initialized by calling Init method and providing path to event files - this path is supposed not to contain file extension (.dat or .idx shall be added internally)

◆ CardEventReaderPr

__ECLASS CardEventReaderPr