Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

CharsRep Class Reference

Representation class for Chars. More...

#include <Chars.h>

Inheritance diagram for CharsRep::

RefCounter List of all members.

Public Methods

 CharsRep ()
 Gives empty string.

 CharsRep (const char *s)
 Creates a string from 's'.

 CharsRep (char c)
 Creates a string from 'c'.

 CharsRep (const CharsRep &CR)
 Copy constructor.

 CharsRep (int num)
 Creates an empty string of length 'num'.

virtual ~CharsRep ()
int len () const
 Returns length of the string.

const char* getChars () const
 Returns string as a pointer to char.

char& ref (int i)
 for reference access.

char val (int i) const
 for value access.

CharsRep* clone () const
void concat (const char *, int len)
 Concatenate string of length 'len'.

void readFrom (istream &istr)
 Read string from a stream.

virtual void write (ostream &ostr) const
 IPC tools:.

virtual void read (istream &istr)
 IPC tools:.


Private Methods

CharsRep operator= (const CharsRep &)

Private Attributes

int length
 < Prohibited//////////////////////////////////////////////////////////////////////.

char* theChars
char special [2]

Detailed Description

Representation class for Chars.

Definition at line 50 of file Chars.h.


Constructor & Destructor Documentation

CharsRep::CharsRep ( )
 

Gives empty string.

Referenced by clone().

CharsRep::CharsRep ( const char * s )
 

Creates a string from 's'.

CharsRep::CharsRep ( char c )
 

Creates a string from 'c'.

CharsRep::CharsRep ( const CharsRep & CR )
 

Copy constructor.

CharsRep::CharsRep ( int num )
 

Creates an empty string of length 'num'.

virtual CharsRep::~CharsRep ( ) [virtual]
 


Member Function Documentation

int CharsRep::len ( ) const [inline]
 

Returns length of the string.

Definition at line 78 of file Chars.h.

const char * CharsRep::getChars ( ) const [inline]
 

Returns string as a pointer to char.

Definition at line 80 of file Chars.h.

char & CharsRep::ref ( int i )
 

for reference access.

char CharsRep::val ( int i ) const
 

for value access.

CharsRep * CharsRep::clone ( ) const [inline]
 

Definition at line 94 of file Chars.h.

void CharsRep::concat ( const char *,
int len )
 

Concatenate string of length 'len'.

void CharsRep::readFrom ( istream & istr )
 

Read string from a stream.

void CharsRep::write ( ostream & ostr ) const [virtual]
 

IPC tools:.

void CharsRep::read ( istream & istr ) [virtual]
 

IPC tools:.

CharsRep CharsRep::operator= ( const CharsRep & ) [private]
 


Member Data Documentation

int CharsRep::length [private]
 

< Prohibited//////////////////////////////////////////////////////////////////////.

Definition at line 126 of file Chars.h.

char* CharsRep::theChars [private]
 

Definition at line 128 of file Chars.h.

char CharsRep::special[2] [private]
 

Definition at line 130 of file Chars.h.


The documentation for this class was generated from the following file:
Generated at Tue Jun 19 09:49:48 2001 for Magnus Classes by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001