29 #ifndef CDPL_UTIL_COMPRESSEDDATAWRITER_HPP
30 #define CDPL_UTIL_COMPRESSEDDATAWRITER_HPP
53 template <
typename WriterImpl,
typename CompStream,
typename DataType =
typename WriterImpl::DataType>
81 operator const void*()
const;
99 template <
typename WriterImpl,
typename DecompStream,
typename DataType>
101 stream(os), writer(stream)
103 writer.setParent(
this);
107 template <
typename WriterImpl,
typename DecompStream,
typename DataType>
116 template <
typename WriterImpl,
typename DecompStream,
typename DataType>
123 template <
typename WriterImpl,
typename DecompStream,
typename DataType>
126 return writer.operator
const void*();
129 template <
typename WriterImpl,
typename DecompStream,
typename DataType>
132 return writer.operator!();
Definition of I/O-stream classes capable of performing compression and decompression.
Definition of class CDPL::Base::DataWriter.
void invokeIOCallbacks(double progress) const
Invokes all registered I/O callback functions with the argument *this.
Interface for writing data objects of a given type to an arbitrary data sink.
Definition: DataWriter.hpp:63
typename WriterImpl::DataType DataType
The type of the written data objects.
Definition: DataWriter.hpp:74
Convenience wrapper that combines a Util::CompressionOStream of type CompStream with a stream-based w...
Definition: CompressedDataWriter.hpp:55
CompressedDataWriter(std::ostream &os)
Constructs the CompressedDataWriter instance that compresses output written to os via CompStream and ...
Definition: CompressedDataWriter.hpp:100
CompressedDataWriter & write(const DataType &obj)
Writes obj via the wrapped writer.
Definition: CompressedDataWriter.hpp:109
bool operator!() const
Tells whether the writer is in a bad (non-writable) state.
Definition: CompressedDataWriter.hpp:130
void close()
Closes the wrapped writer and finalizes the compression stream.
Definition: CompressedDataWriter.hpp:117
The namespace of the Chemical Data Processing Library.