plptools
Loading...
Searching...
No Matches
PsiZone Class Reference

A singleton wrapper for a psi_timezone . More...

#include <psitime.h>

Collaboration diagram for PsiZone:

Public Member Functions

bool getZone (psi_timezone &ptz)
 Retrieve the Psion time zone.
 

Static Public Member Functions

static PsiZonegetInstance ()
 Retrieve the singleton object.
 

Private Member Functions

 PsiZone ()
 Private constructor.
 
void setZone (psi_timezone &ptz)
 

Private Attributes

bool _ptzValid
 
psi_timezone _ptz
 

Static Private Attributes

static PsiZone_instance = 0L
 This objects instance (singleton)
 

Friends

class RPCS32
 

Detailed Description

A singleton wrapper for a psi_timezone .

This class is used by PsiTime to initialize its psi_timezone variable. PsiZone itself is initialized from within RPCS::getMachineInfo . In an application, you typically call this at the very beginning, just after connection setup. From then on, a single PsiZone instance is held in memory and used by the various constructors of PsiTime.

Author
Fritz Elfert felfe.nosp@m.rt@t.nosp@m.o.com

Definition at line 325 of file psitime.h.

Constructor & Destructor Documentation

◆ PsiZone()

PsiZone::PsiZone ( )
private

Private constructor.

Definition at line 292 of file psitime.cc.

Member Function Documentation

◆ getInstance()

PsiZone & PsiZone::getInstance ( )
static

Retrieve the singleton object.

If it does not exist, it is created.

Definition at line 285 of file psitime.cc.

◆ getZone()

bool PsiZone::getZone ( psi_timezone & ptz)

Retrieve the Psion time zone.

Parameters
ptzThe time zone is returned here.
Returns
false, if the time zone is not known (yet).

Definition at line 302 of file psitime.cc.

◆ setZone()

void PsiZone::setZone ( psi_timezone & ptz)
private

Definition at line 296 of file psitime.cc.

Friends And Related Symbol Documentation

◆ RPCS32

friend class RPCS32
friend

Definition at line 326 of file psitime.h.

Member Data Documentation

◆ _instance

PsiZone * PsiZone::_instance = 0L
staticprivate

This objects instance (singleton)

Definition at line 349 of file psitime.h.

◆ _ptz

psi_timezone PsiZone::_ptz
private

Definition at line 359 of file psitime.h.

◆ _ptzValid

bool PsiZone::_ptzValid
private

Definition at line 358 of file psitime.h.


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