A.I.M.S


aims::Writer< T > Class Template Reference

Generic writer for every format of Aims object. More...

#include <aims/io/writer.h>

Inheritance diagram for aims::Writer< T >:
Collaboration diagram for aims::Writer< T >:

Public Member Functions

 Writer ()
 
 Writer (const std::string &filename, carto::Object options=carto::none())
 
virtual ~Writer ()
 
virtual bool write (const T &obj, bool ascii=false, const std::string *format=0)
 Finds the correct format and writes the object. More...
 
virtual std::string writtenObjectType () const
 
virtual std::string writtenObjectDataType () const
 
virtual std::string writtenObjectFullType () const
 
- Public Member Functions inherited from aims::GenericWriter
 GenericWriter ()
 
 GenericWriter (const std::string &filename, carto::Object options=carto::none())
 
virtual ~GenericWriter ()
 
template<typename T >
bool write (const T &obj, bool ascii=false, const std::string *format=0)
 Finds the correct format and writes the object. More...
 
void setFileName (const std::string &fileName)
 set output file name More...
 
const std::string & fileName () const
 get output file name More...
 
const carto::Object options () const
 
void setOptions (carto::Object opt)
 

Additional Inherited Members

- Protected Attributes inherited from aims::GenericWriter
std::string _filename
 
carto::Object _options
 

Detailed Description

template<class T>
class aims::Writer< T >

Generic writer for every format of Aims object.

The Writer classes are built on the same model as the Reader classes and share the same FileFormatDictionary with them to store all known file formats.

See also
FileFormatDictionary Reader

Definition at line 92 of file writer.h.

Constructor & Destructor Documentation

template<class T>
aims::Writer< T >::Writer ( )
inline

Definition at line 95 of file writer.h.

template<class T>
aims::Writer< T >::Writer ( const std::string &  filename,
carto::Object  options = carto::none() 
)
inline

Definition at line 96 of file writer.h.

template<class T>
virtual aims::Writer< T >::~Writer ( )
inlinevirtual

Definition at line 99 of file writer.h.

Member Function Documentation

template<class T >
bool aims::Writer< T >::write ( const T &  obj,
bool  ascii = false,
const std::string *  format = 0 
)
virtual
template<class T >
std::string aims::Writer< T >::writtenObjectDataType ( ) const
virtual

Implements aims::GenericWriter.

Definition at line 94 of file writer_d.h.

template<class T >
std::string aims::Writer< T >::writtenObjectFullType ( ) const
virtual

Implements aims::GenericWriter.

Definition at line 101 of file writer_d.h.

References carto::DataTypeCode< class >::name().

template<class T >
std::string aims::Writer< T >::writtenObjectType ( ) const
virtual

Implements aims::GenericWriter.

Definition at line 87 of file writer_d.h.


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