OpenFOAM logo
The Open Source CFD Toolbox
  Source Guide OpenCFD Solutions Contact OpenFOAM

ISstream Class Reference

Generic input stream. More...

Inheritance diagram for ISstream:
Collaboration diagram for ISstream:

List of all members.


Public Member Functions

 ISstream (istream &is, const string &name, streamFormat format=ASCII, versionNumber version=currentVersion, compressionType compression=UNCOMPRESSED)
 Construct as wrapper around istream.
virtual ~ISstream ()
virtual const fileNamename () const
 Return the name of the stream.
virtual fileNamename ()
 Return non-const access to the name of the stream.
virtual ios_base::fmtflags flags () const
 Return flags of output stream.
ISstreamget (char &)
 Raw, low-level get character function.
ISstreamgetLine (string &)
 Raw, low-level getline into a string function.
ISstreamputback (const char &)
 Raw, low-level putback character function.
virtual Istreamread (token &)
 Return next token from stream.
virtual Istreamread (char &)
 Read a character.
virtual Istreamread (word &)
 Read a word.
virtual Istreamread (string &)
 Read a string (including enclosing double-quotes).
virtual Istreamread (label &)
 Read a label.
virtual Istreamread (floatScalar &)
 Read a floatScalar.
virtual Istreamread (doubleScalar &)
 Read a doubleScalar.
virtual Istreamread (char *, std::streamsize)
 Read binary block.
virtual Istreamrewind ()
 Rewind and return the stream so that it may be read again.
virtual ios_base::fmtflags flags (const ios_base::fmtflags flags)
 Set flags of output stream.
virtual void print (Ostream &) const
 Print description of IOstream to Ostream.

Protected Member Functions

istream & stream ()
 Return the stream reference.
const istream & stream () const
 Return the const stream reference.

Detailed Description

Generic input stream.

Source files

Definition at line 48 of file ISstream.H.


Constructor & Destructor Documentation

ISstream ( istream &  is,
const string name,
streamFormat  format = ASCII,
versionNumber  version = currentVersion,
compressionType  compression = UNCOMPRESSED 
) [inline]

Construct as wrapper around istream.

Definition at line 23 of file ISstreamI.H.

References IOstream::setGood(), and IOstream::setOpened().

Here is the call graph for this function:

virtual ~ISstream (  )  [inline, virtual]

Definition at line 103 of file ISstream.H.


Member Function Documentation

istream& stream (  )  [inline, protected]

Return the stream reference.

Definition at line 74 of file ISstream.H.

Referenced by IStringStream::str().

Here is the caller graph for this function:

const istream& stream (  )  const [inline, protected]

Return the const stream reference.

Definition at line 80 of file ISstream.H.

virtual const fileName& name (  )  const [inline, virtual]

Return the name of the stream.

Useful for Fstream to return the filename

Reimplemented from IOstream.

Reimplemented in IFstream.

Definition at line 115 of file ISstream.H.

Referenced by OStringStream::print(), and OSstream::print().

Here is the caller graph for this function:

virtual fileName& name (  )  [inline, virtual]

Return non-const access to the name of the stream.

Useful to alter the stream name

Reimplemented from IOstream.

Reimplemented in IFstream.

Definition at line 124 of file ISstream.H.

std::ios_base::fmtflags flags (  )  const [virtual]

Return flags of output stream.

Implements IOstream.

Definition at line 515 of file ISstream.C.

Foam::ISstream & get ( char &  c  )  [inline]

Raw, low-level get character function.

Definition at line 49 of file ISstreamI.H.

References IOstream::setState().

Referenced by Foam::readHexLabel().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::ISstream & getLine ( string s  )  [inline]

Raw, low-level getline into a string function.

Definition at line 63 of file ISstreamI.H.

References IOstream::lineNumber_.

Referenced by Foam::parseNASCoord(), AC3DsurfaceFormatCore::readCmd(), and STARCDsurfaceFormatCore::readHeader().

Here is the caller graph for this function:

Foam::ISstream & putback ( const char &  c  )  [inline]

Raw, low-level putback character function.

Definition at line 73 of file ISstreamI.H.

References IOstream::lineNumber_, and IOstream::setState().

Here is the call graph for this function:

Foam::Istream & read ( token t  )  [virtual]

Return next token from stream.

Implements Istream.

Definition at line 94 of file ISstream.C.

Foam::Istream & read ( char &  c  )  [virtual]

Read a character.

Implements Istream.

Definition at line 267 of file ISstream.C.

Foam::Istream & read ( word str  )  [virtual]

Read a word.

Implements Istream.

Definition at line 274 of file ISstream.C.

Foam::Istream & read ( string str  )  [virtual]

Read a string (including enclosing double-quotes).

Backslashes are retained, except when escaping double-quotes and an embedded newline character.

Implements Istream.

Definition at line 350 of file ISstream.C.

Foam::Istream & read ( label val  )  [virtual]

Read a label.

Implements Istream.

Definition at line 460 of file ISstream.C.

Foam::Istream & read ( floatScalar val  )  [virtual]

Read a floatScalar.

Implements Istream.

Definition at line 468 of file ISstream.C.

References IOstream::setState().

Here is the call graph for this function:

Foam::Istream & read ( doubleScalar val  )  [virtual]

Read a doubleScalar.

Implements Istream.

Definition at line 476 of file ISstream.C.

References IOstream::setState().

Here is the call graph for this function:

Foam::Istream & read ( char *  buf,
std::streamsize  count 
) [virtual]

Read binary block.

Implements Istream.

Definition at line 485 of file ISstream.C.

References IOstream::setState().

Here is the call graph for this function:

Foam::Istream & rewind (  )  [virtual]

Rewind and return the stream so that it may be read again.

Implements Istream.

Definition at line 504 of file ISstream.C.

std::ios_base::fmtflags flags ( const ios_base::fmtflags  flags  )  [virtual]

Set flags of output stream.

Definition at line 521 of file ISstream.C.

void print ( Ostream os  )  const [virtual]

Print description of IOstream to Ostream.

Reimplemented from IOstream.

Reimplemented in IFstream, and IStringStream.

Definition at line 27 of file SstreamsPrint.C.

Referenced by OSstream::print().

Here is the caller graph for this function:


The documentation for this class was generated from the following files:
Copyright © 2000-2009 OpenCFD Ltd