A class which reads logical values from SDS argument structures. More...
#include <Git.h>
Public Member Functions | |
GitBool () | |
Simple constructor with a default value of false. More... | |
GitBool (const SdsId &Id, const char *const Name, const int Position, StatusType *const status, const bool Default=false, const int Flags=(Git::Upper|Git::Abbrev)) | |
Constructor with the initial value set from an SDS structure. More... | |
virtual | ~GitBool () |
Destructor. More... | |
virtual void | Get (const SdsId &Id, const char *const Name, const int Position, StatusType *const status, const bool Default=false, const int Flags=(Git::Upper|Git::Abbrev)) |
Get the value of the object from an SDS struture. More... | |
operator int () const | |
Conversion operator - given GitBool, return an int. More... | |
operator bool () const | |
Conversion operator - given GitBool, return a bool. More... | |
Protected Member Functions | |
virtual const GitLogStrType * | Lookup () |
Return a pointer to an array of enum strings equivalents. More... | |
Additional Inherited Members | |
![]() | |
enum | { Upper =GIT_M_ARG_UPPER, Lower =GIT_M_ARG_UPPER, KeepErr =GIT_M_ARG_KEEPERR, Abbrev = GIT_M_ARG_ABBREV, LastBit =GIT_M_ARG_LASTBIT } |
A class which reads logical values from SDS argument structures.
This is C++ class which provides an interface to GitArgGetL(). It Implements a boolean type which includes the operation GotBool::Get , to fetch its value from an Sds structure.
By default, the string combinations "YES/NO" and "TRUE/FALSE" are accepted as boolean values, any input string being converted to upper case and abbreviations being accepted. There is also a constructor which does the Get operation.
By overriding the method GitEnum::Lookup in an inheriting class, you can supplied alternative lists of True/False strings.
|
inline |
Simple constructor with a default value of false.
|
inline |
Constructor with the initial value set from an SDS structure.
Id | The SDS structure. |
Name | The name of the item within the structure. |
Position | If the item does not exist by the name, then presume this position. |
status | Inherited status |
Default | The default value. |
Flags | Which GIT Flags to apply |
|
inlinevirtual |
Destructor.
|
inlinevirtual |
Get the value of the object from an SDS struture.
This is the function which is used to set the value of the object. It is passed an SDS structure and looks for the item within that structure.
Id | The SDS structure. |
Name | The name of the item within the structure. |
Position | If the item does not exist by the name, then presume this position. |
status | Inherited status |
Default | The default value. |
Flags | Which GIT Flags to apply |
|
inlineprotectedvirtual |
Return a pointer to an array of enum strings equivalents.
The integer index of the string in this array is passed to GitEnum::SetValue when the value is set
|
inline |
Conversion operator - given GitBool, return a bool.
|
inline |
Conversion operator - given GitBool, return an int.
Click here for the DRAMA home page and here for the AAO home page.
For more information, contact tjf@aao.gov.au Generated on Mon Feb 22 2016 13:58:31 for AAO DRAMA C++ Interfaces by