vega
single_string_manipulator.h
Go to the documentation of this file.
1 #pragma once
2 
4 #include <string>
5 
6 namespace vega {
7  namespace manipulators {
14  private:
15  std::string m_str;
16 
17  public:
19  explicit SingleStringManipulator(const std::string& str);
20  explicit SingleStringManipulator(std::shared_ptr<dicom::RawValue> raw_value);
21 
23  const std::string& value() const { return m_str; }
25  std::string& value() { return m_str; }
26 
27  std::shared_ptr<dicom::RawValue> raw_value() override;
28  std::string str() const override;
29  bool read_from(dicom::RawReader* reader, size_t num_bytes) override;
30  size_t write_to(dicom::RawWriter* writer) const override;
31 
32  virtual bool operator==(const ValueManipulator& other) const override;
33  virtual bool operator!=(const ValueManipulator& other) const override;
34  };
35  }
36 }
size_t write_to(dicom::RawWriter *writer) const override
virtual bool operator!=(const ValueManipulator &other) const override
A manipulator class for VR that represent a single string.
Definition: single_string_manipulator.h:13
std::string str() const override
bool read_from(dicom::RawReader *reader, size_t num_bytes) override
const std::string & value() const
Definition: single_string_manipulator.h:23
Definition: value_manipulator.h:29
std::shared_ptr< dicom::RawValue > raw_value() override
std::string & value()
Definition: single_string_manipulator.h:25
Definition: age.h:6
virtual bool operator==(const ValueManipulator &other) const override