libcommonc++  0.7
ccxx Namespace Reference

Classes

class  AbstractBuffer
 An abstract base class for buffers. More...
 
class  AbstractCache
 An abstract base class for a general-purpose LRU-cache with a maximum capacity. More...
 
class  AddressInUseException
 An exception indicating that a socket address could not be bound because it is already in use. More...
 
class  AllocationMap
 An index allocation map. More...
 
class  Application
 Base functionality for an application, including command-line argument parsing and a shutdown handler. More...
 
class  Array
 A simple object wrapper for arrays. More...
 
class  AsyncIOPoller
 A class that polls a set of AsyncIOTask objects. More...
 
class  AsyncIOTask
 An object representing an asynchronous I/O operation. More...
 
class  AtomicCounter
 An integer counter whose value is modified in an atomic fashion. More...
 
class  Base64
 Base-64 encoding and decoding routines. More...
 
class  BasicBufferedStream
 A buffered stream. More...
 
class  BitSet
 A compact representation of an array of bits (boolean values). More...
 
class  Blob
 A reference-counting, copy-on-write, threadsafe container for arbitrary binary data. More...
 
class  BoundedQueue
 A bounded, threadsafe FIFO processing queue. More...
 
class  BTree
 A balanced, n-ary tree data structure for storing key/value relationships. More...
 
class  Buffer
 A buffer for storing a contiguous sequence of elements. More...
 
class  ByteArrayDataReader
 A DataReader which reads data from a byte array. More...
 
class  ByteArrayDataWriter
 A DataWriter which writes data to a byte array. More...
 
class  ByteBufferDataReader
 A DataReader which reads data from a ByteBuffer. More...
 
class  ByteBufferDataWriter
 A DataWriter which writes data to a ByteBuffer. More...
 
class  ByteOrder
 Byte-order conversion routines. More...
 
class  Cache
 A general-purpose LRU-cache with a maximum capacity. More...
 
class  Char
 A class representing a UTF-16 character. More...
 
class  CharOps
 UTF-16 character array operations. More...
 
class  Checksum
 A base class for checksum generators. More...
 
class  CircularBuffer
 A circular buffer that can be used to efficiently transfer data between buffers and/or streams. More...
 
class  CircularByteBufferDataReader
 A DataReader which reads data from a CircularByteBuffer. More...
 
class  CircularByteBufferDataWriter
 A DataWriter which writes data to a CircularByteBuffer. More...
 
class  ConditionVar
 A condition variable – a synchronization mechanism used to coordinate the actions of multiple threads. More...
 
class  Connection
 An abstract object representing a network connection. More...
 
class  ConnectionRefusedException
 An exception indicating that a connection attempt was refused because there was no process listening on the remote port. More...
 
class  Console
 A class that provides basic control of the console, such as changing text attributes, clearing the screen, and moving the cursor. More...
 
class  ConsoleLogger
 A logger that writes to the console (the standard error stream). More...
 
class  CPUStats
 System CPU utilization statistics. More...
 
class  CRC32Checksum
 A class for generating CRC-32 checksums. More...
 
class  CriticalSection
 A critical section, a synchronization primitive that is typically more efficient than but roughly semantically equivalent to a Mutex. More...
 
class  CString
 An implicitly shared, reference-counted container for an immutable, NUL-terminated C string. More...
 
class  CStringBuilder
 A utility class for constructing C-style strings. More...
 
class  CStringLessThanFunctor
 A "less than" comparator for C strings. More...
 
class  DataEncoder
 An abstract class with basic functionality that is common to all data decoders (readers) and data encoders (writers). More...
 
class  DataFormatException
 An exception indicating a data format error. More...
 
class  DatagramSocket
 A User Datagram (UDP) socket. More...
 
class  DataReader
 An abstract base class for data readers. More...
 
class  DataWriter
 An abstract base class for data writers. More...
 
class  Date
 A representation of a calendar date. More...
 
class  DateTime
 A representation of a calendar date and clock time. More...
 
class  DateTimeFormat
 A formatter for dates and times. More...
 
struct  DeleteFunctor
 A functor that deletes its argument. More...
 
class  Digest
 An abstract base class for message digests. More...
 
class  Dir
 Directory reading support. More...
 
class  DirectoryWatcher
 A class that watches for changes in a given directory. More...
 
class  DynamicArray
 A simple object wrapper for dynamically-allocated arrays. More...
 
class  DynamicCache
 An LRU cache implementation in which cache objects are deleted when they are removed from the cache. More...
 
class  DynamicObjectPool
 An object pool that dynamically allocates its objects. More...
 
class  EncodingException
 An exception indicating that a character string encoding error has occurred. More...
 
class  EnumMap
 A bidirectional mapping between enum values and static string constants. More...
 
class  EnumTraits
 A class of functions that describe traits of an enumeration. More...
 
class  EOFException
 An exception indicating an end-of-file condition for a file stream or a broken connection for a socket or pipe. More...
 
class  EventHandler
 A functor for event-handler callbacks. More...
 
class  EventHandlerDelegate
 An implementation of EventHandler that delegates to a method in an object. More...
 
class  Exception
 A general-purpose exception. More...
 
class  ExitStatus
 The exit status of a process. More...
 
class  File
 A representation of a file in the filesystem. More...
 
struct  FileAttributes
 File attributes. More...
 
class  FileLogger
 A logger that writes to a file, and can optionally perform log rotation. More...
 
class  FileName
 A class representing a filename. More...
 
class  FilePtr
 A smart pointer for stdio streams. More...
 
class  FileTraverser
 A depth- or breadth-first file traverser. More...
 
class  Flags
 A wrapper template for primitive integer types that represent flag bitmasks. More...
 
class  Hash
 A collection of hash functions. More...
 
class  Hex
 Routines for ASCII hex encoding and decoding. More...
 
class  HostNotFoundException
 An exception indicating a hostname resolution failure or malformed IP address string. More...
 
class  InetAddress
 An IPv4 Internet address. More...
 
class  InterruptedException
 An exception indicating that a blocking operation was interrupted. More...
 
class  IntervalTimer
 A high-precision interval timer that does not require blocking or polling from a dedicated thread. More...
 
class  InvalidArgumentException
 An exception indicating that an invalid argument was passed to a function. More...
 
class  IOException
 An exception indicating an I/O error. More...
 
class  Iterator
 A Java-style iterator. More...
 
class  JavaArrayAccessException
 An exception indicating an attempt to store a value of an inappropriate type into a Java array. More...
 
class  JavaBuffer
 An implementation of Buffer representing a Java direct buffer. More...
 
class  JavaClassLoaderException
 An exception indicating that the raw bytecode for a class could not be loaded because of a class format, bytecode verification, or security error. More...
 
class  JavaClassNotFoundException
 An exception indicating that a requested Java class was not found. More...
 
class  JavaContext
 When the Invocation Interface is being used (that is, when a C++ program calls into Java code), the getContext() method of the JavaVirtualMachine class is used to obtain an appropriate JavaContext object. More...
 
class  JavaException
 A base class for all Java Virtual Machine exceptions. More...
 
class  JavaFieldAccessException
 An exception indicating an attempt at an invalid field access. More...
 
class  JavaFieldNotFoundException
 An exception indicating that a requested field of a Java class was not found. More...
 
class  JavaInstantiationException
 An exception indicating that an error occurred while instantiating a Java class. More...
 
class  JavaInvocationException
 An exception indicating that a Java exception occurred while invoking a Java method. More...
 
class  JavaMethodNotFoundException
 An exception indicating that a requested method of a Java class was not found. More...
 
class  JavaMonitorException
 An exception indicating an illegal monitor state. More...
 
struct  JavaNativeMethod
 A structure representing a Java native method. More...
 
class  JavaNotAttachedException
 An exception indicating that a call was made from a native thread that is not attached to the JVM. More...
 
class  JavaOutOfMemoryException
 An exception indicating exhaustion of heap space in the Java Virtual Machine. More...
 
class  JavaScope
 A convenience class for creating lexical Java scopes in native code. More...
 
class  JavaSignatureException
 An exception indicating that a Java method signature string was malformed. More...
 
class  JavaThreadException
 An exception indicating a native thread attach or detach operation failed. More...
 
class  JavaThreadLocalBuffer
 Thread-local Java direct buffer. More...
 
class  JavaVirtualMachine
 An object that encapsulates (most of) the Java Native Interface (JNI) to a Java Virtual Machine. More...
 
class  LoadableModule
 An encapsulation of a dynamically loadable module, such as a shared library or object file on UNIX systems or a DLL on Windows. More...
 
class  LoadAverageStats
 System "load average" statistics. More...
 
class  Locale
 A class that encapsulates locale-specific information. More...
 
class  Lock
 An abstract base class for synchronization primitives. More...
 
class  Log
 Logging routines. More...
 
class  LogFormat
 A log message formatter. More...
 
class  Logger
 An abstract base class for threadsafe loggers. More...
 
class  MACAddress
 A network hardware (MAC) address. More...
 
class  MD5Digest
 A class for generating MD5 digests. More...
 
class  MD5Password
 MD5-hash password encryption and validation routines. More...
 
class  MemoryBlock
 An encapsulation of a block of memory. More...
 
class  MemoryMappedFile
 An abstraction of a memory-mapped file. More...
 
class  MemoryStats
 System memory utilization statistics. More...
 
class  MulticastSocket
 A UDP multicast socket. More...
 
class  Mutex
 A mutual-exclusion lock. More...
 
class  Network
 Network-related routines. More...
 
class  NetworkInterface
 An aggregation of information about a network interface. More...
 
class  NullPointerException
 An exception indicating an attempt to dereference a null pointer. More...
 
class  Numeric
 Numeric and bitwise utility functions. More...
 
class  ObjectPool
 A base class for object pools. More...
 
class  ObjectPoolException
 An exception indicating an ObjectPool error. More...
 
class  OutOfBoundsException
 An exception indicating that an attempted operation would result in an out-of-range array index access or a buffer overflow/underflow. More...
 
class  ParseException
 An exception indicating a parsing error. More...
 
class  PathNotFoundException
 An exception indicating a file or directory was not found. More...
 
class  Permissions
 File permissions. More...
 
class  Pipe
 A unidirectional stream pipe. More...
 
class  Plugin
 A class representing a dynamically loaded plugin. More...
 
class  PluginLoader
 A convenience class for loading Plugin objects. More...
 
class  Process
 A system process. More...
 
class  ProgressTracker
 An interface for tracking the progress of a lengthy operation. More...
 
class  ProgressTrackerDelegate
 An implementation of ProgressTracker that delegates to a method in an object. More...
 
class  PulseTimer
 A timer that fires at regular intervals, with a resolution of 1 second. More...
 
class  Random
 A random number generator. More...
 
class  ReadWriteLock
 A Read/Write lock – a synchronization primitive that allows multiple threads to coordinate access to a mutable resource. More...
 
class  RefSet
 A reference-counted set. More...
 
class  RegExp
 A regular expression. More...
 
class  RegExpMatch
 A regular expression substring match. More...
 
class  Runnable
 A runnable object. More...
 
class  RunnableClosure
 An adapter object similar to RunnableDelegate that additionally takes an arbitrary argument which will be passed to the member function. More...
 
class  RunnableDelegate
 An adapter object that implements the Runnable interface and delegates to an arbitrary method (one that must have no arguments or return value) in some other object. More...
 
class  ScopedLock
 A convenience object for lexical scope based synchronization. More...
 
class  ScopedPtr
 A non-copyable scoped pointer. More...
 
class  ScopedReadLock
 A convenience object for lexical scope based synchronization. More...
 
class  ScopedWriteLock
 A convenience object for lexical scope based synchronization. More...
 
class  SearchPath
 A file search path. More...
 
class  Semaphore
 A counting semaphore – a synchronization primitive that allows multiple processes to coordinate access to a shared resource. More...
 
class  SerialPort
 A class representing a serial communications port. More...
 
class  ServerSocket
 A server (listening) socket for StreamSocket (TCP) connections. More...
 
class  ServerStreamPipe
 A server (listening) pipe for StreamPipe connections. More...
 
class  Service
 Basic functionality for a system service, such as a daemon on UNIX or an "NT Service" on Windows. More...
 
class  SHA1Digest
 A class for generating SHA-1 digests. More...
 
class  SharedMemoryBlock
 An encapsulation of a block of memory that can be mapped by one or more (not necessarily related) processes; when one process changes the data in the block, the changes are immediately visible to the other processes. More...
 
class  SharedPtr
 A threadsafe, reference-counting smart pointer. More...
 
class  Socket
 A base class for network sockets. More...
 
class  SocketAddress
 A socket endpoint network address. More...
 
class  SocketException
 A general-purpose socket exception. More...
 
class  SocketIOException
 A general-purose socket I/O exception. More...
 
class  SocketSelector
 A socket I/O selector. More...
 
class  SQLDatabase
 A class representing a session with an embedded SQL database. More...
 
class  SQLException
 An exception indicating a SQL database error. More...
 
class  SQLQuery
 An SQL prepared statement that can be efficiently executed multiple times. More...
 
class  SQLTransaction
 A scoped database transaction. More...
 
class  SQLValueBinder
 A value binder for a SQLQuery object. More...
 
class  StaticCache
 An LRU cache implementation in which cache objects are recycled when they are removed from the cache. More...
 
class  StaticObjectPool
 An object pool that allocates (presumably fixed-size) objects in a contiguous memory buffer. More...
 
class  StopWatch
 A stopwatch-style timer. More...
 
class  Stream
 An unbuffered I/O stream. More...
 
class  StreamDataReader
 A DataReader which reads data from a Stream. More...
 
class  StreamDataWriter
 A DataWriter which writes data to a Stream. More...
 
class  StreamPipe
 A full-duplex stream pipe. More...
 
class  StreamSocket
 A reliable, connection-oriented stream (TCP) socket. More...
 
class  String
 A flexible, reference counted, copy-on-write, thread-safe, nullable string. More...
 
class  StringVec
 A String vector. More...
 
class  System
 Various system-level utility functions. More...
 
class  SystemException
 A system-level exception. More...
 
class  SystemLog
 The system event log. More...
 
class  SystemStats
 A collector of system performance or resource utilization statistics. More...
 
class  TempFile
 A temporary file that may optionally "shadow" another file. More...
 
class  Thread
 A thread of execution. More...
 
class  ThreadLocal
 Thread-local storage smart pointer. More...
 
class  ThreadLocalBuffer
 Thread-local data buffer. More...
 
class  ThreadLocalCounter
 Thread-local numeric counter. More...
 
class  Time
 A representation of a clock time. More...
 
class  TimeoutException
 An exception indicating that a blocking operation has timed out. More...
 
class  TimeSpan
 A span of time (a delta), represented in milliseconds. More...
 
class  TimeSpec
 A time specification, such as that used by cron servers. More...
 
class  UnsupportedOperationException
 An exception indicating that an attempted operation is not supported. More...
 
class  URL
 A class representing a URL (Uniform Resource Locator). More...
 
class  UTF32Decoder
 A UTF-32 to UTF-16 string transcoder. More...
 
class  UTF8Decoder
 A UTF-8 to UTF-16 string transcoder. More...
 
class  UTF8Encoder
 A UTF-16 to UTF-8 string transcoder. More...
 
class  UTFDecoder
 A base class for transcoders that decode strings to UTF-16 from a different UTF encoding. More...
 
class  UUID
 A universally unique identifier. More...
 
class  Variant
 A general-purpose variant type. More...
 
class  Version
 A class representing an interface version number. More...
 
class  XDRDecoder
 A decoder for XDR, the eXternal Data Representation format. More...
 
class  XDREncoder
 An encoder for XDR, the eXternal Data Representation format. More...
 
class  XMLDocument
 An object representing an XML document. More...
 
class  XMLElement
 An object representing an XML element. More...
 
class  XMLElementConstIterator
 An XMLElement const iterator. More...
 
class  XMLElementIterator
 An XMLElement iterator. More...
 

Typedefs

typedef BasicBufferedStream< char > BufferedCharStream
 
typedef BasicBufferedStream< byte_tBufferedByteStream
 
typedef Buffer< byte_tByteBuffer
 
typedef Buffer< char > CharBuffer
 
typedef BasicBufferedStream< char > BufferedStream
 
typedef BasicBufferedStream< wchar_t > BufferedWStream
 
typedef CircularBuffer< byte_tCircularByteBuffer
 
typedef CircularBuffer< char > CircularCharBuffer
 
typedef uint16_t char16_t
 A UTF-16 character. More...
 
typedef uint32_t char32_t
 A UTF-32 character. More...
 
typedef pid_t ProcessHandle
 
typedef pid_t ProcessID
 
typedef pthread_t ThreadHandle
 
typedef pthread_t ThreadID
 
typedef int FileHandle
 
typedef unsigned char byte_t
 An unsigned 8-bit value. More...
 
typedef unsigned int uint_t
 An alias for unsigned int. More...
 
typedef int32_t time_s_t
 A time expressed in seconds since the epoch (00:00:00, UTC, January 1, 1970). More...
 
typedef int timespan_s_t
 A timespan expressed in seconds. More...
 
typedef int64_t time_ms_t
 A time expressed in milliseconds since the epoch (00:00:00, UTC, January 1, 1970). More...
 
typedef int timespan_ms_t
 A timespan expressed in milliseconds. More...
 
typedef int SocketHandle
 
typedef ThreadLocalBuffer< byte_tThreadLocalByteBuffer
 

Enumerations

enum  Priority {
  PrioLowest, PrioLow, PrioNormal, PrioHigh,
  PrioHighest
}
 Thread and Process priority levels. More...
 
enum  Endianness { BigEndian = 0, LittleEndian = 1 }
 Byte endianness. More...
 
enum  FileType {
  TypeFile, TypeDir, TypeSymLink, TypePipe,
  TypeDevice, TypeOther, TypeUnknown
}
 File types. More...
 
enum  FileOpenMode {
  FileOpenElseCreate, FileOpen, FileCreate, FileTruncate,
  FileTruncateElseCreate
}
 File open modes. More...
 
enum  LockType { LockRead, LockWrite }
 File lock types. More...
 
enum  LogLevel { LogDebug = 1 << 0, LogInfo = 1 << 1, LogWarning = 1 << 2, LogError = 1 << 3 }
 Logging levels. More...
 
enum  NetProtocol { ProtoAny, ProtoTCP, ProtoUDP }
 Network protocol types. More...
 
enum  IOMode { IORead, IOWrite, IOReadWrite }
 Stream I/O modes. More...
 
enum  SeekMode { SeekAbsolute, SeekRelative, SeekEnd }
 Stream seek modes. More...
 

Functions

static void __unhandledExceptionHandler ()
 
static void __unexpectedExceptionHandler ()
 
static int __getGMTOffset ()
 
static struct tm * localtime_r (const time_t *timep, struct tm *result)
 
static void __cleanup_logger_singletons (void)
 
static size_t __bsnputs (char *buf, size_t maxlen, const char *str)
 
static size_t __bsnputsf (char *buf, size_t maxlen, const char *str)
 
static size_t __bvsnprintf (char *buf, size_t maxlen, const char *fmt, va_list vp)
 
static size_t __bsnprintf (char *buf, size_t maxlen, const char *fmt,...)
 
static int copyNameArray (char **src, char *buf, size_t bufsz)
 
static int copyAddrArray (char **src, char *buf, size_t addrsz, size_t bufsz)
 
static struct hostent * copyStructHostent (struct hostent *rhe, struct hostent *result, char *buffer, int buflen)
 
static struct servent * copyStructServent (struct servent *rse, struct servent *result, char *buffer, int buflen)
 
static bool __static_init (void)
 
const TimeSpan operator+ (const TimeSpan &s1, const TimeSpan &s2)
 
const TimeSpan operator+ (const TimeSpan &s1, int64_t s2)
 
const TimeSpan operator+ (int64_t s1, const TimeSpan &s2)
 
const TimeSpan operator- (const TimeSpan &s1, const TimeSpan &s2)
 
const TimeSpan operator- (const TimeSpan &s1, int64_t s2)
 
const TimeSpan operator- (int64_t s1, const TimeSpan &s2)
 
std::ostream & operator<< (std::ostream &stream, const BitSet &bs)
 
bool operator== (const Blob &b1, const Blob &b2)
 
bool operator!= (const Blob &b1, const Blob &b2)
 
bool operator< (const Blob &b1, const Blob &b2)
 
bool operator> (const Blob &b1, const Blob &b2)
 
bool operator<= (const Blob &b1, const Blob &b2)
 
bool operator>= (const Blob &b1, const Blob &b2)
 
std::ostream & operator<< (std::ostream &stream, const Blob &b)
 
bool operator== (char c1, const Char &c2)
 
bool operator!= (char c1, const Char &c2)
 
bool operator< (char c1, const Char &c2)
 
bool operator<= (char c1, const Char &c2)
 
bool operator> (char c1, const Char &c2)
 
bool operator>= (char c1, const Char &c2)
 
bool operator== (char16_t c1, const Char &c2)
 
bool operator!= (char16_t c1, const Char &c2)
 
bool operator< (char16_t c1, const Char &c2)
 
bool operator<= (char16_t c1, const Char &c2)
 
bool operator> (char16_t c1, const Char &c2)
 
bool operator>= (char16_t c1, const Char &c2)
 
const TimeSpan operator- (const DateTime &d1, const DateTime &d2)
 
const DateTime operator- (const DateTime &d, const TimeSpan &ts)
 
const DateTime operator+ (const DateTime &d, const TimeSpan &ts)
 
template<typename T , typename E >
enum_cast (T val)
 Safe enumeration cast. More...
 
template<typename T , typename E >
enum_cast (T val, E defval)
 Safe enumeration cast. More...
 
std::ostream & operator<< (std::ostream &stream, const Exception &ex)
 Write an exception to a stream. More...
 
std::ostream & operator<< (std::ostream &stream, const InetAddress &a)
 
template<typename S , typename T >
numeric_cast (S value)
 A range-checked numeric cast. More...
 
template<typename S , typename T >
numeric_clipping_cast (S value)
 A range-clipping numeric cast. More...
 
template<typename T >
numeric_clip (T value, T min, T max)
 A numeric range-clipping function. More...
 
uint_t operator| (const Permissions &perm, const uint_t rhs)
 
uint_t operator & (const Permissions &perm, const uint_t rhs)
 
template<class T >
void swap (ScopedPtr< T > &a, ScopedPtr< T > &b)
 Swap two ScopedPtr values. More...
 
std::ostream & operator<< (std::ostream &stream, const SocketAddress &a)
 
bool operator== (const String &s1, const String &s2)
 
bool operator== (const String &s1, const char *s2)
 
bool operator== (const char *s1, const String &s2)
 
bool operator!= (const String &s1, const String &s2)
 
bool operator!= (const String &s1, const char *s2)
 
bool operator!= (const char *s1, const String &s2)
 
bool operator< (const String &s1, const String &s2)
 
bool operator< (const String &s1, const char *s2)
 
bool operator< (const char *s1, const String &s2)
 
bool operator> (const String &s1, const String &s2)
 
bool operator> (const String &s1, const char *s2)
 
bool operator> (const char *s1, const String &s2)
 
bool operator<= (const String &s1, const String &s2)
 
bool operator<= (const String &s1, const char *s2)
 
bool operator<= (const char *s1, const String &s2)
 
bool operator>= (const String &s1, const String &s2)
 
bool operator>= (const String &s1, const char *s2)
 
bool operator>= (const char *s1, const String &s2)
 
String operator+ (const char *s1, const String &s2)
 
String operator+ (const Char &c, const String &s)
 
std::ostream & operator<< (std::ostream &stream, const String &s)
 
std::ostream & operator<< (std::ostream &stream, const Variant &v)
 Write a Variant to an output stream. More...
 
std::ostream & operator<< (std::ostream &stream, const Version &v)
 

Variables

static const char * __base64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
 
static int __tuplesPerLine = 19
 
static int __bytesPerLine = __tuplesPerLine * 3
 
static const uint32_t __firstN []
 
static const uint32_t __lastN []
 
static const uint32_t crc32_table []
 
static const uint_t __daysInMonth [] = { 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }
 
static const uint_t __daysInYearAccum [] = { 0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334 }
 
static const uint_t __daysInLeapYearAccum [] = {0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335 }
 
static const int __GMTOffset = __getGMTOffset()
 
static bool disable_cleanup = false
 
static int cleanup_init = atexit(__cleanup_logger_singletons)
 
static const char _formatTokens []
 
static const char _levelTokens []
 
static const char * __protoNames [] = { NULL, "tcp", "udp" }
 
static const int OPCODES_PER_PROGRESS_CALLBACK = 1000
 
static bool __static_init_flag = __static_init()
 
static const char * __unreserved
 
static const size_t ALIGNMENT = 4
 
static const size_t ALIGNMENT = 4
 
class COMMONCPP_API Plugin
 

Typedef Documentation

◆ BufferedByteStream

◆ BufferedCharStream

◆ BufferedStream

◆ BufferedWStream

◆ byte_t

An unsigned 8-bit value.

◆ ByteBuffer

◆ char16_t

A UTF-16 character.

◆ char32_t

A UTF-32 character.

◆ CharBuffer

typedef Buffer<char> CharBuffer

◆ CircularByteBuffer

◆ CircularCharBuffer

◆ FileHandle

typedef int FileHandle

◆ ProcessHandle

typedef pid_t ProcessHandle

◆ ProcessID

typedef pid_t ProcessID

◆ SocketHandle

typedef int SocketHandle

◆ ThreadHandle

typedef pthread_t ThreadHandle

◆ ThreadID

typedef pthread_t ThreadID

◆ ThreadLocalByteBuffer

◆ time_ms_t

A time expressed in milliseconds since the epoch (00:00:00, UTC, January 1, 1970).

◆ time_s_t

A time expressed in seconds since the epoch (00:00:00, UTC, January 1, 1970).

◆ timespan_ms_t

A timespan expressed in milliseconds.

◆ timespan_s_t

A timespan expressed in seconds.

◆ uint_t

An alias for unsigned int.

Enumeration Type Documentation

◆ Endianness

enum Endianness

Byte endianness.

Enumerator
BigEndian 

Big-endian (network byte order).

LittleEndian 

Little-endian.

◆ FileOpenMode

File open modes.

Enumerator
FileOpenElseCreate 

Open the file if it exists, otherwise create the file.

FileOpen 

Open the file if it exists, otherwise fail.

FileCreate 

Create the file if it does not exist, otherwise fail.

FileTruncate 

Open and truncate the file if it exists, otherwise fail.

FileTruncateElseCreate 

Open and truncate the file if it exists, otherwise create the file.

◆ FileType

enum FileType

File types.

Enumerator
TypeFile 

Regular file.

TypeDir 

Directory.

TypeSymLink 

Symbolic link.

TypePipe 

Named pipe.

TypeDevice 

Device file.

TypeOther 

Other filetype.

TypeUnknown 

Unknown filetype.

◆ IOMode

enum IOMode

Stream I/O modes.

Enumerator
IORead 

Read-only mode.

IOWrite 

Write-only mode.

IOReadWrite 

Read/write mode.

◆ LockType

enum LockType

File lock types.

Enumerator
LockRead 

Lock for reading.

LockWrite 

Lock for writing.

◆ LogLevel

enum LogLevel

Logging levels.

Enumerator
LogDebug 

Debugging messages.

LogInfo 

Informational messages.

LogWarning 

Warning messages.

LogError 

Error messages.

◆ NetProtocol

Network protocol types.

Enumerator
ProtoAny 

Any (unspecified) protocol.

ProtoTCP 

TCP protocol.

ProtoUDP 

UDP protocol.

◆ Priority

enum Priority

Thread and Process priority levels.

Enumerator
PrioLowest 

Lowest priority.

PrioLow 

Low priority.

PrioNormal 

Normal (default) priority.

PrioHigh 

High priority.

PrioHighest 

Highest priority.

◆ SeekMode

enum SeekMode

Stream seek modes.

Enumerator
SeekAbsolute 

Seek from the beginning of the stream.

SeekRelative 

Seek from the current stream position.

SeekEnd 

Seek backward from the end of the stream.

Function Documentation

◆ __bsnprintf()

static size_t ccxx::__bsnprintf ( char *  buf,
size_t  maxlen,
const char *  fmt,
  ... 
)
static

◆ __bsnputs()

static size_t ccxx::__bsnputs ( char *  buf,
size_t  maxlen,
const char *  str 
)
static

◆ __bsnputsf()

static size_t ccxx::__bsnputsf ( char *  buf,
size_t  maxlen,
const char *  str 
)
static

◆ __bvsnprintf()

static size_t ccxx::__bvsnprintf ( char *  buf,
size_t  maxlen,
const char *  fmt,
va_list  vp 
)
static

◆ __cleanup_logger_singletons()

static void ccxx::__cleanup_logger_singletons ( void  )
static

◆ __getGMTOffset()

static int ccxx::__getGMTOffset ( )
static

◆ __static_init()

static bool ccxx::__static_init ( void  )
static

◆ __unexpectedExceptionHandler()

static void ccxx::__unexpectedExceptionHandler ( )
static

◆ __unhandledExceptionHandler()

static void ccxx::__unhandledExceptionHandler ( )
static

◆ copyAddrArray()

static int ccxx::copyAddrArray ( char **  src,
char *  buf,
size_t  addrsz,
size_t  bufsz 
)
static

◆ copyNameArray()

static int ccxx::copyNameArray ( char **  src,
char *  buf,
size_t  bufsz 
)
static

◆ copyStructHostent()

static struct hostent* ccxx::copyStructHostent ( struct hostent *  rhe,
struct hostent *  result,
char *  buffer,
int  buflen 
)
static

◆ copyStructServent()

static struct servent* ccxx::copyStructServent ( struct servent *  rse,
struct servent *  result,
char *  buffer,
int  buflen 
)
static

◆ enum_cast() [1/2]

E ccxx::enum_cast ( val)

Safe enumeration cast.

Casts a value of type T to an enumeration of type E, ensuring that the value returned is a valid one for E. It is assumed that the values in the enumeration E are sequential integers, that is, that there are no "gaps" in the range.

Parameters
valThe value to cast.
Returns
The value cast to the enumeration type E. If the value is outside the allowed range for E, the default value for E is returned, as specified by the specialization of EnumTraits::defVal().

◆ enum_cast() [2/2]

E ccxx::enum_cast ( val,
defval 
)

Safe enumeration cast.

Casts a value of type T to an enumeration of type E, ensuring that the value returned is a valid one for E. It is assumed that the values in the enumeration E are sequential integers, that is, that there are no "gaps" in the range.

Parameters
valThe value to cast.
defvalThe default enumeration value to return, if the passed-in value is not a valid one for the enumeration.
Returns
The value cast to the enumeration type E. If the value is outside the allowed range for E, defVal is returned.

◆ localtime_r()

static struct tm* ccxx::localtime_r ( const time_t *  timep,
struct tm *  result 
)
static

◆ numeric_cast()

T ccxx::numeric_cast ( value)
inline

A range-checked numeric cast.

If the value is outside the range of the target type, an exception is thrown.

Parameters
valueThe value to cast.
Returns
The value cast to the target type.
Exceptions
OutOfBoundsExceptionIf the value is outside the range of the target type.

◆ numeric_clip()

T ccxx::numeric_clip ( value,
min,
max 
)
inline

A numeric range-clipping function.

If the value is outside the specified range, it is clipped.

Parameters
valueThe value to cast.
minThe lower bound of the allowed range.
maxThe upper bound of the allowed range.
Returns
The (possibly clipped) value.

◆ numeric_clipping_cast()

T ccxx::numeric_clipping_cast ( value)
inline

A range-clipping numeric cast.

If the value is outside the range of the target type, it is clipped.

Parameters
valueThe value to cast.
Returns
The value cast to the target type.

◆ operator &()

uint_t ccxx::operator& ( const Permissions perm,
const uint_t  rhs 
)
inline

◆ operator!=() [1/6]

bool ccxx::operator!= ( char  c1,
const Char c2 
)
inline

◆ operator!=() [2/6]

bool ccxx::operator!= ( char16_t  c1,
const Char c2 
)
inline

◆ operator!=() [3/6]

bool ccxx::operator!= ( const Blob b1,
const Blob b2 
)
inline

◆ operator!=() [4/6]

bool ccxx::operator!= ( const String s1,
const String s2 
)
inline

◆ operator!=() [5/6]

bool ccxx::operator!= ( const String s1,
const char *  s2 
)
inline

◆ operator!=() [6/6]

bool ccxx::operator!= ( const char *  s1,
const String s2 
)
inline

◆ operator+() [1/6]

const DateTime ccxx::operator+ ( const DateTime d,
const TimeSpan ts 
)
inline

◆ operator+() [2/6]

const TimeSpan ccxx::operator+ ( const TimeSpan s1,
const TimeSpan s2 
)

◆ operator+() [3/6]

const TimeSpan ccxx::operator+ ( const TimeSpan s1,
int64_t  s2 
)

◆ operator+() [4/6]

const TimeSpan ccxx::operator+ ( int64_t  s1,
const TimeSpan s2 
)

◆ operator+() [5/6]

String ccxx::operator+ ( const char *  s1,
const String s2 
)
inline

◆ operator+() [6/6]

String ccxx::operator+ ( const Char c,
const String s 
)
inline

◆ operator-() [1/5]

const TimeSpan ccxx::operator- ( const DateTime d1,
const DateTime d2 
)
inline

◆ operator-() [2/5]

const DateTime ccxx::operator- ( const DateTime d,
const TimeSpan ts 
)
inline

◆ operator-() [3/5]

const TimeSpan ccxx::operator- ( const TimeSpan s1,
const TimeSpan s2 
)

◆ operator-() [4/5]

const TimeSpan ccxx::operator- ( const TimeSpan s1,
int64_t  s2 
)

◆ operator-() [5/5]

const TimeSpan ccxx::operator- ( int64_t  s1,
const TimeSpan s2 
)

◆ operator<() [1/6]

bool ccxx::operator< ( char  c1,
const Char c2 
)
inline

◆ operator<() [2/6]

bool ccxx::operator< ( char16_t  c1,
const Char c2 
)
inline

◆ operator<() [3/6]

bool ccxx::operator< ( const Blob b1,
const Blob b2 
)
inline

◆ operator<() [4/6]

bool ccxx::operator< ( const String s1,
const String s2 
)
inline

◆ operator<() [5/6]

bool ccxx::operator< ( const String s1,
const char *  s2 
)
inline

◆ operator<() [6/6]

bool ccxx::operator< ( const char *  s1,
const String s2 
)
inline

◆ operator<<() [1/8]

std::ostream& ccxx::operator<< ( std::ostream &  stream,
const Exception ex 
)
inline

Write an exception to a stream.

◆ operator<<() [2/8]

std::ostream& ccxx::operator<< ( std::ostream &  stream,
const SocketAddress a 
)
inline

◆ operator<<() [3/8]

std::ostream& ccxx::operator<< ( std::ostream &  stream,
const Version v 
)
inline

◆ operator<<() [4/8]

std::ostream& ccxx::operator<< ( std::ostream &  stream,
const InetAddress a 
)
inline

◆ operator<<() [5/8]

std::ostream& ccxx::operator<< ( std::ostream &  stream,
const Blob b 
)
inline

◆ operator<<() [6/8]

std::ostream& ccxx::operator<< ( std::ostream &  stream,
const BitSet bs 
)
inline

◆ operator<<() [7/8]

std::ostream& ccxx::operator<< ( std::ostream &  stream,
const Variant v 
)
inline

Write a Variant to an output stream.

Parameters
streamThe stream to write to.
vThe variant to write.
Returns
The stream.

◆ operator<<() [8/8]

std::ostream& ccxx::operator<< ( std::ostream &  stream,
const String s 
)
inline

◆ operator<=() [1/6]

bool ccxx::operator<= ( char  c1,
const Char c2 
)
inline

◆ operator<=() [2/6]

bool ccxx::operator<= ( char16_t  c1,
const Char c2 
)
inline

◆ operator<=() [3/6]

bool ccxx::operator<= ( const Blob b1,
const Blob b2 
)
inline

◆ operator<=() [4/6]

bool ccxx::operator<= ( const String s1,
const String s2 
)
inline

◆ operator<=() [5/6]

bool ccxx::operator<= ( const String s1,
const char *  s2 
)
inline

◆ operator<=() [6/6]

bool ccxx::operator<= ( const char *  s1,
const String s2 
)
inline

◆ operator==() [1/6]

bool ccxx::operator== ( char  c1,
const Char c2 
)
inline

◆ operator==() [2/6]

bool ccxx::operator== ( char16_t  c1,
const Char c2 
)
inline

◆ operator==() [3/6]

bool ccxx::operator== ( const Blob b1,
const Blob b2 
)
inline

◆ operator==() [4/6]

bool ccxx::operator== ( const String s1,
const String s2 
)
inline

◆ operator==() [5/6]

bool ccxx::operator== ( const String s1,
const char *  s2 
)
inline

◆ operator==() [6/6]

bool ccxx::operator== ( const char *  s1,
const String s2 
)
inline

◆ operator>() [1/6]

bool ccxx::operator> ( char  c1,
const Char c2 
)
inline

◆ operator>() [2/6]

bool ccxx::operator> ( char16_t  c1,
const Char c2 
)
inline

◆ operator>() [3/6]

bool ccxx::operator> ( const Blob b1,
const Blob b2 
)
inline

◆ operator>() [4/6]

bool ccxx::operator> ( const String s1,
const String s2 
)
inline

◆ operator>() [5/6]

bool ccxx::operator> ( const String s1,
const char *  s2 
)
inline

◆ operator>() [6/6]

bool ccxx::operator> ( const char *  s1,
const String s2 
)
inline

◆ operator>=() [1/6]

bool ccxx::operator>= ( char  c1,
const Char c2 
)
inline

◆ operator>=() [2/6]

bool ccxx::operator>= ( char16_t  c1,
const Char c2 
)
inline

◆ operator>=() [3/6]

bool ccxx::operator>= ( const Blob b1,
const Blob b2 
)
inline

◆ operator>=() [4/6]

bool ccxx::operator>= ( const String s1,
const String s2 
)
inline

◆ operator>=() [5/6]

bool ccxx::operator>= ( const String s1,
const char *  s2 
)
inline

◆ operator>=() [6/6]

bool ccxx::operator>= ( const char *  s1,
const String s2 
)
inline

◆ operator|()

uint_t ccxx::operator| ( const Permissions perm,
const uint_t  rhs 
)
inline

◆ swap()

void ccxx::swap ( ScopedPtr< T > &  a,
ScopedPtr< T > &  b 
)
inline

Swap two ScopedPtr values.

Variable Documentation

◆ __base64

const char* __base64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
static

◆ __bytesPerLine

int __bytesPerLine = __tuplesPerLine * 3
static

◆ __daysInLeapYearAccum

const uint_t __daysInLeapYearAccum[] = {0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335 }
static

◆ __daysInMonth

const uint_t __daysInMonth[] = { 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }
static

◆ __daysInYearAccum

const uint_t __daysInYearAccum[] = { 0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334 }
static

◆ __firstN

const uint32_t __firstN[]
static
Initial value:
= { 0x00000000U,
0x00000001U, 0x00000003U, 0x00000007U, 0x0000000FU,
0x0000001FU, 0x0000003FU, 0x0000007FU, 0x000000FFU,
0x000001FFU, 0x000003FFU, 0x000007FFU, 0x00000FFFU,
0x00001FFFU, 0x00003FFFU, 0x00007FFFU, 0x0000FFFFU,
0x0001FFFFU, 0x0003FFFFU, 0x0007FFFFU, 0x000FFFFFU,
0x001FFFFFU, 0x003FFFFFU, 0x007FFFFFU, 0x00FFFFFFU,
0x01FFFFFFU, 0x03FFFFFFU, 0x07FFFFFFU, 0x0FFFFFFFU,
0x1FFFFFFFU, 0x3FFFFFFFU, 0x7FFFFFFFU, 0xFFFFFFFFU }

◆ __GMTOffset

const int __GMTOffset = __getGMTOffset()
static

◆ __lastN

const uint32_t __lastN[]
static
Initial value:
= { 0x00000000U,
0x80000000U, 0xC0000000U, 0xE0000000U, 0xF0000000U,
0xF8000000U, 0xFC000000U, 0xFE000000U, 0xFF000000U,
0xFF800000U, 0xFFC00000U, 0xFFE00000U, 0xFFF00000U,
0xFFF80000U, 0xFFFC0000U, 0xFFFE0000U, 0xFFFF0000U,
0xFFFF8000U, 0xFFFFC000U, 0xFFFFE000U, 0xFFFFF000U,
0xFFFFF800U, 0xFFFFFC00U, 0xFFFFFE00U, 0xFFFFFF00U,
0xFFFFFF80U, 0xFFFFFFC0U, 0xFFFFFFE0U, 0xFFFFFFF0U,
0xFFFFFFF8U, 0xFFFFFFFCU, 0xFFFFFFFEU, 0xFFFFFFFFU }

◆ __protoNames

const char* __protoNames[] = { NULL, "tcp", "udp" }
static

◆ __static_init_flag

bool __static_init_flag = __static_init()
static

◆ __tuplesPerLine

int __tuplesPerLine = 19
static

◆ __unreserved

const char* __unreserved
static
Initial value:
= "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
"abcdefghijklmnopqrstuvwxyz" "0123456789" "-+_.~/"

◆ _formatTokens

const char _formatTokens[]
static
Initial value:
= { '=', 'T', 't', 'D', 'd', 'F', 'L', 'm',
'h', 'p', 'o', 'a', 'v', 'u', 'H', 'l',
'%', '*', '_', '#', '-', '0', '1', '2',
'3', '4', '5', '6', '7', '8', '.', '@',
'n', 'A' }

◆ _levelTokens

const char _levelTokens[]
static
Initial value:
= { NUL, 'D', 'I', NUL, 'W', NUL, NUL, NUL,
'E' }
#define NUL
The NUL character (ASCII value 0).
Definition: Common.h++:240

◆ ALIGNMENT [1/2]

const size_t ALIGNMENT = 4
static

◆ ALIGNMENT [2/2]

const size_t ALIGNMENT = 4
static

◆ cleanup_init

int cleanup_init = atexit(__cleanup_logger_singletons)
static

◆ crc32_table

const uint32_t crc32_table[]
static

◆ disable_cleanup

bool disable_cleanup = false
static

◆ OPCODES_PER_PROGRESS_CALLBACK

const int OPCODES_PER_PROGRESS_CALLBACK = 1000
static

◆ Plugin