Generic output stream using a standard (STL) stream. More...
Public Member Functions | |
OSstream (const OSstream &)=default | |
void | operator= (const OSstream &)=delete |
OSstream (std::ostream &os, const string &streamName, IOstreamOption streamOpt=IOstreamOption()) | |
OSstream (std::ostream &os, const string &streamName, IOstreamOption::streamFormat fmt, IOstreamOption::versionNumber ver=IOstreamOption::currentVersion, IOstreamOption::compressionType cmp=IOstreamOption::UNCOMPRESSED) | |
virtual const fileName & | name () const |
virtual fileName & | name () |
virtual ios_base::fmtflags | flags () const |
virtual bool | write (const token &tok) |
virtual Ostream & | write (const char c) |
virtual Ostream & | write (const char *str) |
virtual Ostream & | write (const word &str) |
virtual Ostream & | write (const string &str) |
virtual Ostream & | writeQuoted (const std::string &str, const bool quoted=true) |
virtual Ostream & | write (const int32_t val) |
virtual Ostream & | write (const int64_t val) |
virtual Ostream & | write (const floatScalar val) |
virtual Ostream & | write (const doubleScalar val) |
virtual Ostream & | write (const char *data, std::streamsize count) |
virtual Ostream & | writeRaw (const char *data, std::streamsize count) |
virtual bool | beginRawWrite (std::streamsize count) |
virtual bool | endRawWrite () |
virtual void | indent () |
virtual ios_base::fmtflags | flags (const ios_base::fmtflags f) |
virtual void | flush () |
virtual void | endl () |
virtual char | fill () const |
virtual char | fill (const char fillch) |
virtual int | width () const |
virtual int | width (const int w) |
virtual int | precision () const |
virtual int | precision (const int p) |
virtual std::ostream & | stdStream () |
virtual const std::ostream & | stdStream () const |
virtual void | print (Ostream &os) const |
![]() | |
Ostream (const Ostream &)=default | |
virtual | ~Ostream ()=default |
Ostream (IOstreamOption streamOpt=IOstreamOption()) | |
Ostream (IOstreamOption::streamFormat fmt, IOstreamOption::versionNumber ver=IOstreamOption::currentVersion, IOstreamOption::compressionType cmp=IOstreamOption::UNCOMPRESSED) | |
virtual Ostream & | write (const keyType &kw) |
unsigned short | indentSize () const noexcept |
unsigned short | indentSize (unsigned short val) noexcept |
unsigned short | indentLevel () const noexcept |
unsigned short | indentLevel (unsigned short val) noexcept |
void | incrIndent () noexcept |
void | decrIndent () |
virtual Ostream & | writeKeyword (const keyType &kw) |
virtual Ostream & | beginBlock (const keyType &kw) |
virtual Ostream & | beginBlock () |
virtual Ostream & | endBlock () |
virtual Ostream & | endEntry () |
template<class T > | |
Ostream & | writeEntry (const keyType &key, const T &value) |
template<class T > | |
Ostream & | writeEntryIfDifferent (const word &key, const T &value1, const T &value2) |
Ostream & | operator() () const |
unsigned short & | indentLevel () noexcept |
unsigned short & | indentSize () noexcept |
![]() | |
IOstream (const IOstream &)=default | |
virtual | ~IOstream ()=default |
IOstream (IOstreamOption streamOpt=IOstreamOption()) | |
IOstream (IOstreamOption::streamFormat fmt, IOstreamOption::versionNumber ver, IOstreamOption::compressionType cmp=IOstreamOption::UNCOMPRESSED) | |
fileName | relativeName () const |
virtual bool | check (const char *operation) const |
bool | fatalCheck (const char *operation) const |
bool | opened () const noexcept |
bool | closed () const noexcept |
bool | good () const noexcept |
bool | eof () const noexcept |
bool | fail () const noexcept |
bool | bad () const noexcept |
operator bool () const noexcept | |
bool | operator! () const noexcept |
unsigned | labelByteSize () const noexcept |
unsigned | scalarByteSize () const noexcept |
void | setLabelByteSize (unsigned nbytes) noexcept |
void | setScalarByteSize (unsigned nbytes) noexcept |
template<class T = label> | |
std::enable_if< std::is_integral< T >::value, bool >::type | checkLabelSize () const noexcept |
template<class T = scalar> | |
std::enable_if< std::is_floating_point< T >::value, bool >::type | checkScalarSize () const noexcept |
label | lineNumber () const noexcept |
label & | lineNumber () noexcept |
label | lineNumber (const label num) noexcept |
void | setEof () noexcept |
void | setFail () noexcept |
void | setBad () |
ios_base::fmtflags | setf (const ios_base::fmtflags f) |
ios_base::fmtflags | setf (const ios_base::fmtflags f, const ios_base::fmtflags mask) |
void | unsetf (const ios_base::fmtflags f) |
void | print (Ostream &os, const int streamState) const |
InfoProxy< IOstream > | info () const |
![]() | |
constexpr | IOstreamOption (streamFormat fmt=streamFormat::ASCII, compressionType comp=compressionType::UNCOMPRESSED) noexcept |
constexpr | IOstreamOption (streamFormat fmt, compressionType comp, versionNumber ver) noexcept |
constexpr | IOstreamOption (streamFormat fmt, versionNumber ver, compressionType comp=compressionType::UNCOMPRESSED) noexcept |
IOstreamOption (const IOstreamOption &opt, streamFormat fmt) noexcept | |
streamFormat | format () const noexcept |
streamFormat | format (const streamFormat fmt) noexcept |
streamFormat | format (const word &formatName) |
compressionType | compression () const noexcept |
compressionType | compression (const compressionType comp) noexcept |
compressionType | compression (const word &compName) |
versionNumber | version () const noexcept |
versionNumber | version (const versionNumber ver) noexcept |
versionNumber | version (const token &tok) |
Additional Inherited Members | |
![]() | |
enum | streamAccess : char { CLOSED = 0, OPENED } |
![]() | |
enum | streamFormat : char { ASCII = 0, BINARY } |
enum | compressionType : char { UNCOMPRESSED = 0, COMPRESSED } |
![]() | |
static unsigned int | defaultPrecision () noexcept |
static unsigned int | defaultPrecision (unsigned int prec) noexcept |
![]() | |
static streamFormat | formatEnum (const word &formatName, const streamFormat deflt=streamFormat::ASCII) |
static streamFormat | formatEnum (const word &key, const dictionary &dict, const streamFormat deflt=streamFormat::ASCII) |
static compressionType | compressionEnum (const word &compName, const compressionType deflt=compressionType::UNCOMPRESSED) |
static compressionType | compressionEnum (const word &key, const dictionary &dict, const compressionType deflt=compressionType::UNCOMPRESSED) |
![]() | |
static unsigned int | precision_ |
![]() | |
static const Enum< streamFormat > | formatNames |
static const versionNumber | currentVersion |
![]() | |
void | setOpened () noexcept |
void | setClosed () noexcept |
void | setState (std::ios_base::iostate state) noexcept |
void | setGood () noexcept |
![]() | |
unsigned short | indentSize_ = 4 |
unsigned short | indentLevel_ = 0 |
![]() | |
std::ios_base::iostate | ioState_ |
streamAccess | openClosed_ |
unsigned char | sizeofLabel_ |
unsigned char | sizeofScalar_ |
label | lineNumber_ |
![]() | |
static constexpr const unsigned short | entryIndentation_ = 16 |
![]() | |
static fileName | staticName_ |
Generic output stream using a standard (STL) stream.
Definition at line 50 of file OSstream.H.
|
inline |
Definition at line 27 of file OSstreamI.H.
|
inline |
Definition at line 85 of file OSstream.H.
|
delete |
|
inlinevirtual |
Reimplemented from IOstream.
Definition at line 103 of file OSstream.H.
Referenced by fvMotionSolver::cellMotionBoundaryTypes(), dynamicOversetFvMesh::checkCoupledBC(), meshObject::clear(), meshObject::clearUpto(), mappedPatchBase::collectSamples(), FaceCellWave< Type, int >::handleCyclicPatches(), meshObject::movePoints(), fvMeshDistribute::printFieldInfo(), boundaryMesh::readTriSurface(), voxelMeshSearch::update(), timeVaryingMappedFixedValuePointPatchField< Type >::updateCoeffs(), meshObject::updateMesh(), MappedFile< Type >::value(), and voxelMeshSearch::voxelMeshSearch().
|
inlinevirtual |
Reimplemented from IOstream.
Definition at line 109 of file OSstream.H.
|
virtual |
Implements IOstream.
Definition at line 281 of file OSstream.C.
Referenced by objective::write().
Implements Ostream.
Reimplemented in prefixOSstream, and ensightFile.
Definition at line 29 of file OSstream.C.
References token::BEGIN_BLOCK, token::END_BLOCK, token::HASH, token::stringToken(), token::type(), token::wordToken(), and OSstream::writeQuoted().
Referenced by prefixOSstream::write(), OBJstream::write(), and OBJstream::writeQuoted().
|
virtual |
Implements Ostream.
Reimplemented in ensightFile, OBJstream, and prefixOSstream.
Definition at line 82 of file OSstream.C.
References Foam::constant::universal::c, and token::NL.
|
virtual |
Implements Ostream.
Reimplemented in ensightFile, OBJstream, and prefixOSstream.
Definition at line 94 of file OSstream.C.
References Foam::stringOps::count(), and token::NL.
|
virtual |
Implements Ostream.
Reimplemented in prefixOSstream, ensightFile, and OBJstream.
Definition at line 103 of file OSstream.C.
|
virtual |
Implements Ostream.
Reimplemented in prefixOSstream, OSHA1stream, ensightFile, and OBJstream.
Definition at line 170 of file OSstream.C.
References writeQuoted().
|
virtual |
Implements Ostream.
Reimplemented in prefixOSstream, and OBJstream.
Definition at line 112 of file OSstream.C.
References Foam::constant::universal::c, Foam::stringOps::count(), token::DQUOTE, and token::NL.
Referenced by OSstream::write(), OSHA1stream::write(), and prefixOSstream::writeQuoted().
|
virtual |
Implements Ostream.
Reimplemented in ensightFile, and prefixOSstream.
Definition at line 176 of file OSstream.C.
|
virtual |
Implements Ostream.
Reimplemented in ensightFile, and prefixOSstream.
Definition at line 184 of file OSstream.C.
|
virtual |
Implements Ostream.
Reimplemented in ensightFile, and prefixOSstream.
Definition at line 192 of file OSstream.C.
|
virtual |
Implements Ostream.
Reimplemented in ensightFile, and prefixOSstream.
Definition at line 200 of file OSstream.C.
|
virtual |
Implements Ostream.
Reimplemented in ensightFile, and prefixOSstream.
Definition at line 208 of file OSstream.C.
References Foam::BitOps::count().
|
virtual |
Implements Ostream.
Definition at line 244 of file OSstream.C.
References Foam::BitOps::count(), and Ostream::write().
Referenced by decomposedBlockData::writeData().
|
virtual |
Implements Ostream.
Definition at line 218 of file OSstream.C.
References Foam::abort(), token::BEGIN_LIST, Foam::FatalIOError, FatalIOErrorInFunction, and format().
|
virtual |
|
virtual |
Implements Ostream.
Reimplemented in prefixOSstream.
Definition at line 259 of file OSstream.C.
Referenced by prefixOSstream::indent(), Foam::indent(), and Foam::printDOT().
|
virtual |
Implements IOstream.
Definition at line 287 of file OSstream.C.
References f().
|
virtual |
Implements Ostream.
Definition at line 268 of file OSstream.C.
Referenced by DSMCCloud< ParcelType >::dumpParticlePositions(), Foam::flush(), and Cloud< passivePositionParticle >::writePositions().
|
virtual |
Implements Ostream.
Definition at line 274 of file OSstream.C.
References Foam::vtk::write().
Referenced by Foam::endl().
|
virtual |
Implements Ostream.
Definition at line 295 of file OSstream.C.
|
virtual |
Implements Ostream.
Definition at line 301 of file OSstream.C.
|
virtual |
Implements Ostream.
Definition at line 307 of file OSstream.C.
Referenced by snappyVoxelMeshDriver::snappyVoxelMeshDriver().
|
virtual |
Implements Ostream.
Definition at line 313 of file OSstream.C.
|
virtual |
Implements Ostream.
Definition at line 319 of file OSstream.C.
Referenced by GAMGAgglomeration::compactLevels(), Foam::entryToString(), Time::readDict(), ensightSetWriter< Type >::write(), dimensionSet::write(), PDRblock::writeBlockMeshDict(), ensightWriter::writeCollated(), and ensightWriter::writeUncollated().
|
virtual |
|
inlinevirtual |
Reimplemented in OFstream.
Definition at line 217 of file OSstream.H.
|
inlinevirtual |
Reimplemented in OFstream.
Definition at line 223 of file OSstream.H.
|
virtual |
Reimplemented from IOstream.
Reimplemented in OListStream, OCountStream, OStringStream, UOListStream, prefixOSstream, and OFstream.
Definition at line 39 of file SstreamsPrint.C.
References Foam::name(), os(), and IOstream::print().
Referenced by OFstream::print(), prefixOSstream::print(), and OStringStream::print().
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.