cxxtools Namespace Reference

Namespaces

namespace  bin
namespace  dl
namespace  http
namespace  json
namespace  net
namespace  posix
namespace  unit
namespace  xml
namespace  xmlrpc

Classes

class  Application
 The Application class provides an event loop for console applications without a GUI. More...
class  Arg
 Read and extract commandline parameters from argc/argv. More...
class  Arg< bool >
 specialization for bool. More...
class  ArgIn
 Helper class for redirecting input to stdin or file using command line switch. More...
class  ArgOut
 Helper class for redirecting output to stdout or file using command line switch. More...
class  Base64Codec
class  Base64ostream
 Base64ostream is a base64-encoder. More...
class  Base64istream
 Base64istream is a base64-decoder. More...
class  Cache
 Implements a container for caching elements. More...
class  Cgi
 Class for easy extraction of CGI-parameters. More...
class  Char
 A lightweight Character class (32 bits). More...
class  CharMapCodec
 The codec translates between one byte char and unicode char using a translation map. More...
class  Clock
 Measures time intervals. More...
class  IComposer
class  Composer
class  Condition
 This class is used to control concurrent access. More...
class  Connectable
 Connection management for signal and slot objectsThis class implements connection management for signal and slot objects. More...
class  ConnectionData
class  Connection
 Represents a connection between a Signal/Delegate and a slot. More...
class  ConversionError
struct  Convert
struct  NumberFormat
struct  DecimalFormat
struct  OctalFormat
struct  HexFormat
struct  BinaryFormat
struct  FloatFormat
class  CsvOObject
 Wrapper object to easily print serializable objects as csv to a output stream. More...
class  CsvIOObject
class  CsvDeserializer
class  CsvFormatter
class  CsvParser
class  CsvSerializer
class  InvalidDate
class  Date
 Date expressed in year, month, and day More...
class  DateTime
 Combined Date and Time value. More...
class  IDecomposer
class  Decomposer
class  DelegateBase
class  Deserializer
 convert format to SerializationInfo More...
class  DirectoryIterator
 Iterates over entries of a directory. More...
class  Directory
 Represents a single directory in the file-system. More...
class  EnvSubstSyntaxError
class  EnvSubst
 This class parses a character data and replaces environment variables. More...
class  Event
 Base class for all event types. More...
class  BasicEvent
class  EventLoopBase
 Thread-safe event loop supporting I/O multiplexing and Timers. More...
class  EventLoop
 Thread-safe event loop supporting I/O multiplexing and Timers. More...
class  EventSink
class  EventSource
 Sends Events to receivers in other threads. More...
struct  InitLocale
class  Fdstreambuf
class  Fdiostream
class  File
 Provides common operations on files. More...
class  FileDevice
class  FileInfo
 Provides information about a node in the file-system. More...
class  Formatter
class  Hdstreambuf
class  Hdostream
 hexdumper as a outputstream. More...
class  HexDump
 Helper object for dumping content to output stream without creating another output stream. More...
class  IConverter
 IConverter is a simple wrapper around cxxtools::iconvstream. More...
class  iconv_error
class  iconvstreambuf
 std::streambuf-Interface for iconv(3) and related. More...
class  iconvstream
 std::ostream-Interface for iconv(3) and related. More...
class  iconvwrap
 Wraps iconv. More...
class  IniFile
class  IniParser
 Parser for files in ini-format. More...
class  IODevice
 Endpoint for I/O operations. More...
class  IOError
class  IOTimeout
class  AccessFailed
class  PermissionDenied
class  DeviceNotFound
class  FileNotFound
class  DirectoryNotFound
 A directory could not be found at a given path. More...
class  IOPending
class  DeviceClosed
class  BasicIStream
 An istream with peeking capability. More...
class  BasicOStream
 An ostream with peeking capability. More...
class  BasicIOStream
 An iostream with peeking capability. More...
class  IStream
class  OStream
class  IOStream
class  Iso8859_10Codec
class  Iso8859_11Codec
class  Iso8859_13Codec
class  Iso8859_14Codec
class  Iso8859_15Codec
class  Iso8859_16Codec
class  Iso8859_1Codec
class  Iso8859_2Codec
class  Iso8859_3Codec
class  Iso8859_4Codec
class  Iso8859_5Codec
class  Iso8859_6Codec
class  Iso8859_7Codec
class  Iso8859_8Codec
class  Iso8859_9Codec
class  JsonOObject
 Wrapper object to easily print serializable objects as json to a output stream. More...
class  JsonIOObject
 Wrapper object to easily read objects as json from a input stream. More...
class  JsonDeserializer
 This class converts json format to cxxtools::SerializationInfo. More...
class  JsonFormatter
class  JsonParserError
class  JsonParser
class  JsonSerializer
 Here is a small example to use this class. More...
class  Library
 Shared library loader. More...
class  Symbol
 Symbol resolved from a shared library. More...
class  BasicLimitStreambuf
 The class implements a stream buffer, which reads or writes from another streambuffer but limits the number of characters. More...
class  BasicLimitIStream
 The class implements a input stream, which limits the number of characters to read. More...
class  BasicLimitOStream
 The class implements a output stream, which limits the number of characters to write. More...
class  BasicLimitIOStream
 This class implements a input/output stream, which limits the number of characters to read and write. More...
class  Logger
class  LogConfiguration
class  LogManager
class  LogMessage
class  LogTracer
class  LruCache
 Implements a lru cache. More...
class  md5_hash
class  Md5streambuf
class  Md5stream
 This is a easy and safe interface to MD5-calculation. More...
class  MimeHeader
 The class implements a base class for mime entities, with headers as specified in rfc2045. More...
class  MimeEntity
 A MimeEntity is a message with headers and a body. More...
class  MimeMultipart
 A MimeMultipart is a mime entity with multiple embedded entities. More...
class  multifstreambuf
 Read multiple files as one stream. More...
class  multi_ifstream
class  Mutex
 Mutual exclusion device. More...
class  MutexLock
 MutexLock class for Mutex. More...
class  RecursiveMutex
 Recursive mutual exclusion device. More...
class  RecursiveLock
 Lock class for recursive mutexes. More...
class  ReadWriteMutex
 Synchronisation device similar to a POSIX rwlock. More...
class  ReadLock
class  WriteLock
class  SpinMutex
 Spinmutex class. More...
class  SpinLock
class  NonCopyable
class  Pipe
class  DefaultCreator
 This class is a factory for objects wich are default constructable. More...
class  Pool
 A Pool is a container for pooled objects. More...
class  PropertiesOObject
 Wrapper object to easily print serializable objects as properties to a output stream. More...
class  PropertiesIOObject
 Wrapper object to easily read properties from a input stream and convert them to serializable objects. More...
class  PropertiesDeserializer
class  PropertiesFile
class  PropertiesParser
class  PropertiesParserError
class  PropertiesSerializer
class  QueryParams
 QueryParams represents parameters from a HTML-Form. More...
class  Queue
 This class implements a thread safe queue. More...
class  QuotedPrintableCodec
class  QuotedPrintable_ostream
 The QuotedPrintable_ostream implements a encoder for Quoted-printable encoding. More...
class  SimpleRefCounted
class  AtomicRefCounted
class  RegexDestroyPolicy< regex_t >
class  Regex
 regex(3)-wrapper. More...
class  RegexSMatch
 collects matches in a regex More...
class  RemoteClient
 Base class for rpc client. More...
class  RemoteException
class  IRemoteProcedure
class  RemoteProcedureBase
 Base class for Remote procedure class. More...
class  IRemoteResult
class  RemoteResult
class  ScopedIncrement
class  ScopedIncrement< atomic_t >
class  Selectable
class  SelectorBase
 Reports activity on a set of devices. More...
class  Selector
class  Semaphore
class  SerializationError
 Error during serialization of a type. More...
class  SerializationMemberNotFound
class  SerializationInfo
 Represents arbitrary types during serialization. More...
class  ServiceProcedure
class  ServiceRegistry
class  SettingsError
class  Settings
class  SignalBase
struct  CompareEventTypeInfo
class  Signal< const cxxtools::Event & >
class  Singleton
 Singleton class template. More...
class  Slot
class  RefLinked
 Reference linking. More...
class  InternalRefCounted
 Intrusive reference counting. More...
class  ExternalRefCounted
 Non-intrusive reference counting. More...
class  ExternalAtomicRefCounted
class  DefaultDestroyPolicy
 old name for DeletePolicy for compatibility. More...
class  DeletePolicy
 deleter policy for smart pointer. More...
class  FreeDestroyPolicy
class  ArrayDestroyPolicy
class  SmartPtr
 Policy-based smart-pointer-class. More...
class  SourceInfo
 Source code info classThis class is used to store information about a location in the source code. More...
class  BasicStreamBuffer
class  StreamBuffer
 A stream buffer for IODevices with linear buffer area. More...
class  BasicStreamcounterBuf
class  BasicStreamcounter
class  StringStreamBuffer
class  SystemError
 Exception class indicating a system error. More...
class  OpenLibraryFailed
 Thrown, when a shared library could not be loaded. More...
class  SymbolNotFound
 Thrown, when a symbol is not found in a library. More...
class  SslError
class  Teestreambuf
class  Tee
class  BasicTextBuffer
 Converts character sequences with different encodings. More...
class  TextBuffer
 Buffers the conversion of 8-bit character sequences to unicode. More...
class  TextCodec
 Generic TextCodec class/facet which may be subclassed by specific Codec classes. More...
class  BasicTextIStream
 Converts character sequences using a Codec. More...
class  BasicTextOStream
 Converts character sequences using a Codec. More...
class  BasicTextStream
 Converts character sequences using a Codec. More...
class  TextIStream
 Text Input Stream for Character conversion. More...
class  TextOStream
 Text Output Stream for Character conversion. More...
class  TextStream
 Text Stream for Character conversion. More...
class  Thread
 Platform independent threads. More...
class  AttachedThread
 Platform independent joinable thread. More...
class  DetachedThread
 Platform independent detached thread. More...
class  ThreadPool
class  InvalidTime
class  Time
 Time expressed in hours, minutes, seconds and milliseconds More...
class  Timer
 Notifies clients in constant intervals. More...
class  Timespan
 Represents time spans up to microsecond resolution. More...
class  WeakTimespan
 A WeakTimespan extends a Timespan with a implicit conversion to and from number. More...
class  WeakTimespan< 1 >
 A WeakTimespan<1> specializes a WeakTimespan for microseconds. More...
struct  TypeTraitsBase
struct  TypeTraits
 Type-traits for for non-const value types. More...
struct  TypeTraits< const T >
 Type-traits for for const value types. More...
struct  TypeTraits< T & >
 Type-traits for for non-const reference types. More...
struct  TypeTraits< const T & >
 Type-traits for for const reference types. More...
struct  TypeTraits< T * >
 Type-traits for for non-const pointer types. More...
struct  TypeTraits< const T * >
 Type-traits for for const pointer types. More...
struct  TypeTraits< T[N]>
 Type-traits for for fixed-size array types. More...
struct  TypeTraits< void >
 Type-traits for for void. More...
struct  IntTraits
struct  IntTraits< signed char >
struct  IntTraits< unsigned char >
struct  IntTraits< short >
struct  IntTraits< unsigned short >
struct  IntTraits< int >
struct  IntTraits< unsigned int >
struct  IntTraits< long >
struct  IntTraits< unsigned long >
class  Utf8OString
class  Utf8IOString
class  Utf8Codec
 This Codec class is able to convert from UTF-8 to UTF-32 and from UTF-32 to UTF-8. More...
class  Uuencode_streambuf
class  UuencodeOstream
 uuencoder. More...
struct  Void

Typedefs

typedef std::sig_atomic_t atomic_t
typedef Directory Dir
 for compatibility with old implementation
typedef BasicLimitStreambuf< char > LimitStreambuf
typedef BasicLimitIStream< char > LimitIStream
typedef BasicLimitOStream< char > LimitOStream
typedef BasicLimitIOStream< char > LimitIOStream
typedef SimpleRefCounted RefCounted
typedef BasicStreamcounter
< char, std::char_traits< char > > 
Streamcounter
typedef std::basic_string
< cxxtools::Char
String
 Unicode capable strings.
typedef
std::basic_stringstream
< cxxtools::Char
StringStream
typedef
std::basic_ostringstream
< cxxtools::Char
OStringStream
typedef
std::basic_istringstream
< cxxtools::Char
IStringStream
typedef WeakTimespan< 1 > Microseconds
 The typedefs makes specifying a timespan easy and readable.
typedef WeakTimespan< int64_t(1000)> Milliseconds
typedef WeakTimespan< int64_t(1000)*1000 > Seconds
typedef WeakTimespan< int64_t(1000)*1000 *60 > Minutes
typedef WeakTimespan< int64_t(1000)*1000 *60 *60 > Hours
typedef WeakTimespan< int64_t(1000)*1000 *60 *60 *24 > Days

Enumerations

enum  IOS_OpenMode {
  IOS_Sync = 0, IOS_Async = 1L << 0, IOS_Read = 1L << 1, IOS_Write = 1L << 2,
  IOS_AtEnd = 1L << 3, IOS_Append = 1L << 4, IOS_Trunc = 1L << 5, IOS_OpenModeEnd = 1L << 16
}

Functions

template<typename T >
std::ostream & operator<< (std::ostream &out, const ArgBaseT< T > &arg)
 Output operator for a argument.
atomic_t atomicGet (volatile atomic_t &val)
 Atomically get a value.
void atomicSet (volatile atomic_t &val, atomic_t n)
 Atomically set a value.
atomic_t atomicIncrement (volatile atomic_t &val)
 Increases a value by one as an atomic operation.
atomic_t atomicDecrement (volatile atomic_t &val)
 Decreases a value by one as an atomic operation.
atomic_t atomicExchangeAdd (volatile atomic_t &val, atomic_t add)
 Performs atomic addition of two values.
atomic_t atomicCompareExchange (volatile atomic_t &val, atomic_t exch, atomic_t comp)
 Performs an atomic compare-and-exchange operation.
void * atomicCompareExchange (void *volatile &ptr, void *exch, void *comp)
 Performs an atomic compare-and-exchange operation.
atomic_t atomicExchange (volatile atomic_t &val, atomic_t exch)
 Performs an atomic exchange operation.
void * atomicExchange (void *volatile &dest, void *exch)
 Performs an atomic exchange operation.
template<typename T >
internal T reverse (T value)
 Returns the value in reversed byte order.
bool isBigEndian ()
 Returns true, if machine is big-endian (high byte first).
bool isLittleEndian ()
 Returns true, if machine is little-endian (low byte first).
template<typename T >
hostToLe (T value)
 Converts a native value in little endian.
template<typename T >
leToHost (T value)
 Converts a little endian value to native.
template<typename T >
hostToBe (T value)
 Converts a native value in big endian.
template<typename T >
beToHost (T value)
 Converts a big endian value to native.
internal std::ostream & operator<< (std::ostream &out, Char ch)
std::ctype_base::mask ctypeMask (const Char &ch)
int isalpha (const Char &ch)
int isalnum (const Char &ch)
int ispunct (const Char &ch)
int iscntrl (const Char &ch)
int isdigit (const Char &ch)
int isxdigit (const Char &ch)
int isgraph (const Char &ch)
int islower (const Char &ch)
int isupper (const Char &ch)
int isprint (const Char &ch)
int isspace (const Char &ch)
Char tolower (const Char &ch)
Char toupper (const Char &ch)
void convert (String &s, const String &str)
void convert (String &s, const std::string &value)
void convert (String &s, bool value)
void convert (String &s, char value)
void convert (String &s, wchar_t value)
void convert (String &s, Char value)
void convert (String &s, unsigned char value)
void convert (String &s, signed char value)
void convert (String &s, short value)
void convert (String &s, unsigned short value)
void convert (String &s, int value)
void convert (String &s, unsigned int value)
void convert (String &s, long value)
void convert (String &s, unsigned long value)
void convert (String &s, float value)
void convert (String &s, double value)
void convert (String &s, long double value)
template<typename T >
void convert (String &s, const T &value)
void convert (bool &n, const String &str)
void convert (char &n, const String &str)
void convert (wchar_t &n, const String &str)
void convert (Char &n, const String &str)
void convert (unsigned char &n, const String &str)
void convert (signed char &n, const String &str)
void convert (short &n, const String &str)
void convert (unsigned short &n, const String &str)
void convert (int &n, const String &str)
void convert (unsigned int &n, const String &str)
void convert (long &n, const String &str)
void convert (unsigned long &n, const String &str)
void convert (float &n, const String &str)
void convert (double &n, const String &str)
void convert (long double &n, const String &str)
template<typename T >
void convert (T &t, const String &str)
void convert (std::string &s, const std::string &str)
void convert (std::string &s, const String &str)
void convert (std::string &s, bool value)
void convert (std::string &s, char value)
void convert (std::string &s, signed char value)
void convert (std::string &s, unsigned char value)
void convert (std::string &s, short value)
void convert (std::string &s, unsigned short value)
void convert (std::string &s, int value)
void convert (std::string &s, unsigned int value)
void convert (std::string &s, long value)
void convert (std::string &s, unsigned long value)
void convert (std::string &s, float value)
void convert (std::string &s, double value)
void convert (std::string &s, long double value)
template<typename T >
void convert (std::string &s, const T &value)
void convert (bool &n, const std::string &str)
void convert (char &n, const std::string &str)
void convert (signed char &n, const std::string &str)
void convert (unsigned char &n, const std::string &str)
void convert (short &n, const std::string &str)
void convert (unsigned short &n, const std::string &str)
void convert (int &n, const std::string &str)
void convert (unsigned int &n, const std::string &str)
void convert (long &n, const std::string &str)
void convert (unsigned long &n, const std::string &str)
void convert (float &n, const std::string &str)
void convert (double &n, const std::string &str)
void convert (long double &n, const std::string &str)
template<typename T >
void convert (T &t, const std::string &str)
void convert (bool &n, const char *str)
void convert (char &n, const char *str)
void convert (signed char &n, const char *str)
void convert (unsigned char &n, const char *str)
void convert (short &n, const char *str)
void convert (unsigned short &n, const char *str)
void convert (int &n, const char *str)
void convert (unsigned int &n, const char *str)
void convert (long &n, const char *str)
void convert (unsigned long &n, const char *str)
void convert (float &n, const char *str)
void convert (double &n, const char *str)
void convert (long double &n, const char *str)
template<typename T , typename S >
void convert (T &to, const S &from)
template<typename T , typename S >
convert (const S &from)
template<typename OutIterT , typename T , typename FormatT >
OutIterT putInt (OutIterT it, T i, const FormatT &fmt)
 Formats an integer in a given format format.
template<typename OutIterT , typename T >
OutIterT putInt (OutIterT it, T i)
 Formats an integer in a decimal format.
template<typename OutIterT , typename T , typename FormatT >
OutIterT putFloat (OutIterT it, T d, const FormatT &fmt, int precision)
 Formats a floating point value in a given format.
template<typename OutIterT , typename T >
OutIterT putFloat (OutIterT it, T d)
 Formats a floating point value in default format.
template<typename InIterT , typename T , typename FormatT >
InIterT getInt (InIterT it, InIterT end, bool &ok, T &n, const FormatT &fmt)
 Parses an integer value in a given format.
template<typename InIterT , typename T >
InIterT getInt (InIterT it, InIterT end, bool &ok, T &n)
 Parses an integer value in decimal format.
template<typename InIterT , typename T , typename FormatT >
InIterT getFloat (InIterT it, InIterT end, bool &ok, T &n, const FormatT &fmt)
 Parses a floating point value in a given format.
template<typename InIterT , typename T >
InIterT getFloat (InIterT it, InIterT end, bool &ok, T &n)
 Parses a floating point value.
unsigned char formatAbs (char i, bool &isNeg)
unsigned char formatAbs (unsigned char i, bool &isNeg)
unsigned short formatAbs (short i, bool &isNeg)
unsigned short formatAbs (unsigned short i, bool &isNeg)
unsigned int formatAbs (int i, bool &isNeg)
unsigned int formatAbs (unsigned int i, bool &isNeg)
unsigned long formatAbs (long i, bool &isNeg)
unsigned long formatAbs (unsigned long i, bool &isNeg)
template<typename CharT , typename T , typename FormatT >
CharT * formatInt (CharT *buf, std::size_t buflen, T si, const FormatT &fmt)
 Formats an integer in a given format.
template<typename CharT , typename T >
CharT * formatInt (CharT *buf, std::size_t buflen, T i, const BinaryFormat< CharT > &fmt)
 Formats an integer in binary format.
template<typename InIterT , typename FormatT >
InIterT getSign (InIterT it, InIterT end, bool &pos, const FormatT &fmt)
template<typename CharType , typename ObjectType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &out, const CsvOObject< ObjectType > &object)
 The output operator for CsvOObject. It does the actual work.
template<typename ObjectType >
CsvOObject< ObjectType > Csv (const ObjectType &object)
 Function, which creates a CsvOObject.
template<typename CharType , typename ObjectType >
std::basic_istream< CharType > & operator>> (std::basic_istream< CharType > &in, CsvIOObject< ObjectType > object)
 The input operator for CsvIOObject. It does the actual work.
template<typename ObjectType >
CsvIOObject< ObjectType > Csv (ObjectType &object)
void greg2jul (unsigned &jd, int y, int m, int d)
void jul2greg (unsigned jd, int &y, int &m, int &d)
void operator>>= (const SerializationInfo &si, Date &date)
void operator<<= (SerializationInfo &si, const Date &date)
Date operator+ (const Date &d, int days)
Date operator+ (int days, const Date &d)
Days operator- (const Date &a, const Date &b)
void operator>>= (const SerializationInfo &si, DateTime &dt)
void operator<<= (SerializationInfo &si, const DateTime &dt)
bool operator< (const Directory &a, const Directory &b)
bool operator== (const Directory &a, const Directory &b)
bool operator!= (const Directory &a, const Directory &b)
std::string envSubst (const std::string &str)
 Function uses the class cxxtools::EnvSubst to substitute environment variables in the passed string.
bool operator< (const File &a, const File &b)
bool operator== (const File &a, const File &b)
bool operator!= (const File &a, const File &b)
bool operator< (const FileInfo &a, const FileInfo &b)
bool operator== (const FileInfo &a, const FileInfo &b)
bool operator!= (const FileInfo &a, const FileInfo &b)
template<typename T >
void hexDump (std::ostream &out, const T &t)
template<typename T >
std::string hexDump (const T &t)
std::string hexDump (const char *p, unsigned n)
std::ostream & operator<< (std::ostream &out, const HexDump &hd)
 Outputs data to output stream as a hex dump.
template<typename Algo >
void hmac_pad_key (Algo &key_hash, const std::string &key, std::string &o_key_pad, std::string &i_key_pad)
template<typename Algo , typename data_type >
std::string hmac (const std::string &key, const data_type &msg)
template<typename Algo , typename iterator_type >
std::string hmac (const std::string &key, iterator_type from, iterator_type to)
std::istream & operator>> (std::istream &in, IniFile &ini)
 Reads ini file from an output stream.
std::ostream & operator<< (std::ostream &out, const IniFile &ini)
 Outputs ini file to an output stream.
IOS_OpenMode operator& (IOS_OpenMode a, IOS_OpenMode b)
IOS_OpenMode operator| (IOS_OpenMode a, IOS_OpenMode b)
IOS_OpenMode operator^ (IOS_OpenMode a, IOS_OpenMode b)
IOS_OpenModeoperator|= (IOS_OpenMode &a, IOS_OpenMode b)
IOS_OpenModeoperator&= (IOS_OpenMode &a, IOS_OpenMode b)
IOS_OpenModeoperator^= (IOS_OpenMode &a, IOS_OpenMode b)
IOS_OpenMode operator~ (IOS_OpenMode a)
template<typename inputIterator , typename separatorType , typename characterType >
void join (inputIterator b, inputIterator e, const separatorType &sep, std::basic_ostream< characterType > &out)
 Joins a list of tokens into a output stream using a delimiter.
template<typename inputIterator , typename separatorType >
std::string join (inputIterator b, inputIterator e, const separatorType &sep)
 Joins a list of tokens into a std::string using a delimiter.
template<typename CharType , typename ObjectType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &out, const JsonOObject< ObjectType > &object)
 The output operator for JsonOObject. It does the actual work.
template<typename ObjectType >
JsonOObject< ObjectType > Json (const ObjectType &object, bool beautify=false)
 Function, which creates a JsonOObject.
template<typename CharType , typename ObjectType >
std::basic_istream< CharType > & operator>> (std::basic_istream< CharType > &in, JsonIOObject< ObjectType > object)
 The input operator for JsonIOObject. It does the actual work.
template<typename ObjectType >
JsonIOObject< ObjectType > Json (ObjectType &object)
 Creates a JsonIObject with a reference to a deserializable object.
void operator>>= (const SerializationInfo &si, LogConfiguration &logConfiguration)
void operator<<= (SerializationInfo &si, const LogConfiguration &logConfiguration)
template<typename iterator_type >
std::string md5 (iterator_type from, iterator_type to)
template<typename data_type >
std::string md5 (const data_type &data)
void membar_rw ()
void membar_write ()
void membar_read ()
MimeEntityoperator<< (MimeEntity &me, const std::string &str)
 operator to add a std::string to a mime entity body.
MimeEntityoperator<< (MimeEntity &me, const char *str)
 operator to add a const char* to a mime entity body.
std::ostream & operator<< (std::ostream &out, const MimeHeader &mimeHeader)
std::ostream & operator<< (std::ostream &out, const MimeEntity &mimeEntity)
std::ostream & operator<< (std::ostream &out, const MimeMultipart &mime)
template<typename CharType , typename ObjectType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &out, const PropertiesOObject< ObjectType > &object)
 The output operator for PropertiesOObject. It does the actual work.
template<typename CharType , typename ObjectType >
std::basic_istream< CharType > & operator>> (std::basic_istream< CharType > &in, PropertiesIOObject< ObjectType > object)
 The input operator for PropertiesIOObject. It does the actual work.
template<typename ObjectType >
PropertiesIOObject< ObjectType > Properties (ObjectType &object, const std::string &name=std::string())
std::ostream & operator<< (std::ostream &out, const QueryParams &p)
 output QueryParams in url-syntax
void operator>>= (const SerializationInfo &si, SerializationInfo &ssi)
void operator<<= (SerializationInfo &si, const SerializationInfo &ssi)
void operator>>= (const SerializationInfo &si, bool &n)
void operator<<= (SerializationInfo &si, bool n)
void operator>>= (const SerializationInfo &si, signed char &n)
void operator<<= (SerializationInfo &si, signed char n)
void operator>>= (const SerializationInfo &si, unsigned char &n)
void operator<<= (SerializationInfo &si, unsigned char n)
void operator>>= (const SerializationInfo &si, char &n)
void operator<<= (SerializationInfo &si, char n)
void operator>>= (const SerializationInfo &si, short &n)
void operator<<= (SerializationInfo &si, short n)
void operator>>= (const SerializationInfo &si, unsigned short &n)
void operator<<= (SerializationInfo &si, unsigned short n)
void operator>>= (const SerializationInfo &si, int &n)
void operator<<= (SerializationInfo &si, int n)
void operator>>= (const SerializationInfo &si, unsigned int &n)
void operator<<= (SerializationInfo &si, unsigned int n)
void operator>>= (const SerializationInfo &si, long &n)
void operator<<= (SerializationInfo &si, long n)
void operator>>= (const SerializationInfo &si, unsigned long &n)
void operator<<= (SerializationInfo &si, unsigned long n)
void operator>>= (const SerializationInfo &si, float &n)
void operator<<= (SerializationInfo &si, float n)
void operator>>= (const SerializationInfo &si, double &n)
void operator<<= (SerializationInfo &si, double n)
void operator>>= (const SerializationInfo &si, std::string &n)
void operator<<= (SerializationInfo &si, const std::string &n)
void operator<<= (SerializationInfo &si, const char *n)
void operator>>= (const SerializationInfo &si, String &n)
void operator<<= (SerializationInfo &si, const String &n)
void operator>>= (const SerializationInfo &si, Char &n)
void operator<<= (SerializationInfo &si, const Char &n)
template<typename T , typename A >
void operator>>= (const SerializationInfo &si, std::vector< T, A > &vec)
template<typename T , typename A >
void operator<<= (SerializationInfo &si, const std::vector< T, A > &vec)
template<typename T , typename A >
void operator>>= (const SerializationInfo &si, std::list< T, A > &list)
template<typename T , typename A >
void operator<<= (SerializationInfo &si, const std::list< T, A > &list)
template<typename T , typename A >
void operator>>= (const SerializationInfo &si, std::deque< T, A > &deque)
template<typename T , typename A >
void operator<<= (SerializationInfo &si, const std::deque< T, A > &deque)
template<typename T , typename C , typename A >
void operator>>= (const SerializationInfo &si, std::set< T, C, A > &set)
template<typename T , typename C , typename A >
void operator<<= (SerializationInfo &si, const std::set< T, C, A > &set)
template<typename T , typename C , typename A >
void operator>>= (const SerializationInfo &si, std::multiset< T, C, A > &multiset)
template<typename T , typename C , typename A >
void operator<<= (SerializationInfo &si, const std::multiset< T, C, A > &multiset)
template<typename A , typename B >
void operator>>= (const SerializationInfo &si, std::pair< A, B > &p)
template<typename A , typename B >
void operator<<= (SerializationInfo &si, const std::pair< A, B > &p)
template<typename K , typename V , typename P , typename A >
void operator>>= (const SerializationInfo &si, std::map< K, V, P, A > &map)
template<typename K , typename V , typename P , typename A >
void operator<<= (SerializationInfo &si, const std::map< K, V, P, A > &map)
template<typename K , typename V , typename P , typename A >
void operator>>= (const SerializationInfo &si, std::multimap< K, V, P, A > &multimap)
template<typename T , typename C , typename P , typename A >
void operator<<= (SerializationInfo &si, const std::multimap< T, C, P, A > &multimap)
std::ostream & operator<< (std::ostream &out, const SerializationInfo &si)
template<typename R >
Connection connect (Signal< const cxxtools::Event & > &signal, R(*func)(const cxxtools::Event &))
template<typename R , class BaseT , class ClassT >
Connection connect (Signal< const cxxtools::Event & > &signal, BaseT &object, R(ClassT::*memFunc)(const cxxtools::Event &))
Connection connect (Signal< const cxxtools::Event & > &sender, Signal< const cxxtools::Event & > &receiver)
template<typename R >
void disconnect (Signal< const cxxtools::Event & > &signal, R(*func)(const cxxtools::Event &))
template<typename R , class BaseT , class ClassT >
void disconnect (Signal< const cxxtools::Event & > &signal, BaseT &object, R(ClassT::*memFunc)(const cxxtools::Event &))
void disconnect (Signal< const cxxtools::Event & > &sender, Signal< const cxxtools::Event & > &receiver)
template<typename T1 , typename T2 >
bool operator== (const SmartPtr< T1 > &p1, const T2 *p2)
template<typename T1 , typename T2 >
bool operator== (const T1 *p1, const SmartPtr< T2 > &p2)
template<typename T1 , typename T2 >
bool operator== (const SmartPtr< T1 > &p1, const SmartPtr< T2 > &p2)
template<typename T1 , typename T2 >
bool operator!= (const SmartPtr< T1 > &p1, const T2 *p2)
template<typename T1 , typename T2 >
bool operator!= (const T1 *p1, const SmartPtr< T2 > &p2)
template<typename T1 , typename T2 >
bool operator!= (const SmartPtr< T1 > &p1, const SmartPtr< T2 > &p2)
std::string operator+ (const std::string &what, const SourceInfo &info)
std::string operator+ (const char *what, const SourceInfo &info)
std::string operator+ (const SourceInfo &info, const std::string &what)
std::string operator+ (const SourceInfo &info, const char *what)
template<typename outputIterator , typename characterType >
void split (characterType ch, const std::basic_string< characterType > &line, outputIterator it)
 Splits a std::string into tokens using a delimiter character.
template<typename outputIterator , typename characterType >
void split (const characterType *chars, const std::basic_string< characterType > &line, outputIterator it)
 Splits a std::string into tokens using a set of delimiter characters.
template<typename outputIterator , typename characterType >
void split (const std::basic_string< characterType > &chars, const std::basic_string< characterType > &line, outputIterator it)
 Splits a std::string into tokens using a set of delimiter characters.
template<typename outputIterator >
void split (const Regex &re, const std::string &line, outputIterator it)
 Splits a std::string into tokens using a regular expression.
void throwSystemError (const char *fn)
void throwSystemError (int errnum, const char *fn)
template<typename CodecType >
std::basic_string< typename
CodecType::InternT > 
decode (const typename CodecType::ExternT *data, unsigned size)
 helper template function for decoding data using a codec.
template<typename CodecType >
std::basic_string< typename
CodecType::InternT > 
decode (const std::basic_string< typename CodecType::ExternT > &data)
 helper template function for decoding strings using a codec.
template<typename CodecType >
std::basic_string< typename
CodecType::ExternT > 
encode (const typename CodecType::InternT *data, unsigned size)
template<typename CodecType >
std::basic_string< typename
CodecType::ExternT > 
encode (const std::basic_string< typename CodecType::InternT > &data)
 helper template function for encoding strings using a codec.
std::basic_ostream< Char > & operator<< (std::basic_ostream< Char > &out, wchar_t ch)
std::basic_ostream< Char > & operator<< (std::basic_ostream< Char > &out, const wchar_t *str)
void operator>>= (const SerializationInfo &si, Time &time)
void operator<<= (SerializationInfo &si, const Time &time)
Time operator+ (const Time &time, const Timespan &ts)
 Addition operator.
Time operator- (const Time &time, const Timespan &ts)
 Subtraction operator.
Timespan operator* (const Timespan &d, double fac)
Timespan operator* (double fac, const Timespan &d)
Timespan operator/ (const Timespan &d, double fac)
std::ostream & operator<< (std::ostream &out, const Timespan &ts)
 outputs timespan as number of seconds with the suffix 's'
std::ostream & operator<< (std::ostream &out, const Microseconds &ts)
 outputs timespan as number of microseconds with the suffix 'us'
std::ostream & operator<< (std::ostream &out, const Milliseconds &ts)
 outputs timespan as number of milliseconds with the suffix 'ms'
std::istream & operator>> (std::istream &in, Timespan &ts)
 reads a whole number from stream and creates a timespan with the number of microseconds
std::istream & operator>> (std::istream &in, Microseconds &ts)
 reads a whole number from stream and creates a timespan with the number of microseconds
std::istream & operator>> (std::istream &in, Milliseconds &ts)
 reads a decimal number from stream and creates a timespan with the number of milliseconds
void operator>>= (const SerializationInfo &si, Timespan &timespan)
void operator>>= (const SerializationInfo &si, Milliseconds &timespan)
void operator<<= (SerializationInfo &si, const Timespan &timespan)
void operator<<= (SerializationInfo &si, const Microseconds &timespan)
void operator<<= (SerializationInfo &si, const Milliseconds &timespan)
template<typename StringType >
StringType ltrim (const StringType &s, const StringType &ws=StringType(" \t\r\n"))
template<typename StringType >
StringType rtrim (const StringType &s, const StringType &ws=StringType(" \t\r\n"))
template<typename StringType >
StringType trim (const StringType &s, const StringType &ws=StringType(" \t\r\n"))
Utf8OString Utf8 (const String &str)
 Function, which creates a Utf8OString.
Utf8OString Utf8 (const std::string &str)
Utf8IOString Utf8 (std::string &str)
 Creates a Utf8IString with a reference to a deserializable object.
void operator<<= (SerializationInfo &si, const Utf8OString &str)
void operator>>= (const SerializationInfo &si, Utf8IOString str)

Typedef Documentation

typedef LONG cxxtools::atomic_t
typedef WeakTimespan<int64_t(1000)*1000*60*60*24> cxxtools::Days

for compatibility with old implementation

typedef WeakTimespan<int64_t(1000)*1000*60*60> cxxtools::Hours
typedef std::basic_istringstream<cxxtools::Char> cxxtools::IStringStream

The typedefs makes specifying a timespan easy and readable.

Examples:

// for this example we assume these functions:
void foo(Milliseconds t); // a function expecting a timespan - default unit is milliseconds
Milliseconds foo(); // a function returning a timespan - default is to return milliseconds
// specify 5 milliseconds:
// specify half second:
cxxtools::Timespan halfSecond = Seconds(0.5);
// get a timespan value in seconds:
cxxtools::Timespan someTimespan = foo();
double numberOfSeconds = Seconds(someTimespan);
// or shorter:
double numberOfSeconds(Seconds(foo());
// pass a timespan to a function:
foo(500); // since foo expects a cxxtools::Milliseconds, the default is
// to convert a number to milliseconds timespan
foo(cxxtools::Seconds(0.5)); // Seconds is a Timespan, which can be converted to Milliseconds
// so that foo is here called with 500 milliseconds
// get the number of milliseconds or some other unit in a timespan:
cxxtools::Timespan someTimespan = foo();
double numberOfMilliseconds = cxxtools::Milliseconds(someTimespan);
double numberOfSeconds = cxxtools::Seconds(someTimespan);
double numberOfDays = cxxtools::Days(someTimespan);
typedef WeakTimespan<int64_t(1000)> cxxtools::Milliseconds
typedef WeakTimespan<int64_t(1000)*1000*60> cxxtools::Minutes
typedef std::basic_ostringstream<cxxtools::Char> cxxtools::OStringStream
typedef WeakTimespan<int64_t(1000)*1000> cxxtools::Seconds
typedef BasicStreamcounter<char, std::char_traits<char> > cxxtools::Streamcounter
typedef std::basic_string<cxxtools::Char> cxxtools::String

Unicode capable strings.

typedef std::basic_stringstream<cxxtools::Char> cxxtools::StringStream

Enumeration Type Documentation

Enumerator:
IOS_Sync 
IOS_Async 
IOS_Read 
IOS_Write 
IOS_AtEnd 
IOS_Append 
IOS_Trunc 
IOS_OpenModeEnd 

Function Documentation

atomic_t cxxtools::atomicCompareExchange ( volatile atomic_t &  val,
atomic_t  exch,
atomic_t  comp 
)

Performs an atomic compare-and-exchange operation.

If val is equal to comp, val is replaced by exch. The initial value of of val is returned.

void* cxxtools::atomicCompareExchange ( void *volatile &  ptr,
void *  exch,
void *  comp 
)

Performs an atomic compare-and-exchange operation.

If ptr is equal to comp, ptr is replaced by exch. The initial value of ptr is returned.

atomic_t cxxtools::atomicDecrement ( volatile atomic_t &  val)

Decreases a value by one as an atomic operation.

Returns the resulting decremented value.

atomic_t cxxtools::atomicExchange ( volatile atomic_t &  val,
atomic_t  exch 
)

Performs an atomic exchange operation.

Sets val to exch and returns the initial value of val.

void* cxxtools::atomicExchange ( void *volatile &  dest,
void *  exch 
)

Performs an atomic exchange operation.

Sets dest to exch and returns the initial value of dest.

atomic_t cxxtools::atomicExchangeAdd ( volatile atomic_t &  val,
atomic_t  add 
)

Performs atomic addition of two values.

Returns the initial value of the addend.

atomic_t cxxtools::atomicGet ( volatile atomic_t &  val)

Atomically get a value.

Returns the value after employing a memory fence.

atomic_t cxxtools::atomicIncrement ( volatile atomic_t &  val)

Increases a value by one as an atomic operation.

Returns the resulting incremented value.

void cxxtools::atomicSet ( volatile atomic_t &  val,
atomic_t  n 
)

Atomically set a value.

Sets the value and employs a memory fence.

template<typename T >
T cxxtools::beToHost ( value)

Converts a big endian value to native.

template<typename R >
Connection cxxtools::connect ( Signal< const cxxtools::Event & > &  signal,
R(*)(const cxxtools::Event &)  func 
)
template<typename R , class BaseT , class ClassT >
Connection cxxtools::connect ( Signal< const cxxtools::Event & > &  signal,
BaseT &  object,
R(ClassT::*)(const cxxtools::Event &)  memFunc 
)
Connection cxxtools::connect ( Signal< const cxxtools::Event & > &  sender,
Signal< const cxxtools::Event & > &  receiver 
)
inline
void cxxtools::convert ( String &  s,
const String &  str 
)
inline
void cxxtools::convert ( String &  s,
const std::string &  value 
)
void cxxtools::convert ( String &  s,
bool  value 
)
void cxxtools::convert ( String &  s,
char  value 
)
void cxxtools::convert ( String &  s,
wchar_t  value 
)
void cxxtools::convert ( String &  s,
Char  value 
)
void cxxtools::convert ( String &  s,
unsigned char  value 
)
void cxxtools::convert ( String &  s,
signed char  value 
)
void cxxtools::convert ( String &  s,
short  value 
)
void cxxtools::convert ( String &  s,
unsigned short  value 
)
void cxxtools::convert ( String &  s,
int  value 
)
void cxxtools::convert ( String &  s,
unsigned int  value 
)
void cxxtools::convert ( String &  s,
long  value 
)
void cxxtools::convert ( String &  s,
unsigned long  value 
)
void cxxtools::convert ( String &  s,
float  value 
)
void cxxtools::convert ( String &  s,
double  value 
)
void cxxtools::convert ( String &  s,
long double  value 
)
template<typename T >
void cxxtools::convert ( String &  s,
const T &  value 
)
inline
void cxxtools::convert ( bool &  n,
const String &  str 
)
void cxxtools::convert ( char &  n,
const String &  str 
)
void cxxtools::convert ( wchar_t &  n,
const String &  str 
)
void cxxtools::convert ( Char &  n,
const String &  str 
)
void cxxtools::convert ( unsigned char &  n,
const String &  str 
)
void cxxtools::convert ( signed char &  n,
const String &  str 
)
void cxxtools::convert ( short &  n,
const String &  str 
)
void cxxtools::convert ( unsigned short &  n,
const String &  str 
)
void cxxtools::convert ( int &  n,
const String &  str 
)
void cxxtools::convert ( unsigned int &  n,
const String &  str 
)
void cxxtools::convert ( long &  n,
const String &  str 
)
void cxxtools::convert ( unsigned long &  n,
const String &  str 
)
void cxxtools::convert ( float &  n,
const String &  str 
)
void cxxtools::convert ( double &  n,
const String &  str 
)
void cxxtools::convert ( long double &  n,
const String &  str 
)
template<typename T >
void cxxtools::convert ( T &  t,
const String &  str 
)
inline
void cxxtools::convert ( std::string &  s,
const std::string &  str 
)
inline
void cxxtools::convert ( std::string &  s,
const String &  str 
)
void cxxtools::convert ( std::string &  s,
bool  value 
)
void cxxtools::convert ( std::string &  s,
char  value 
)
void cxxtools::convert ( std::string &  s,
signed char  value 
)
void cxxtools::convert ( std::string &  s,
unsigned char  value 
)
void cxxtools::convert ( std::string &  s,
short  value 
)
void cxxtools::convert ( std::string &  s,
unsigned short  value 
)
void cxxtools::convert ( std::string &  s,
int  value 
)
void cxxtools::convert ( std::string &  s,
unsigned int  value 
)
void cxxtools::convert ( std::string &  s,
long  value 
)
void cxxtools::convert ( std::string &  s,
unsigned long  value 
)
void cxxtools::convert ( std::string &  s,
float  value 
)
void cxxtools::convert ( std::string &  s,
double  value 
)
void cxxtools::convert ( std::string &  s,
long double  value 
)
template<typename T >
void cxxtools::convert ( std::string &  s,
const T &  value 
)
inline
void cxxtools::convert ( bool &  n,
const std::string &  str 
)
void cxxtools::convert ( char &  n,
const std::string &  str 
)
void cxxtools::convert ( signed char &  n,
const std::string &  str 
)
void cxxtools::convert ( unsigned char &  n,
const std::string &  str 
)
void cxxtools::convert ( short &  n,
const std::string &  str 
)
void cxxtools::convert ( unsigned short &  n,
const std::string &  str 
)
void cxxtools::convert ( int &  n,
const std::string &  str 
)
void cxxtools::convert ( unsigned int &  n,
const std::string &  str 
)
void cxxtools::convert ( long &  n,
const std::string &  str 
)
void cxxtools::convert ( unsigned long &  n,
const std::string &  str 
)
void cxxtools::convert ( float &  n,
const std::string &  str 
)
void cxxtools::convert ( double &  n,
const std::string &  str 
)
void cxxtools::convert ( long double &  n,
const std::string &  str 
)
template<typename T >
void cxxtools::convert ( T &  t,
const std::string &  str 
)
inline
void cxxtools::convert ( bool &  n,
const char *  str 
)
void cxxtools::convert ( char &  n,
const char *  str 
)
void cxxtools::convert ( signed char &  n,
const char *  str 
)
void cxxtools::convert ( unsigned char &  n,
const char *  str 
)
void cxxtools::convert ( short &  n,
const char *  str 
)
void cxxtools::convert ( unsigned short &  n,
const char *  str 
)
void cxxtools::convert ( int &  n,
const char *  str 
)
void cxxtools::convert ( unsigned int &  n,
const char *  str 
)
void cxxtools::convert ( long &  n,
const char *  str 
)
void cxxtools::convert ( unsigned long &  n,
const char *  str 
)
void cxxtools::convert ( float &  n,
const char *  str 
)
void cxxtools::convert ( double &  n,
const char *  str 
)
void cxxtools::convert ( long double &  n,
const char *  str 
)
template<typename T , typename S >
void cxxtools::convert ( T &  to,
const S &  from 
)
template<typename T , typename S >
T cxxtools::convert ( const S &  from)
template<typename ObjectType >
CsvOObject<ObjectType> cxxtools::Csv ( const ObjectType &  object)

Function, which creates a CsvOObject.

This makes the syntactic sugar perfect. See the example at CsvOObject for its use.

template<typename ObjectType >
CsvIOObject<ObjectType> cxxtools::Csv ( ObjectType &  object)
std::ctype_base::mask cxxtools::ctypeMask ( const Char &  ch)
template<typename CodecType >
std::basic_string<typename CodecType::InternT> cxxtools::decode ( const typename CodecType::ExternT *  data,
unsigned  size 
)

helper template function for decoding data using a codec.

This template function makes it easy to use a codec to convert a string with one encoding to another.

template<typename CodecType >
std::basic_string<typename CodecType::InternT> cxxtools::decode ( const std::basic_string< typename CodecType::ExternT > &  data)

helper template function for decoding strings using a codec.

This template function makes it easy to use a codec to convert a string with one encoding to another.

std::string utf8data = ...;
cxxtools::String unicodeString = cxxtools::decode<cxxtools::Utf8Codec>(utf8data);
std::string base64data = ...;
std::string data = cxxtools::decode<cxxtools::Base64Codec>(base64data);
template<typename R >
void cxxtools::disconnect ( Signal< const cxxtools::Event & > &  signal,
R(*)(const cxxtools::Event &)  func 
)
template<typename R , class BaseT , class ClassT >
void cxxtools::disconnect ( Signal< const cxxtools::Event & > &  signal,
BaseT &  object,
R(ClassT::*)(const cxxtools::Event &)  memFunc 
)
void cxxtools::disconnect ( Signal< const cxxtools::Event & > &  sender,
Signal< const cxxtools::Event & > &  receiver 
)
inline
template<typename CodecType >
std::basic_string<typename CodecType::ExternT> cxxtools::encode ( const typename CodecType::InternT *  data,
unsigned  size 
)
template<typename CodecType >
std::basic_string<typename CodecType::ExternT> cxxtools::encode ( const std::basic_string< typename CodecType::InternT > &  data)

helper template function for encoding strings using a codec.

This template function makes it easy to use a codec to convert a string with one encoding to another.

cxxtools::String unicodeString = ...;
std::string utf8data = cxxtools::encode<cxxtools::Utf8Codec>(unicodeString);
std::string base64data = cxxtools::encode<cxxtools::Base64Codec>("some data");
std::string cxxtools::envSubst ( const std::string &  str)

Function uses the class cxxtools::EnvSubst to substitute environment variables in the passed string.

The replacement string is returned.

unsigned char cxxtools::formatAbs ( char  i,
bool &  isNeg 
)
inline
unsigned char cxxtools::formatAbs ( unsigned char  i,
bool &  isNeg 
)
inline
unsigned short cxxtools::formatAbs ( short  i,
bool &  isNeg 
)
inline
unsigned short cxxtools::formatAbs ( unsigned short  i,
bool &  isNeg 
)
inline
unsigned int cxxtools::formatAbs ( int  i,
bool &  isNeg 
)
inline
unsigned int cxxtools::formatAbs ( unsigned int  i,
bool &  isNeg 
)
inline
unsigned long cxxtools::formatAbs ( long  i,
bool &  isNeg 
)
inline
unsigned long cxxtools::formatAbs ( unsigned long  i,
bool &  isNeg 
)
inline
template<typename CharT , typename T , typename FormatT >
CharT* cxxtools::formatInt ( CharT *  buf,
std::size_t  buflen,
si,
const FormatT &  fmt 
)
inline

Formats an integer in a given format.

template<typename CharT , typename T >
CharT* cxxtools::formatInt ( CharT *  buf,
std::size_t  buflen,
i,
const BinaryFormat< CharT > &  fmt 
)
inline

Formats an integer in binary format.

template<typename InIterT , typename T , typename FormatT >
InIterT cxxtools::getFloat ( InIterT  it,
InIterT  end,
bool &  ok,
T &  n,
const FormatT &  fmt 
)

Parses a floating point value in a given format.

template<typename InIterT , typename T >
InIterT cxxtools::getFloat ( InIterT  it,
InIterT  end,
bool &  ok,
T &  n 
)

Parses a floating point value.

template<typename InIterT , typename T , typename FormatT >
InIterT cxxtools::getInt ( InIterT  it,
InIterT  end,
bool &  ok,
T &  n,
const FormatT &  fmt 
)

Parses an integer value in a given format.

template<typename InIterT , typename T >
InIterT cxxtools::getInt ( InIterT  it,
InIterT  end,
bool &  ok,
T &  n 
)

Parses an integer value in decimal format.

template<typename InIterT , typename FormatT >
InIterT cxxtools::getSign ( InIterT  it,
InIterT  end,
bool &  pos,
const FormatT &  fmt 
)
void cxxtools::greg2jul ( unsigned &  jd,
int  y,
int  m,
int  d 
)
template<typename T >
void cxxtools::hexDump ( std::ostream &  out,
const T &  t 
)
template<typename T >
std::string cxxtools::hexDump ( const T &  t)
std::string cxxtools::hexDump ( const char *  p,
unsigned  n 
)
inline
template<typename Algo , typename data_type >
std::string cxxtools::hmac ( const std::string &  key,
const data_type &  msg 
)
template<typename Algo , typename iterator_type >
std::string cxxtools::hmac ( const std::string &  key,
iterator_type  from,
iterator_type  to 
)
template<typename Algo >
void cxxtools::hmac_pad_key ( Algo &  key_hash,
const std::string &  key,
std::string &  o_key_pad,
std::string &  i_key_pad 
)
template<typename T >
T cxxtools::hostToBe ( value)

Converts a native value in big endian.

template<typename T >
T cxxtools::hostToLe ( value)

Converts a native value in little endian.

int cxxtools::isalnum ( const Char &  ch)
inline
int cxxtools::isalpha ( const Char &  ch)
inline
bool cxxtools::isBigEndian ( )
inline

Returns true, if machine is big-endian (high byte first).

e.g. PowerPC

int cxxtools::iscntrl ( const Char &  ch)
inline
int cxxtools::isdigit ( const Char &  ch)
inline
int cxxtools::isgraph ( const Char &  ch)
inline
bool cxxtools::isLittleEndian ( )
inline

Returns true, if machine is little-endian (low byte first).

e.g. x86

int cxxtools::islower ( const Char &  ch)
inline
int cxxtools::isprint ( const Char &  ch)
inline
int cxxtools::ispunct ( const Char &  ch)
inline
int cxxtools::isspace ( const Char &  ch)
inline
int cxxtools::isupper ( const Char &  ch)
inline
int cxxtools::isxdigit ( const Char &  ch)
inline
template<typename inputIterator , typename separatorType , typename characterType >
void cxxtools::join ( inputIterator  b,
inputIterator  e,
const separatorType &  sep,
std::basic_ostream< characterType > &  out 
)

Joins a list of tokens into a output stream using a delimiter.

A list of tokens read from a range is printed to a out stream. The tokens are separated by a token.

Example (prints "4, 17, 12"):

std::vector<unsigned> v;
v.push_back(4);
v.push_back(17);
v.push_back(12);
join(v.begin(), v.end(), ", ", std::cout);
template<typename inputIterator , typename separatorType >
std::string cxxtools::join ( inputIterator  b,
inputIterator  e,
const separatorType &  sep 
)

Joins a list of tokens into a std::string using a delimiter.

This function is just like the other join function, but returns the result as a std::string.

Example (prints "4, 17, 12"):

std::vector<unsigned> v;
v.push_back(4);
v.push_back(17);
v.push_back(12);
std::cout << join(v.begin(), v.end(), ", ");
template<typename ObjectType >
JsonOObject<ObjectType> cxxtools::Json ( const ObjectType &  object,
bool  beautify = false 
)

Function, which creates a JsonOObject.

This makes the syntactic sugar perfect. See the example at JsonOObject for its use.

template<typename ObjectType >
JsonIOObject<ObjectType> cxxtools::Json ( ObjectType &  object)

Creates a JsonIObject with a reference to a deserializable object.

See JsonIObject for a usage example.

void cxxtools::jul2greg ( unsigned  jd,
int &  y,
int &  m,
int &  d 
)
template<typename T >
T cxxtools::leToHost ( value)

Converts a little endian value to native.

template<typename StringType >
StringType cxxtools::ltrim ( const StringType &  s,
const StringType &  ws = StringType(" \t\r\n") 
)
template<typename iterator_type >
std::string cxxtools::md5 ( iterator_type  from,
iterator_type  to 
)
template<typename data_type >
std::string cxxtools::md5 ( const data_type &  data)
void cxxtools::membar_read ( )
inline
void cxxtools::membar_rw ( )
inline
void cxxtools::membar_write ( )
inline
bool cxxtools::operator!= ( const File &  a,
const File &  b 
)
inline
bool cxxtools::operator!= ( const FileInfo &  a,
const FileInfo &  b 
)
inline
bool cxxtools::operator!= ( const Directory &  a,
const Directory &  b 
)
inline
template<typename T1 , typename T2 >
bool cxxtools::operator!= ( const SmartPtr< T1 > &  p1,
const T2 *  p2 
)
template<typename T1 , typename T2 >
bool cxxtools::operator!= ( const T1 *  p1,
const SmartPtr< T2 > &  p2 
)
template<typename T1 , typename T2 >
bool cxxtools::operator!= ( const SmartPtr< T1 > &  p1,
const SmartPtr< T2 > &  p2 
)
IOS_OpenMode cxxtools::operator& ( IOS_OpenMode  a,
IOS_OpenMode  b 
)
inline
IOS_OpenMode& cxxtools::operator&= ( IOS_OpenMode &  a,
IOS_OpenMode  b 
)
inline
Timespan cxxtools::operator* ( const Timespan &  d,
double  fac 
)
inline
Timespan cxxtools::operator* ( double  fac,
const Timespan &  d 
)
inline
std::string cxxtools::operator+ ( const std::string &  what,
const SourceInfo &  info 
)
inline
std::string cxxtools::operator+ ( const char *  what,
const SourceInfo &  info 
)
inline
std::string cxxtools::operator+ ( const SourceInfo &  info,
const std::string &  what 
)
inline
std::string cxxtools::operator+ ( const SourceInfo &  info,
const char *  what 
)
inline
Time cxxtools::operator+ ( const Time &  time,
const Timespan &  ts 
)
inline

Addition operator.

Date cxxtools::operator+ ( const Date &  d,
int  days 
)
inline
Date cxxtools::operator+ ( int  days,
const Date &  d 
)
inline
Time cxxtools::operator- ( const Time &  time,
const Timespan &  ts 
)
inline

Subtraction operator.

Days cxxtools::operator- ( const Date &  a,
const Date &  b 
)
inline
Timespan cxxtools::operator/ ( const Timespan &  d,
double  fac 
)
inline
bool cxxtools::operator< ( const File &  a,
const File &  b 
)
inline
bool cxxtools::operator< ( const FileInfo &  a,
const FileInfo &  b 
)
inline
bool cxxtools::operator< ( const Directory &  a,
const Directory &  b 
)
inline
template<typename CharType , typename ObjectType >
std::basic_ostream<CharType>& cxxtools::operator<< ( std::basic_ostream< CharType > &  out,
const PropertiesOObject< ObjectType > &  object 
)

The output operator for PropertiesOObject. It does the actual work.

template<typename CharType , typename ObjectType >
std::basic_ostream<CharType>& cxxtools::operator<< ( std::basic_ostream< CharType > &  out,
const JsonOObject< ObjectType > &  object 
)

The output operator for JsonOObject. It does the actual work.

template<typename CharType , typename ObjectType >
std::basic_ostream<CharType>& cxxtools::operator<< ( std::basic_ostream< CharType > &  out,
const CsvOObject< ObjectType > &  object 
)

The output operator for CsvOObject. It does the actual work.

MimeEntity& cxxtools::operator<< ( MimeEntity &  me,
const std::string &  str 
)
inline

operator to add a std::string to a mime entity body.

MimeEntity& cxxtools::operator<< ( MimeEntity &  me,
const char *  str 
)
inline

operator to add a const char* to a mime entity body.

std::ostream& cxxtools::operator<< ( std::ostream &  out,
const HexDump &  hd 
)
inline

Outputs data to output stream as a hex dump.

Example:

const char* buffer = ...;
unsigned bufsize = ...
std::cout << HexDump(buffer, bufsize);

This outputs the content of the buffer to standard out as a hex dump.

std::ostream& cxxtools::operator<< ( std::ostream &  out,
const IniFile &  ini 
)

Outputs ini file to an output stream.

internal std::ostream& cxxtools::operator<< ( std::ostream &  out,
Char  ch 
)
std::ostream& cxxtools::operator<< ( std::ostream &  out,
const MimeHeader &  mimeHeader 
)
std::ostream& cxxtools::operator<< ( std::ostream &  out,
const MimeEntity &  mimeEntity 
)
std::ostream& cxxtools::operator<< ( std::ostream &  out,
const MimeMultipart &  mime 
)
std::ostream& cxxtools::operator<< ( std::ostream &  out,
const QueryParams &  p 
)
inline

output QueryParams in url-syntax

std::ostream& cxxtools::operator<< ( std::ostream &  out,
const Timespan &  ts 
)

outputs timespan as number of seconds with the suffix 's'

std::ostream& cxxtools::operator<< ( std::ostream &  out,
const Microseconds &  ts 
)

outputs timespan as number of microseconds with the suffix 'us'

std::ostream & cxxtools::operator<< ( std::ostream &  out,
const Milliseconds &  ts 
)

outputs timespan as number of milliseconds with the suffix 'ms'

outputs timespan as number of days with the suffix 'd'

outputs timespan as number of hours with the suffix 'h'

outputs timespan as number of minutes with the suffix 'min'

outputs timespan as number of seconds with the suffix 's'

std::basic_ostream<Char>& cxxtools::operator<< ( std::basic_ostream< Char > &  out,
wchar_t  ch 
)
inline
std::basic_ostream<Char>& cxxtools::operator<< ( std::basic_ostream< Char > &  out,
const wchar_t *  str 
)
inline
template<typename T >
std::ostream& cxxtools::operator<< ( std::ostream &  out,
const ArgBaseT< T > &  arg 
)

Output operator for a argument.

std::ostream& cxxtools::operator<< ( std::ostream &  out,
const SerializationInfo &  si 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
const Utf8OString &  str 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
const LogConfiguration &  logConfiguration 
)
void cxxtools::operator<<= ( SerializationInfo &  si,
const DateTime &  dt 
)
void cxxtools::operator<<= ( SerializationInfo &  si,
const Time &  time 
)
void cxxtools::operator<<= ( SerializationInfo &  si,
const Date &  date 
)
void cxxtools::operator<<= ( SerializationInfo &  si,
const SerializationInfo &  ssi 
)
void cxxtools::operator<<= ( SerializationInfo &  si,
bool  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
const Timespan &  timespan 
)
void cxxtools::operator<<= ( SerializationInfo &  si,
const Microseconds &  timespan 
)
void cxxtools::operator<<= ( SerializationInfo &  si,
signed char  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
const Milliseconds &  timespan 
)
void cxxtools::operator<<= ( SerializationInfo &  si,
unsigned char  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
char  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
short  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
unsigned short  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
int  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
unsigned int  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
long  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
unsigned long  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
float  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
double  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::string &  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
const char *  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
const String &  n 
)
inline
void cxxtools::operator<<= ( SerializationInfo &  si,
const Char &  n 
)
inline
template<typename T , typename A >
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::vector< T, A > &  vec 
)
inline
template<typename T , typename A >
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::list< T, A > &  list 
)
inline
template<typename T , typename A >
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::deque< T, A > &  deque 
)
inline
template<typename T , typename C , typename A >
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::set< T, C, A > &  set 
)
inline
template<typename T , typename C , typename A >
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::multiset< T, C, A > &  multiset 
)
inline
template<typename A , typename B >
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::pair< A, B > &  p 
)
inline
template<typename K , typename V , typename P , typename A >
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::map< K, V, P, A > &  map 
)
inline
template<typename T , typename C , typename P , typename A >
void cxxtools::operator<<= ( SerializationInfo &  si,
const std::multimap< T, C, P, A > &  multimap 
)
inline
bool cxxtools::operator== ( const File &  a,
const File &  b 
)
inline
bool cxxtools::operator== ( const FileInfo &  a,
const FileInfo &  b 
)
inline
bool cxxtools::operator== ( const Directory &  a,
const Directory &  b 
)
inline
template<typename T1 , typename T2 >
bool cxxtools::operator== ( const SmartPtr< T1 > &  p1,
const T2 *  p2 
)
template<typename T1 , typename T2 >
bool cxxtools::operator== ( const T1 *  p1,
const SmartPtr< T2 > &  p2 
)
template<typename T1 , typename T2 >
bool cxxtools::operator== ( const SmartPtr< T1 > &  p1,
const SmartPtr< T2 > &  p2 
)
template<typename CharType , typename ObjectType >
std::basic_istream<CharType>& cxxtools::operator>> ( std::basic_istream< CharType > &  in,
PropertiesIOObject< ObjectType >  object 
)

The input operator for PropertiesIOObject. It does the actual work.

template<typename CharType , typename ObjectType >
std::basic_istream<CharType>& cxxtools::operator>> ( std::basic_istream< CharType > &  in,
JsonIOObject< ObjectType >  object 
)

The input operator for JsonIOObject. It does the actual work.

template<typename CharType , typename ObjectType >
std::basic_istream<CharType>& cxxtools::operator>> ( std::basic_istream< CharType > &  in,
CsvIOObject< ObjectType >  object 
)

The input operator for CsvIOObject. It does the actual work.

std::istream& cxxtools::operator>> ( std::istream &  in,
IniFile &  ini 
)

Reads ini file from an output stream.

std::istream& cxxtools::operator>> ( std::istream &  in,
Timespan &  ts 
)
inline

reads a whole number from stream and creates a timespan with the number of microseconds

std::istream& cxxtools::operator>> ( std::istream &  in,
Microseconds &  ts 
)
inline

reads a whole number from stream and creates a timespan with the number of microseconds

std::istream & cxxtools::operator>> ( std::istream &  in,
Milliseconds &  ts 
)
inline

reads a decimal number from stream and creates a timespan with the number of milliseconds

reads a decimal number from stream and creates a timespan with the number of days

reads a decimal number from stream and creates a timespan with the number of hours

reads a decimal number from stream and creates a timespan with the number of minutes

reads a decimal number from stream and creates a timespan with the number of seconds

void cxxtools::operator>>= ( const SerializationInfo &  si,
Utf8IOString  str 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
LogConfiguration &  logConfiguration 
)
void cxxtools::operator>>= ( const SerializationInfo &  si,
DateTime &  dt 
)
void cxxtools::operator>>= ( const SerializationInfo &  si,
Time &  time 
)
void cxxtools::operator>>= ( const SerializationInfo &  si,
Date &  date 
)
void cxxtools::operator>>= ( const SerializationInfo &  si,
Timespan &  timespan 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
SerializationInfo &  ssi 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
Milliseconds &  timespan 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
bool &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
signed char &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
unsigned char &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
char &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
short &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
unsigned short &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
int &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
unsigned int &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
long &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
unsigned long &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
float &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
double &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::string &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
String &  n 
)
inline
void cxxtools::operator>>= ( const SerializationInfo &  si,
Char &  n 
)
inline
template<typename T , typename A >
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::vector< T, A > &  vec 
)
inline
template<typename T , typename A >
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::list< T, A > &  list 
)
inline
template<typename T , typename A >
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::deque< T, A > &  deque 
)
inline
template<typename T , typename C , typename A >
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::set< T, C, A > &  set 
)
inline
template<typename T , typename C , typename A >
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::multiset< T, C, A > &  multiset 
)
inline
template<typename A , typename B >
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::pair< A, B > &  p 
)
inline
template<typename K , typename V , typename P , typename A >
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::map< K, V, P, A > &  map 
)
inline
template<typename K , typename V , typename P , typename A >
void cxxtools::operator>>= ( const SerializationInfo &  si,
std::multimap< K, V, P, A > &  multimap 
)
inline
IOS_OpenMode cxxtools::operator^ ( IOS_OpenMode  a,
IOS_OpenMode  b 
)
inline
IOS_OpenMode& cxxtools::operator^= ( IOS_OpenMode &  a,
IOS_OpenMode  b 
)
inline
IOS_OpenMode cxxtools::operator| ( IOS_OpenMode  a,
IOS_OpenMode  b 
)
inline
IOS_OpenMode& cxxtools::operator|= ( IOS_OpenMode &  a,
IOS_OpenMode  b 
)
inline
IOS_OpenMode cxxtools::operator~ ( IOS_OpenMode  a)
inline
template<typename ObjectType >
PropertiesIOObject<ObjectType> cxxtools::Properties ( ObjectType &  object,
const std::string &  name = std::string() 
)
template<typename OutIterT , typename T , typename FormatT >
OutIterT cxxtools::putFloat ( OutIterT  it,
d,
const FormatT &  fmt,
int  precision 
)
inline

Formats a floating point value in a given format.

template<typename OutIterT , typename T >
OutIterT cxxtools::putFloat ( OutIterT  it,
d 
)
inline

Formats a floating point value in default format.

template<typename OutIterT , typename T , typename FormatT >
OutIterT cxxtools::putInt ( OutIterT  it,
i,
const FormatT &  fmt 
)
inline

Formats an integer in a given format format.

template<typename OutIterT , typename T >
OutIterT cxxtools::putInt ( OutIterT  it,
i 
)
inline

Formats an integer in a decimal format.

template<typename T >
internal T cxxtools::reverse ( value)

Returns the value in reversed byte order.

template<typename StringType >
StringType cxxtools::rtrim ( const StringType &  s,
const StringType &  ws = StringType(" \t\r\n") 
)
template<typename outputIterator , typename characterType >
void cxxtools::split ( characterType  ch,
const std::basic_string< characterType > &  line,
outputIterator  it 
)

Splits a std::string into tokens using a delimiter character.

This is a little helper functions, which splits a string into tokens. A delimiter character is passed as a character and the resulting tokens are written to a output iterator.

The most common output iterator is a std::back_inserter.

Example (print username and uid on a unix system):

std::ifstream passwd("/etc/passwd");
std::string line;
while (std::getline(passwd, line))
{
std::vector<std::string> tokens;
cxxtools::split(':', line, std::back_inserter(tokens));
if (tokens.size() > 2)
std::cout << "username: " << tokens[0] << " uid=" << tokens[2] << std::endl;
}
template<typename outputIterator , typename characterType >
void cxxtools::split ( const characterType *  chars,
const std::basic_string< characterType > &  line,
outputIterator  it 
)

Splits a std::string into tokens using a set of delimiter characters.

This is a little helper functions, which splits a string into tokens. A set of delimiter characters is passed as a zero terminated char array and the resulting tokens are written to a output iterator.

The most common output iterator is a std::back_inserter.

Example (splits a line on white space):

std::string line = ...;
std::vector<std::string> tokens;
cxxtools::split(" \t", line, std::back_inserter(tokens));
template<typename outputIterator , typename characterType >
void cxxtools::split ( const std::basic_string< characterType > &  chars,
const std::basic_string< characterType > &  line,
outputIterator  it 
)

Splits a std::string into tokens using a set of delimiter characters.

This is a little helper functions, which splits a string into tokens. A set of delimiter characters is passed as a string and the resulting tokens are written to a output iterator.

The most common output iterator is a std::back_inserter.

Example (splits a line on white space):

std::string line = ...;
std::vector<std::string> tokens;
cxxtools::split("[ \t]+", line, std::back_inserter(tokens));
template<typename outputIterator >
void cxxtools::split ( const Regex &  re,
const std::string &  line,
outputIterator  it 
)

Splits a std::string into tokens using a regular expression.

This function is much like the other split function, but uses a regular expression to find a delimiter. This is useful e.g. to split a string using white space:

Example (splits a line on white space):

std::string line = ...;
std::vector<std::string> tokens;
cxxtools::split(cxxtools::Regex("[ \t]+"), line, std::back_inserter(tokens));
void cxxtools::throwSystemError ( const char *  fn)
void cxxtools::throwSystemError ( int  errnum,
const char *  fn 
)
Char cxxtools::tolower ( const Char &  ch)
Char cxxtools::toupper ( const Char &  ch)
template<typename StringType >
StringType cxxtools::trim ( const StringType &  s,
const StringType &  ws = StringType(" \t\r\n") 
)
Utf8OString cxxtools::Utf8 ( const String &  str)
inline

Function, which creates a Utf8OString.

This makes the syntactic sugar perfect. See the example at Utf8OString for its use.

Utf8OString cxxtools::Utf8 ( const std::string &  str)
inline
Utf8IOString cxxtools::Utf8 ( std::string &  str)
inline

Creates a Utf8IString with a reference to a deserializable object.

See Utf8IString for a usage example.