Developer Documentation
RAVL, Recognition And Vision Library
USER HOME PAGE CLASS LIST CONTENTS
Ravl - Core - IO - Streams - StrIStreamC
 

  PUBLIC
StrIStreamC::StrIStreamC(void)
StrIStreamC::StrIStreamC(const StringC &)
StrIStreamC::String(void)
IStreamC::Unget(StringC)
IStreamC::Unget(const char *,int)
IStreamC::CopyTo(OStreamC &,IntT)
IStreamC::is(void)
IStreamC::is(void) const
IStreamC::operator istream &(void)
IStreamC::operator const istream &(void) const
IStreamC::read(char *,streamsize)
IStreamC::get(char &)
IStreamC::get(void)
IStreamC::get(char *,int)
IStreamC::getline(char *,int)
IStreamC::gcount(void)
IStreamC::operator >>(DataT &)
IStreamC::operator >>(char *)
IStreamC::Tell(void) const
IStreamC::Seek(streampos)
IStreamC::tellg(void) const
IStreamC::seekg(streampos)
IStreamC::seekg(streampos,SeekDirT)
IStreamC::IsEndOfStream(void)
IStreamC::GetChar(void)
IStreamC::SkipWhiteSpace(void)
IStreamC::Skip(const char *)
IStreamC::SkipTo(const StringC &)
IStreamC::SkipTo(char)
IStreamC::ClipTo(char)
IStreamC::ClipTo(const StringC &)
IStreamC::ClipWord(const char *,bool)
StreamBaseC::Name(void) const
StreamBaseC::IsOpen(void) const
StreamBaseC::good(void) const
StreamBaseC::bad(void) const
StreamBaseC::eof(void) const
StreamBaseC::fail(void) const
StreamBaseC::operator !(void) const
StreamBaseC::operator void *(void) const
StreamBaseC::DiagnoseStream(ostream &)
StreamBaseC::Close(void)
StreamBaseC::Init(istream *,StringC,bool)
StreamBaseC::Init(ostream *,StringC,bool)
StreamBaseC::buf(void)
StreamBaseC::buf(void) const
HandleRefCounterC::SetDestructionOp(const TriggerC &)
HandleRefCounterC::References(void) const
RCHandleC::operator =(const RCHandleC &)
RCHandleC::DeepCopy(UIntT) const
RCHandleC::operator ==(const RCHandleC &) const
RCHandleC::operator !=(const RCHandleC &) const
RCHandleC::Hash(void) const
RCHandleC::IsValid(void) const
RCHandleC::Invalidate(void)
RCHandleC::IsHandleType(const DT &) const
RCHandleC::CheckHandleType(const DT &) const
RCHandleC::Body(void)
RCHandleC::Body(void) const
RCHandleC::References(void) const
RCHandleC::operator <<(ostream &,const RCHandleC &)
RCHandleC::operator >>(istream &,RCHandleC &)

   StrIStreamC   
 
Input stream from memory.
 
include "Ravl/StrStream.hh"
Created:25/02/1999 
Source file:Ravl/Core/Base/StrStream.hh
User Level:Normal
Library:RavlCore
In Scope:RavlN

Comments:
Wraps the standard library istrstream class.

Parent Classes: Variables:
istringstream * iss;
Output string stream.

StringC buff;

Methods:
StrIStreamC()
Default constructor

StrIStreamC(const StringC & dat)
Constructor.

StringC & String()
Get string used as buffer.

#include "Ravl/Stream.hh"
void Unget(StringC text)
Put string pack. (Puts a '\n')

void Unget(const char * dat,int len)
Put string pack.

IntT CopyTo(OStreamC & out,IntT maxChars = - 1)
Copy stream to output.

istream & is()
Access input stream.

const istream & is() const
Access input stream.

operator istream &()
Converter.

operator const istream &() const
Converter.

istream & read(char * d,streamsize n)
read data.
istream compatable function.

istream & get(char & ch)
Get character.
istream compatable function.

char get()
Get character.
istream compatable function.

istream & get(char * buff,int buffsize)
Read in a line.
istream compatable function.

istream & getline(char * buff,int buffsize)
Read in a line.
istream compatable function.

streamsize gcount()
Get number of character read in last operation.
istream compatable function.

istream & operator >>(DataT & dat)

istream & operator >>(char * dat)

streampos Tell() const
Where are we in the stream.

void Seek(streampos to)
Goto a position in the stream.

streampos tellg() const
Where are we in the stream.
istream compatable function.

istream & seekg(streampos to)
Goto a position in the stream.
istream compatable function.

istream & seekg(streampos to,SeekDirT dir)
Goto a position in the stream.
istream compatable.

bool IsEndOfStream()
Test if its the end of the stream is comming up...
Maybe there's a better way ?

Parsing Functions.

Some methods to help parse text streams.
char GetChar()
Get next character.
This will throw an ExceptionEndOfStreamC if the end of the input stream is found.

char SkipWhiteSpace()
Skip white space characters.
returns the first non-white space character found.

This will throw an ExceptionEndOfStreamC if the end of the input stream is found.


bool Skip(const char * delim = " \n\t\r")
Skip all 'delim' characters.
Leaves stream at first character this is not one of those listed in 'delim'. If end of stream is found before returns false.

bool SkipTo(const StringC & endStr)
Skip through stream until endStr is found.
this leaves the stream positioned at the first character after the string.

returns false if the end of the stream is found first.


bool SkipTo(char let)
Skip through stream until 'let' is found.
returns false if the end of the stream is found first.

StringC ClipTo(char let)
Return all characters before let.
the 'let' character is discarded.

If the end of stream is found, all data found upto that point is returned.


StringC ClipTo(const StringC & endStr)
Return all characters before 'endStr'.
this leaves the stream positioned at the first character after the string.

If the end of stream is found, all data found upto that point is returned.


StringC ClipWord(const char * delim = " \n\t\r",bool initalSkipDelim = false)
Clip word until one of 'delim' characters are found.

const StringC & Name() const
Returns the name of the stream.

bool IsOpen() const
Test if this stream is open.

bool good() const
Is stream good ?

bool bad() const
Is stream corrupted ?

bool eof() const
End of file ?

bool fail() const
Operation failed ?

bool operator !() const
Not failed ?

operator void *() const
Ok ?

bool DiagnoseStream(ostream & out)
Print diagnostic message about the streams state to out.

bool Close()
Close this stream.
After this is called no further IO should be attempted!

bool Init(istream * ns,StringC afilename,bool nDelOnClose = true)
Setup
This should only be called on Stream's constructed with the default constructor!

bool Init(ostream * ns,StringC afilename,bool nDelOnClose = true)
Setup
This should only be called on Stream's constructed with the default constructor!

ios & buf()
Access handle.

const ios & buf() const
Access handle.

#include "Ravl/HandleRefCounter.hh"
void SetDestructionOp(const TriggerC & ntrig)
Set trigger to call on delete.

UIntT References() const
Returns the number of references to this object.

#include "Ravl/RefCounter.hh"
const RCHandleC<HandleRefCounterBodyC> & operator =(const RCHandleC<HandleRefCounterBodyC> & oth)
Assign handle.

RCHandleC<HandleRefCounterBodyC> DeepCopy(UIntT levels = ((UIntT))) const
Do a deep copy of the object.

bool operator ==(const RCHandleC<HandleRefCounterBodyC> & oth) const
Are handles to the same object ?

bool operator !=(const RCHandleC<HandleRefCounterBodyC> & oth) const
Are handles to different objects ?

UIntT Hash() const
Default hash function.
This hashes on the address of the body.

bool IsValid() const
Test if this is a valid handle.

void Invalidate()
Invalidate this handle.
Unattaches the body from the handle.

bool IsHandleType(const DT &) const
Is handle of given type ?

void CheckHandleType(const DT & dummy) const
Check handle type. Throw an expception if not.

HandleRefCounterBodyC & Body()
Access body of object.

const HandleRefCounterBodyC & Body() const
Constant access to body of object.

UIntT References() const
Find the number of references to the body of this object.

ostream & operator <<(ostream & strm,const RCHandleC<HandleRefCounterBodyC> & obj)

istream & operator >>(istream & strm,RCHandleC<HandleRefCounterBodyC> & obj)


Maintainer:Charles Galambos, Created: 25/02/1999, Documentation by CxxDoc: Tue Aug 13 09:59:30 2002