Gel2D - The free/open source game creation suite

Public Member Functions
gel::GelCString Class Reference

Classic C style string abstraction. More...

#include <gelCString.h>

List of all members.

Public Member Functions

 GelCString ()
 Default constructor.
 GelCString (const GelCString &cstring)
 Copy constructor.
 GelCString (const char *str)
 C string constructor.
 ~GelCString ()
 Destructor.
void append (const char *str)
void append (const char ch)
int getLength () const
 Gets the number of characters in the string.
void resize (int size)
 Resizes the string's length.
char * getData ()
 Returns a pointer to the character string. */.
const char * getData () const
 Returns a const pointer to the character string. */.
GelCStringoperator= (const GelCString &s)
GelCStringoperator= (const char *s)
GelCStringoperator+= (const char *s)
GelCStringoperator+= (const char c)
char & operator[] (int i)
const char & operator[] (int i) const
 operator const char * () const

Detailed Description

Classic C style string abstraction.

This class currently serves as an intermediary between GelString and char* strings.
It's exact structure and role is still a little uncertain.


Constructor & Destructor Documentation

gel::GelCString::GelCString ( )

Default constructor.

gel::GelCString::GelCString ( const GelCString cstring)

Copy constructor.

gel::GelCString::GelCString ( const char *  str)

C string constructor.

Parameters:
str: An 8-bit C string.
gel::GelCString::~GelCString ( ) [inline]

Destructor.


Member Function Documentation

void gel::GelCString::append ( const char *  str)
void gel::GelCString::append ( const char  ch)
int gel::GelCString::getLength ( ) const [inline]

Gets the number of characters in the string.

Returns:
The length of the string.
void gel::GelCString::resize ( int  size)

Resizes the string's length.

Parameters:
size: The new length of the string.
char* gel::GelCString::getData ( ) [inline]

Returns a pointer to the character string. */.

const char* gel::GelCString::getData ( ) const [inline]

Returns a const pointer to the character string. */.

GelCString& gel::GelCString::operator= ( const GelCString s)
GelCString& gel::GelCString::operator= ( const char *  s)
GelCString& gel::GelCString::operator+= ( const char *  s) [inline]
GelCString& gel::GelCString::operator+= ( const char  c) [inline]
char& gel::GelCString::operator[] ( int  i) [inline]
const char& gel::GelCString::operator[] ( int  i) const [inline]
gel::GelCString::operator const char * ( ) const [inline]

The documentation for this class was generated from the following file: