TrioCFD 1.9.9_beta
TrioCFD documentation
Loading...
Searching...
No Matches
OBuffer Class Reference

#include <OBuffer.h>

Inheritance diagram for OBuffer:
[legend]
Collaboration diagram for OBuffer:
[legend]

Public Member Functions

 OBuffer ()
void new_buffer ()
void precision (int) override
int get_precision ()
const char * str ()
 Returns a pointer to the beginning of the buffer.
int len ()
void put_null_char ()
 Appends a null character at the end of the buffer to make it a valid C string.
Sortieflush () override
 Forces writing of buffered data to disk. Uses the ofstream implementation.
void set_bin (bool bin) override
Public Member Functions inherited from Sortie
 Sortie ()
 Sortie (ostream &os)
 Sortie (const Sortie &os)
virtual ~Sortie ()
Sortieoperator= (ostream &os)
Sortieoperator= (Sortie &os)
void set_bin (bool bin) override
 Changes the write mode of the file.
ostream & get_ostream ()
const ostream & get_ostream () const
void set_col_width (int w)
Sortieoperator<< (ostream &(*f)(ostream &))
Sortieoperator<< (Sortie &(*f)(Sortie &))
Sortieoperator<< (ios &(*f)(ios &))
virtual Sortielockfile ()
virtual Sortieunlockfile ()
virtual Sortiesyncfile ()
virtual void setf (IOS_FORMAT)
template<typename T>
Sortieoperator<< (const TRUST_Ref< T > &)
Sortieoperator<< (const TRUST_Ref_Objet_U &)
virtual Sortieoperator<< (const Separateur &)
virtual Sortieoperator<< (const Objet_U &ob)
 Writes an object or variable.
virtual Sortieoperator<< (const int ob)
virtual Sortieoperator<< (const unsigned ob)
virtual Sortieoperator<< (const long ob)
virtual Sortieoperator<< (const long long ob)
virtual Sortieoperator<< (const unsigned long ob)
virtual Sortieoperator<< (const float ob)
virtual Sortieoperator<< (const double ob)
virtual Sortieoperator<< (const char *ob)
 Writes a character string.
virtual Sortieoperator<< (const std::string &str)
virtual int add_col (const double ob)
virtual int add_col (const char *ob)
virtual int put (const unsigned *ob, std::streamsize n, std::streamsize nb_colonnes=1)
virtual int put (const int *ob, std::streamsize n, std::streamsize nb_colonnes=1)
virtual int put (const float *ob, std::streamsize n, std::streamsize nb_colonnes=1)
virtual int put (const double *ob, std::streamsize n, std::streamsize nb_colonnes=1)
virtual int put (const long *ob, std::streamsize n, std::streamsize nb_colonnes=1)
virtual int put (const long long *ob, std::streamsize n, std::streamsize nb_colonnes=1)
bool has_ostream () const
Public Member Functions inherited from AbstractIO
bool is_64b () const
virtual void set_64b (bool is_64b)
bool is_bin ()
void set_avoid_conversion (bool avoid)
bool avoid_conversion ()

Additional Inherited Members

Protected Member Functions inherited from AbstractIO
 AbstractIO ()
virtual ~AbstractIO ()
template<typename _TYPE_>
bool must_convert () const
 Whether to convert an int into a long when reading/writing out data.
Protected Attributes inherited from Sortie
int col_width_
std::unique_ptr< ostream > ostream_
Protected Attributes inherited from AbstractIO
bool bin_ = false
 Is this a binary flux?
bool is_64b_
 Will we be reading/writing in 64b? (Init in ctor to avoid including arch.h probably).
bool avoid_conversion_ = false

Detailed Description

Definition at line 24 of file OBuffer.h.

Constructor & Destructor Documentation

◆ OBuffer()

OBuffer::OBuffer ( )

Definition at line 18 of file OBuffer.cpp.

Member Function Documentation

◆ flush()

Sortie & OBuffer::flush ( )
overridevirtual

Forces writing of buffered data to disk. Uses the ofstream implementation.

Returns
*this

Reimplemented from Sortie.

Definition at line 48 of file OBuffer.cpp.

◆ get_precision()

int OBuffer::get_precision ( )

Definition at line 40 of file OBuffer.cpp.

◆ len()

int OBuffer::len ( )

Definition at line 76 of file OBuffer.cpp.

◆ new_buffer()

void OBuffer::new_buffer ( )

Definition at line 24 of file OBuffer.cpp.

◆ precision()

void OBuffer::precision ( int i)
overridevirtual

Reimplemented from Sortie.

Definition at line 34 of file OBuffer.cpp.

◆ put_null_char()

void OBuffer::put_null_char ( )

Appends a null character at the end of the buffer to make it a valid C string.

len() returns the buffer length including the null terminator. See EcrFicPartage::syncfile().

Definition at line 59 of file OBuffer.cpp.

◆ set_bin()

void OBuffer::set_bin ( bool bin)
inlineoverridevirtual

Reimplemented from AbstractIO.

Definition at line 37 of file OBuffer.h.

◆ str()

const char * OBuffer::str ( )

Returns a pointer to the beginning of the buffer.

Definition at line 68 of file OBuffer.cpp.


The documentation for this class was generated from the following files:
  • /home/docs/trust-code/src/Kernel/Utilitaires/OBuffer.h
  • /home/docs/trust-code/src/Kernel/Utilitaires/OBuffer.cpp