Views
Foundation Package API Reference Guide
Product Documentation:
Views Documentation Home
Classes | Functions
string.h File Reference
#include <string>
#include <ilog/macros.h>
#include <ilog/iostream.h>
#include <stddef.h>

Classes

class  IlString
 Manages strings in single or multi-bytes. More...
 

Functions

IlBoolean ILOG_EXPORTED operator!= (const char *strLeft, const IlString &strRight)
 Not equal operator. More...
 
IlBoolean ILOG_EXPORTED operator!= (const IlString &strLeft, const char *strRight)
 Not equal operator. More...
 
IlString ILOG_EXPORTED operator+ (const char *strLeft, const IlString &strRight)
 Concatenation operator. More...
 
IlString operator+ (const IlString &string1, const IlString &string2)
 Concatenation operator. More...
 
IlString ILOG_EXPORTED operator+ (const IlString &strLeft, const char *strRight)
 Concatenation operator. More...
 
IlStringoperator<< (IlString &string, const char *cstring)
 Append operator. More...
 
IlStringoperator<< (IlString &string1, const IlString &string2)
 Append operator. More...
 
std::ostream & operator<< (std::ostream &ostr, const IlString &string)
 Writes an IlString to an output stream. More...
 
IlBoolean ILOG_EXPORTED operator== (const char *strLeft, const IlString &strRight)
 Equality operator. More...
 
IlBoolean ILOG_EXPORTED operator== (const IlString &strLeft, const char *strRight)
 Equality operator. More...
 
std::istream & operator>> (std::istream &istr, IlString &string)
 Reads an IlString from an input stream. More...
 

Detailed Description

Library: ilog
Declaration of the IlString class and some utilities.

Function Documentation

◆ operator!=() [1/2]

IlBoolean ILOG_EXPORTED operator!= ( const char *  strLeft,
const IlString strRight 
)

Not equal operator.

Parameters
strLeftThe left char*.
strRightThe right IlString.
Returns
IlTrue when the strings are not equal and IlFalse otherwise.

◆ operator!=() [2/2]

IlBoolean ILOG_EXPORTED operator!= ( const IlString strLeft,
const char *  strRight 
)

Not equal operator.

Parameters
strLeftThe left IlString.
strRightThe right char*.
Returns
IlTrue when the strings are not equal and IlFalse otherwise.

◆ operator+() [1/3]

IlString ILOG_EXPORTED operator+ ( const char *  strLeft,
const IlString strRight 
)

Concatenation operator.

Parameters
strLeftThe left char*.
strRightThe right IlString.
Returns
The resulting IlString.

◆ operator+() [2/3]

IlString operator+ ( const IlString string1,
const IlString string2 
)

Concatenation operator.

This operator concatenates two IlString objects into a new one.

Example:

Parameters
string1The head IlString.
string2The tail IlString.
Returns
The resulting string.
See also
IlString::operator+=(), IlString::catenate(), operator<<(IlString&, const IlString&), operator<<(IlString&, const char*).

◆ operator+() [3/3]

IlString ILOG_EXPORTED operator+ ( const IlString strLeft,
const char *  strRight 
)

Concatenation operator.

Parameters
strLeftThe left IlString.
strRightThe right char*.
Returns
The resulting IlString.

◆ operator<<() [1/3]

IlString& operator<< ( IlString string,
const char *  cstring 
)

Append operator.

This operator appends a C-style string to an IlString.

Example:

Parameters
stringThe source IlString where cstring is appended.
cstringA null-terminated C-style string.
Returns
The resulting string.
See also
IlString::operator+=(const IlString&), IlString::catenate(), operator+(const IlString&, const IlString&), operator<<(IlString&, const IlString&).

◆ operator<<() [2/3]

IlString& operator<< ( IlString string1,
const IlString string2 
)

Append operator.

This operator appends an IlString to another IlString.

Example:

Parameters
string1The source IlString where string2 is appended.
string2The string that is appended to string1.
Returns
The resulting string.
See also
IlString::catenate(), operator<<(IlString&, const char*).

◆ operator<<() [3/3]

std::ostream& operator<< ( std::ostream &  ostr,
const IlString string 
)

Writes an IlString to an output stream.

Parameters
ostrThe output stream to write to.
stringThe string that is written.
Returns
The given output stream, ostr.
See also
IlString::writeQuoted(), operator>>(std::istream&, IlString&).

◆ operator==() [1/2]

IlBoolean ILOG_EXPORTED operator== ( const char *  strLeft,
const IlString strRight 
)

Equality operator.

Parameters
strLeftThe left char*.
strRightThe right IlString.
Returns
IlTrue when the strings are equal and IlFalse otherwise.

◆ operator==() [2/2]

IlBoolean ILOG_EXPORTED operator== ( const IlString strLeft,
const char *  strRight 
)

Equality operator.

Parameters
strLeftThe left IlString.
strRightThe right char*.
Returns
IlTrue when the strings are equal and IlFalse otherwise.

◆ operator>>()

std::istream& operator>> ( std::istream &  istr,
IlString string 
)

Reads an IlString from an input stream.

Parameters
istrThe input stream to read from.
stringThe string where the stream content is read.
Returns
The given input stream, istr.
See also
IlString::readQuoted(std::istream&), operator<<(std::ostream&, const IlString&).