klee
klee::TreeStreamWriter Class Reference

#include <TreeStream.h>

Public Member Functions

 TreeStreamWriter (const std::string &_path)
 
 ~TreeStreamWriter ()
 
bool good ()
 
TreeOStream open ()
 
TreeOStream open (const TreeOStream &node)
 
void flush ()
 
void readStream (TreeStreamID id, std::vector< unsigned char > &out)
 

Private Member Functions

void write (TreeOStream &os, const char *s, unsigned size)
 
void flushBuffer ()
 

Private Attributes

char buffer [bufferSize]
 
unsigned lastID
 
unsigned bufferCount
 
std::string path
 
std::ofstream * output
 
unsigned ids
 

Static Private Attributes

static const unsigned bufferSize = 4*4096
 

Friends

class TreeOStream
 

Detailed Description

Definition at line 21 of file TreeStream.h.

Constructor & Destructor Documentation

◆ TreeStreamWriter()

TreeStreamWriter::TreeStreamWriter ( const std::string &  _path)

Definition at line 28 of file TreeStream.cpp.

References output.

◆ ~TreeStreamWriter()

TreeStreamWriter::~TreeStreamWriter ( )

Definition at line 41 of file TreeStream.cpp.

References flush(), and output.

Here is the call graph for this function:

Member Function Documentation

◆ flush()

void TreeStreamWriter::flush ( )

Definition at line 91 of file TreeStream.cpp.

References flushBuffer(), and output.

Referenced by klee::TreeOStream::flush(), readStream(), and ~TreeStreamWriter().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ flushBuffer()

void TreeStreamWriter::flushBuffer ( void  )
private

Definition at line 82 of file TreeStream.cpp.

References buffer, bufferCount, lastID, and output.

Referenced by flush(), open(), and write().

Here is the caller graph for this function:

◆ good()

bool TreeStreamWriter::good ( )

Definition at line 46 of file TreeStream.cpp.

References output.

Referenced by KleeHandler::setInterpreter().

Here is the caller graph for this function:

◆ open() [1/2]

TreeOStream TreeStreamWriter::open ( )

Definition at line 50 of file TreeStream.cpp.

References open(), and TreeOStream.

Referenced by klee::Executor::fork(), open(), and klee::Executor::runFunctionAsMain().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ open() [2/2]

TreeOStream TreeStreamWriter::open ( const TreeOStream node)

Definition at line 54 of file TreeStream.cpp.

References flushBuffer(), klee::TreeOStream::id, ids, output, TreeOStream, and klee::TreeOStream::writer.

Here is the call graph for this function:

◆ readStream()

void TreeStreamWriter::readStream ( TreeStreamID  id,
std::vector< unsigned char > &  out 
)

Definition at line 96 of file TreeStream.cpp.

References flush(), ids, and path.

Referenced by KleeHandler::processTestCase().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ write()

void TreeStreamWriter::write ( TreeOStream os,
const char *  s,
unsigned  size 
)
private

Definition at line 64 of file TreeStream.cpp.

References buffer, bufferCount, bufferSize, flushBuffer(), klee::TreeOStream::id, lastID, and output.

Referenced by klee::TreeOStream::write().

Here is the call graph for this function:
Here is the caller graph for this function:

Friends And Related Function Documentation

◆ TreeOStream

friend class TreeOStream
friend

Definition at line 24 of file TreeStream.h.

Referenced by open().

Member Data Documentation

◆ buffer

char klee::TreeStreamWriter::buffer[bufferSize]
private

Definition at line 27 of file TreeStream.h.

Referenced by flushBuffer(), and write().

◆ bufferCount

unsigned klee::TreeStreamWriter::bufferCount
private

Definition at line 28 of file TreeStream.h.

Referenced by flushBuffer(), and write().

◆ bufferSize

const unsigned klee::TreeStreamWriter::bufferSize = 4*4096
staticprivate

Definition at line 22 of file TreeStream.h.

Referenced by write().

◆ ids

unsigned klee::TreeStreamWriter::ids
private

Definition at line 32 of file TreeStream.h.

Referenced by open(), and readStream().

◆ lastID

unsigned klee::TreeStreamWriter::lastID
private

Definition at line 28 of file TreeStream.h.

Referenced by flushBuffer(), and write().

◆ output

std::ofstream* klee::TreeStreamWriter::output
private

Definition at line 31 of file TreeStream.h.

Referenced by flush(), flushBuffer(), good(), open(), TreeStreamWriter(), write(), and ~TreeStreamWriter().

◆ path

std::string klee::TreeStreamWriter::path
private

Definition at line 30 of file TreeStream.h.

Referenced by readStream().


The documentation for this class was generated from the following files: