claw::graphic::png::writer::target_manager Struct Reference

#include <png.hpp>

List of all members.


Detailed Description

Target manager that allow us to write in a std::ostream.

Author:
Julien Jorge

Definition at line 163 of file png.hpp.

Public Member Functions

 target_manager (std::ostream &os)
 Constructor.
void write (png_bytep data, png_size_t length)
 Write data in the ouput stream.
void flush ()
 Flush the output stream.

Private Attributes

std::ostream & m_output
 The stream in which we write the data.


Constructor & Destructor Documentation

claw::graphic::png::writer::target_manager::target_manager ( std::ostream &  os  ) 

Constructor.

Parameters:
os The stream in which we write.

Definition at line 72 of file png_writer.cpp.

References CLAW_PRECOND.

00073   : m_output(os)
00074 {
00075   CLAW_PRECOND( !!os );
00076 } // png::writer::target_manager::target_manager()


Member Function Documentation

void claw::graphic::png::writer::target_manager::flush (  ) 

Flush the output stream.

Definition at line 94 of file png_writer.cpp.

References m_output.

00095 {
00096   m_output.flush();
00097 } // png::writer::target_manager::flush()

void claw::graphic::png::writer::target_manager::write ( png_bytep  data,
png_size_t  length 
)

Write data in the ouput stream.

Parameters:
data (out) Array of the bytes to write.
length Number of bytes to write.

Definition at line 85 of file png_writer.cpp.

00086 {
00087   m_output.write( (char*)data, length * sizeof(png_byte) );
00088 } // png::writer::target_manager::write()


Member Data Documentation

std::ostream& claw::graphic::png::writer::target_manager::m_output [private]

The stream in which we write the data.

Definition at line 173 of file png.hpp.

Referenced by flush().


The documentation for this struct was generated from the following files:
Generated on Mon Nov 9 05:07:35 2009 for CLAW Library (a C++ Library Absolutely Wonderful) by  doxygen 1.4.7