9 #include "ismrmrd/export.h"
51 present_ = o.present_;
71 const T* operator->()
const {
75 const T& operator*()
const {
79 operator bool()
const {
83 bool is_present()
const {
87 bool has_value()
const noexcept {
94 throw std::runtime_error(
"Access optional value, which has not been set");
100 const T &value()
const &{
102 throw std::runtime_error(
"Access optional value, which has not been set");
109 throw std::runtime_error(
"Access optional value, which has not been set");
111 return std::move(value_);
114 const T &&value()
const &&{
116 throw std::runtime_error(
"Access optional value, which has not been set");
118 return std::move(value_);
122 return this->value();
126 return this->value();
128 const T &get()
const & {
129 return this->value();
132 const T&& get()
const &&{
133 return this->value();
136 T value_or(U &&default_value)
const &{
137 return bool(*
this) ? **this :
static_cast<T
>(std::forward<U>(default_value));
141 T value_or(U &&default_value) &&{
142 return bool(*
this) ? std::move(**
this) :
static_cast<T
>(std::forward<U>(default_value));
152 void set(
const T& v) {
192 std::string dependencyType;
193 std::string measurementID;
198 std::string referencedSOPInstanceUID;
206 std::string patientPosition;
211 std::vector<MeasurementDependency> measurementDependency;
214 std::vector<ReferencedImageSequence> referencedImageSequence;
219 unsigned short coilNumber;
220 std::string coilName;
230 std::vector<CoilLabel> coilLabel;
239 long int H1resonanceFrequency_Hz;
252 MatrixSize(
unsigned short x,
unsigned short y)
260 MatrixSize(
unsigned short x,
unsigned short y,
unsigned short z)
297 Limit(
unsigned short minimum,
unsigned short maximum,
unsigned short center)
305 unsigned short minimum;
306 unsigned short maximum;
307 unsigned short center;
346 std::vector<UserParameterLong> userParameterLong;
347 std::vector<UserParameterDouble> userParameterDouble;
348 std::vector<UserParameterString> userParameterString;
349 std::vector<UserParameterString> userParameterBase64;
354 std::string identifier;
355 std::vector<UserParameterLong> userParameterLong;
356 std::vector<UserParameterDouble> userParameterDouble;
362 unsigned short kspace_encoding_step_1;
363 unsigned short kspace_encoding_step_2;
373 enum class TrajectoryType {
387 TrajectoryType trajectory;
403 enum class WaveformType {
414 std::string waveformName;
415 WaveformType waveformType;
427 std::vector<Encoding> encoding;
430 std::vector<WaveformInformation> waveformInformation;
434 EXPORTISMRMRD
void deserialize(
const char* xml,
IsmrmrdHeader& h);
435 EXPORTISMRMRD
void serialize(
const IsmrmrdHeader& h, std::ostream& o);