17 #ifndef DCM_TREE_VALUE_H
18 #define DCM_TREE_VALUE_H
21 #pragma warning (push)
22 #pragma warning (disable : 4350)
30 #include <boost/shared_array.hpp>
60 Value (
const unsigned int &size);
67 Value (
const unsigned int &size,
const unsigned char *data);
90 bool operator ==(const
Value &other) const;
95 bool operator !=(const
Value &other) const;
105 unsigned int size() const;
110 const
unsigned char *data() const;
115 unsigned char *data();
120 boost::shared_array<
unsigned char> sharedData() const;
125 void setSize (const
unsigned int &size);
131 void setData (const
unsigned int &size,const
unsigned char *data);
139 void setData (const
unsigned int &size,
unsigned char *data,
145 void setData (const std::
string &value);
169 void allocate (const
unsigned int &size);
171 boost::shared_array<
unsigned char> _data;
173 unsigned int _buffersize;
178 inline std::ostream &operator << (std::ostream &out,const
Value &v)
Class to store tag values.
Value(const Value &other)
Makes a deep copy of other to this.
Value(Value &&) noexcept=default
void toStream(std::ostream &out) const
Copies this instance recursively into the given stream.
Value(const unsigned int &size)
Creates a value with the given size in bytes.
Value(const unsigned int &size, const unsigned char *data)
Creates a value with the given size in bytes and memcpy data to it.
void fromStream(std::istream &in)
Extracts this instance from the given stream.
Interface that provides a method to deserialize an object.
Interface that provides a method to serialize an object.
void serializeX(Sink &sink, const DCMTree::TransferSyntax &syntax)
void deserializeX(Source &source, DCMTree::TransferSyntax &syntax)
DCMTREE_EXPORT void fromStream(std::istream &in, std::string &val, size_t maxSize=0)
Helper functions to read data out of a stream.
DCMTREE_EXPORT void toStream(std::ostream &out, const std::string &val)
Helper functions to write data into a stream.
Class to dump a DCMTree DICOM message into a human-readable file.
std::istream & operator>>(std::istream &in, Message &m)
std::vector< Value > ValueVector
Forward declaration for the boost::mutex class.
boost::graph_traits< ml_graph_ptr >::vertex_descriptor source(graph_traits< ml_graph_ptr >::edge_descriptor e, const ml_graph_ptr)
Returns the vertex descriptor for u of the edge (u,v) represented by e.
boost::log::sinks::sink Sink