YGP Namespace Reference

This namespace holds plattform independend classes of common use. More...


Classes

class  ADate
 Class for date attributes. More...
class  ANumeric
 Class for numeric attributes. More...
class  AssignmentParse
 Class to parse a single assignment. More...
class  ATime
 Class for time attributes. More...
class  ATimestamp
 Class for timestamp (containing date and time) attributes. More...
class  IAttribute
 Baseclass for attributes. More...
class  Attribute
 Template representing an attribute of a specific type. More...
class  AttributeList
 Template for a list of attributes of a specific type. More...
class  MetaEnumAttribute
 An attribute to assign an integer-value from a list of string-values. More...
class  AttributeMap
 Template for a map of attributes of a specific type. More...
class  AttributeParse
 Class to parse attribute-assignments from a string and sets its values into attribute-values. More...
class  AttributValue
 Base-class for all attribut-values. More...
class  AYear
 Class for year attributes. More...
class  ConnectionMgr
 Class to handle the connections an application can have. More...
class  RegularExpression
 Class to compare text with (UNIX-style) regular expressions. More...
class  DirectorySearch
 Class to search for files in a certain (locally accesable) directory. More...
class  DynTrace
 Class for writing trace-messages, which can be dynamically switched on and off at runtime. More...
class  DynTraceManager
 Class to manage the created DynTraces classes. More...
class  Entity
 Baseclass for classes holding (a list of) attributes. More...
class  FileError
 Exception indicating an error handling files. More...
class  CommError
 Exception indicating an error handling network communication. More...
class  ParseError
 Exception indicating an error parsing. More...
class  ExecError
 Exception indicating an error executing a program. More...
class  InvalidValue
 Exception indicating an invalid value. More...
struct  File
 Class representing a file in the file system of the operating system. More...
class  FileRegularExpr
 Class to compare text with (UNIX-file-style) regular expressions. More...
class  FileTypeChecker
 Base-class to check for file-types. More...
class  FileTypeCheckerByExtension
 Class to check for the type of a file (e.g. More...
class  FileTypeCheckerByCaseExt
 Class to check for the type of a file (e.g. More...
class  FileTypeCheckerByContent
 Type to check for type of files by the content of the file. More...
class  IDirectorySearch
 Abstract baseclass providing an interface for classes to search in directory-structures. More...
class  INISection
 Class to handle the information stored in a section of an INI-file (see INIFile for more details). More...
class  INIList
 Class to parse all entries of a section into a list (vector) of values (see INIFile for more details). More...
class  INIMap
 Class to parse all entries of a section into a list (map) of values (see INIFile for more details). More...
class  INIFile
 Class to handle the information of an INI-file (containing the settings of an application). More...
class  IVIOApplication
 Class to handle the startup of a program, which includes reading the data stored in an INI file and (afterwards) the parsing of the parameters before the actual run of the program. More...
class  Syslog
 Class to perform some logging to either a log-file (if available) or to the console. More...
class  MetaEnum
 Class to handle enumerations; in counterpart to C-style enums those values can be accessed by number and name. More...
class  Module
 Dynamically loading of modules. More...
class  Mutex
 Class for mutual exclusive devices. More...
class  ParseObject
 Classes to parse objects and sequences of objects from a stream. More...
class  ParseEOF
 Class to parse the end of a file (EOF). More...
class  ParseSkip
 Class to skip some characters (default from the current position in the stream). More...
class  ParseAttomic
 Class to parse an attomic value; Base-class of all attomic values. More...
class  ParseText
 Class to parse text until specified abort-characters are found. More...
class  ParseTextEsc
 Class to parse text until a certain abort-criteria (as in ParseText). More...
class  ParseQuoted
 Class to parse a quoted text-value until a specified abort-character is found. More...
class  ParseQuotedEsc
 Class to parse a quoted text-value until a specified abort-character is found. More...
class  ParseExact
 Class to parse exactly a certain text (case-sensitive!). More...
class  ParseUpperExact
 Class to parse exactly a certain text (not case-sensitive!). More...
class  ParseToText
 Class to parse text until the specified text is found. More...
class  ParseSequence
 Class to parse series of ParseObjects (sequences). More...
class  ParseSelection
 Class to parse a selection of one ParseObject out of a list. More...
class  CBParseEOF
 Class to check if EOF is parsed. More...
class  CBParseSkip
 Class to skip some characters (from the current position in the stream). More...
class  CBParseAttomic
 Class to parse a attomic value with callback-function if object was found. More...
class  CBParseText
 Class to parse text til a certain abort-criteria with a callback (executed if an object was found). More...
class  CBParseTextEsc
 Class to parse text til a certain abort-criteria (as in CBParseText). More...
class  CBParseQuoted
 Class to parse quoted text. More...
class  CBParseQuotedEsc
 Class to parse quoted text. More...
class  CBParseExact
 Class to parse exactly a certain text (case-sensitive!). More...
class  CBParseUpperExact
 Class to parse exactly a certain text (not case-sensitive!). More...
class  CBParseToText
 Class to parse text until the specified text is found. More...
class  CBParseSequence
 Class to parse sequences (series of ParseObjects). More...
class  CBParseSelection
 Class to parse selections (list of ParseObjects where just one entry must be valid). More...
class  OFParseEOF
 Class to check if EOF is parsed. More...
class  OFParseSkip
 Class to skip some characters (from the current position in the stream). More...
class  OFParseAttomic
 Class to parse a attomic value with callback-function if object found. More...
class  OFParseText
 Class to parse text til a certain abort-criteria with callback-found (called if an object was found). More...
class  OFParseTextEsc
 Class to parse text til a certain abort-criteria (as in OFParseText). More...
class  OFParseQuoted
 Class to parse quoted text; which is returned without the quotes. More...
class  OFParseQuotedEsc
 Class to parse quoted text; which is returned without the quotes. More...
class  OFParseExact
 Class to parse exactly a certain text (case-sensitive!). More...
class  OFParseUpperExact
 Class to parse exactly a certain text (not case-sensitive!). More...
class  OFParseToText
 Class to parse text until the specified text is found. More...
class  OFParseSequence
 Class to parse sequences (series of ParseObjects). More...
class  OFParseSelection
 Class to parse selections (list of ParseObjects where just one entry must be valid). More...
class  Path
class  PathDirectorySearch
 Class to search for files in directories listed in a path. More...
class  Process
 Class to execute a program either synchronlously or asynchronlously. More...
class  RemoteDirSearch
 Class to search for files in a directory over a network-connection. More...
class  RemoteDirSearchSrv
 Class for a server to enable remote directory searching. More...
class  IRegularExpression
 Base-class for any regular expression. More...
class  RelationManager
 Class to manage the created relations. More...
struct  lessDereferenced
 Functor for comparing boost::shared_ptrs. More...
class  IRelation
 Class connecting (relating) objects of two classes (which must be derived from boost::shared_ptr). More...
class  Relation1_1
 1-to-1 relation. More...
class  Relation1_N
 1-to-N relation without a limit for N. More...
class  Relation1_X
 1-to-N relation with a limited N. More...
class  RelationN_M
 N-to-M relation. More...
struct  RemoteFile
 Class representing a file on a remote server with simple management-functions. More...
class  Socket
 A socket is a generalized interprocess communication channel, which supports communication between unrelated processes, and even between processes running on different machines that communicate over a network. More...
class  SortedDirSearch
 Class to search for files in a certain directory. More...
class  StatusObject
 Object holding status information. More...
class  TableWriter
 Baseclass to write tabular information. More...
class  Thread
 Class to execute a certain function in a thread. More...
class  OThread
 Class to execute a member-function in a thread. More...
class  XDirectorySearch
 Template to add file in- and exlusion to the *DirectorySearch classes. More...
class  extStreambuf
 Extended streambuf, designed to parse text. More...
struct  extStream
 Extended stream, designed to parse text. More...

Typedefs

typedef struct File File
typedef int(* PARSECALLBACK )(const char *, unsigned int)
typedef YGP::RemoteFile RemoteFile
typedef boost::tokenizer
< boost::char_separator< char > > 
tokenizer
typedef XDirectorySearch
< DirectorySearch
ExtDirectorySearch
typedef XDirectorySearch
< RemoteDirSearch
ExtRemoteDirSearch
typedef XDirectorySearch
< PathDirectorySearch
ExtPathDirectorySearch
typedef extStream< std::istream > Xistream
typedef extStream< std::ifstream > Xifstream

Functions

ADate operator+ (const ADate &lhs, const ADate &rhs)
ADate operator- (const ADate &lhs, const ADate &rhs)
ANumeric operator+ (const ANumeric &lhs, const ANumeric &rhs)
ANumeric operator- (const ANumeric &lhs, const ANumeric &rhs)
ANumeric operator* (const ANumeric &lhs, const ANumeric &rhs)
ANumeric operator/ (const ANumeric &lhs, const ANumeric &rhs)
ATime operator+ (const ATime &lhs, const ATime &rhs)
ATime operator- (const ATime &lhs, const ATime &rhs)
ATimestamp operator+ (const ATimestamp &lhs, const ATimestamp &rhs)
ATimestamp operator- (const ATimestamp &lhs, const ATimestamp &rhs)
AYear operator+ (const AYear &lhs, const AYear &rhs)
AYear operator- (const AYear &lhs, const AYear &rhs)
std::ostream & operator<< (std::ostream &out, const Entity &obj) throw ()
std::istream & operator>> (std::istream &in, Entity &obj) throw ()
static bool isRegionNegator (const char ch)
static const unsigned int ID_MP3 (0xE0FF)
static bool isOptionChar (const char ch)
static const unsigned int ID_PKZIP_LOCALHDR (0x04034b50)
static const unsigned int ID_PKZIP_END_CDR (0x06054B50)
static const unsigned int ID_PKZIP_CENTRALFILEHDR (0x02014b50)
unsigned int getFileOffsetInArchive (std::istream &stream, char *buffer, const char *file, unsigned int lenFile)
unsigned int get2BytesLSB (const char *pAddr)
unsigned int get2BytesMSB (const char *pAddr)
unsigned long get4BytesLSB (const char *pAddr)
unsigned long get4BytesMSB (const char *pAddr)
bool _XDSfileIsValid (const std::string &files, const char *pFile)
void _XDSaddNode (std::string &list, char prefix, const std::string &node)

Variables

const char MULTIMATCHOPT = '*'
const char MULTIMATCHMAND = '+'
const char MULTIMATCH1 = '?'
const char BOUNDBEG = '{'
const char BOUNDEND = '}'
const char SINGLEMATCH = '.'
const char LINEBEGIN = '^'
const char LINEEND = '$'
const char ESCAPE = '\\'
const char GROUPBEGIN = '('
const char GROUPEND = ')'
const char ALTERNATIVE = '|'
const char REGIONBEGIN = '['
const char REGIONEND = ']'
const char RANGE = '-'
const char NEGREGION1 = '^'
const char NEGREGION2 = '!'
const char REGIONCLASS = ':'
const char WORD = 'w'
const char NOTWORD = 'W'
const char WORDBORDER = 'b'
const char NOTWORDBORDER = 'B'
const char WORDBEGIN = '<'
const char WORDEND = '>'
const char MULTIMATCH = '*'
const char REGIONCOLLATE = '.'
static const char ID_PDF [] = "%PDF"
static const char ID_RTF [] = "{\\rtf"
static const char ID_ABIWORD [] = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE abiword PUBLIC \"-//ABISOURCE//DTD AWML"
static const char ID_ID3 [] = "ID3"
static const char ID_GIF87 [] = "GIF87a"
static const char ID_GIF89 [] = "GIF89a"
static const char ID_OGG [] = "OggS"
static const char ID_JPEG [] = "\xFF\xD8\xFF\xE0\x00\x10JFIF"
static const char ID_PNG [] = "\x89PNG\x0D\x0A\x1A\x0A"
static const char ID_HTML [] = "<!DOCTYPE HTML"
static const char ID_MSOFFICE [] = "\xD0\xCF\x11\xE0\xA1\xB1\x1A\xE1"
static const char ID_STAROFFICE [] = "SfxDocumentInfo"


Detailed Description

This namespace holds plattform independend classes of common use.


Typedef Documentation

Declare ExtDirectorySearch as shortcut.

Declare ExtPathDirectorySearch as shortcut.

Declare ExtRemoteDirSearch as shortcut.

typedef struct File YGP::File

Declare also a File, to not have to use struct File.

typedef int(* YGP::PARSECALLBACK)(const char *, unsigned int)

Prototype of callback-function (called if an object is found).

The return-value specifies how the parsing should be continued: 0 ..... Parsing (and callback OK) > 0 ... Error while parsing; parsing can be continued (in sequences, ...) < 0 ... Error while parsing; abort parsing (unrecoverable error) If possible use the error-values in the error-enum

Class representing a file on a remote server with simple management-functions.

This class offers the same functionality as its parent although the file is (or can be) actually stored on a remote computer.

This class is not really (very) useful by itself but designed to be used by a RemoteDirSearch-object.

typedef extStream<std::ifstream> YGP::Xifstream

Declare Xifstream as shortcut.

typedef extStream<std::istream> YGP::Xistream

Declare Xistream as shortcut.


Function Documentation

void YGP::_XDSaddNode ( std::string &  list,
char  prefix,
const std::string &  node 
)

Prefixes a list with another list of nodes.

Every subnode of the node is prefixed with the specified prefix-character

Parameters:
list List to change
prefix Leading character
node Node to check
Remarks:
The node is added to the beginning of the list

bool YGP::_XDSfileIsValid ( const std::string &  files,
const char *  pFile 
)

Checks the validity of the filename.

Parameters:
files Nodes of files to in/exclude
pFile Pointer to filename
Returns:
bool True: Name valid
Precondition:
pFile is ASCIIZ-string
Remarks:
If the list starts with an x-node, a leading i*-node is assumed

unsigned int YGP::getFileOffsetInArchive ( std::istream &  stream,
char *  buffer,
const char *  file,
unsigned int  lenFile 
)

Checks if the passed stream is a ZIP-archive having the passed file inside.

Parameters:
stream Stream from where to read more characters
buffer Buffer to inspect
file Name of file which must be inside the ZIP-file
length Lenght of file-name
Returns:
unsigned int Offset of file in archive

static bool YGP::isOptionChar ( const char  ch  )  [inline, static]

Checks char if it starts an option.

Parameters:
ch Character to check
Returns:
bool Result (true: char starts option)

ANumeric YGP::operator* ( const ANumeric &  lhs,
const ANumeric &  rhs 
)

Multiplies rhs and lhs and returns the result.

If one object is defined, the other is treated as "1"; so only if both objects are undefined, the result is undefined.

Parameters:
lhs Left-hand-side of mulitplication
rhs Right-hand-side of mulitplication
Returns:
ANumeric Result of mulitplication

AYear YGP::operator+ ( const AYear &  lhs,
const AYear &  rhs 
)

Adds two year-values and returns the result.

An undefined year is treated as "0.0.0"; the result is (remains) undefined if both objects are undefined. Overflows (of day or month) are corrected.

Parameters:
lhs Left-hand-side of addition
rhs Right-hand-side of addition
Returns:
AYear Result of additon

ATimestamp YGP::operator+ ( const ATimestamp &  lhs,
const ATimestamp &  rhs 
)

Returns the addition of two timestamp-values.

An undefined time is treated as "0.0.0 0:00:00"; if both objects are undefined, the result is undefined. Overflows are corrected.

Parameters:
lhs Left-hand-side of addition
rhs Right-hand-side of addition
Returns:
ATimestamp Result of additon

ATime YGP::operator+ ( const ATime &  lhs,
const ATime &  rhs 
)

Returns the addition of two time-values.

An undefined time is treated as "0:00:00"; if both objects are undefined, the result is undefined. Overflows of seconds or minutes are corrected, overflows of the hour undefines the object.

Parameters:
lhs Left-hand-side of addition
rhs Right-hand-side of addition
Returns:
ATime Result of additon

ANumeric YGP::operator+ ( const ANumeric &  lhs,
const ANumeric &  rhs 
)

Adds lhs and rhs and returns the result.

If one object is defined, the other object is treated as "0"; so only if both objects are undefined, the result is undefined.

Parameters:
lhs Left-hand-side of addition
rhs Right-hand-side of addition
Returns:
ANumeric Result of additon Note : Undefined values are ignored

ADate YGP::operator+ ( const ADate &  lhs,
const ADate &  rhs 
)

Adds two date-values and returns the result.

An undefined date is treated as "0.0.0"; the result is (remains) undefined if both objects are undefined. Overflows (of day or month) are corrected.

Parameters:
lhs Left-hand-side of addition
rhs Right-hand-side of addition
Returns:
ADate Result of additon

AYear YGP::operator- ( const AYear &  lhs,
const AYear &  rhs 
)

Substracts two year-values and returns the result.

An undefined year is treated as "0.0.0"; the result is (remains) undefined if both objects are undefined. Overflows (of day or month) are corrected.

Parameters:
lhs Left-hand-side of substraction
rhs Right-hand-side of substraction
Returns:
AYear Result of substraction

ATimestamp YGP::operator- ( const ATimestamp &  lhs,
const ATimestamp &  rhs 
)

Returns the substraction of two timestamp-values.

An undefined time is treated as "0.0.0 0:00:00"; if both objects are undefined, the result is undefined. Underflows are corrected.

Parameters:
lhs Left-hand-side of substraction
rhs Right-hand-side of substraction
Returns:
ATimestamp Result of substraction

ATime YGP::operator- ( const ATime &  lhs,
const ATime &  rhs 
)

Returns the substraction of two time-values.

An undefined time is treated as "0:00:00"; if both objects are undefined, the result is undefined. Underflows of seconds or minutes are corrected, underflows of the hour undefines the object.

Parameters:
lhs Left-hand-side of substraction
rhs Right-hand-side of substraction
Returns:
ATime Result of substraction

ANumeric YGP::operator- ( const ANumeric &  lhs,
const ANumeric &  rhs 
)

Substracts rhs from lhs and returns the result.

If one object is defined, the other is is treated as "0"; so only if both objects are undefined, the result is undefined.

Parameters:
lhs Left-hand-side of substraction
rhs Right-hand-side of substraction
Returns:
ANumeric Result of substraction Note : Undefined values are ignored

ADate YGP::operator- ( const ADate &  lhs,
const ADate &  rhs 
)

Substracts two date-values and returns the result.

An undefined date is treated as "0.0.0"; the result is (remains) undefined if both objects are undefined. Overflows (of day or month) are corrected.

Parameters:
lhs Left-hand-side of substraction
rhs Right-hand-side of substraction
Returns:
ADate Result of substraction

ANumeric YGP::operator/ ( const ANumeric &  lhs,
const ANumeric &  rhs 
)

Divides this by another number-object.

If only one object is defined, the other is treated as "1"; so only if both objects are undefined, the result is undefined.

Parameters:
lhs Left-hand-side of division
rhs Right-hand-side of division
Returns:
ANumeric Result of division

std::ostream& YGP::operator<< ( std::ostream &  out,
const Entity &  obj 
) throw ()

Writes the attributes to a stream.

Parameters:
out Stream to write to
obj Object to write
Returns:
std::ostream& The stream
Exceptions:
Anything that operator<< of the attributes might throw

std::istream& YGP::operator>> ( std::istream &  in,
Entity &  obj 
) throw ()

Reads the attributes from a stream.

Parameters:
in Stream to read from
obj Object to read
Returns:
std::ostream& The stream
Exceptions:
Anything that operator>> of the attributes might throw


YGP Version 0.9.31 - Generated on Wed Nov 18 11:25:27 2009 by doxygen 1.5.8