MeVisLab Toolbox Reference
mlMultiFileVolumeAdditionalOptions.h
Go to the documentation of this file.
1// Copyright (c) Fraunhofer MEVIS, Germany. All rights reserved.
2// **InsertLicense** code
3//----------------------------------------------------------------------------------
6
11//----------------------------------------------------------------------------------
12
13#pragma once
14
16#include <mlModuleIncludes.h>
17
18ML_START_NAMESPACE
19
25public:
28
31
34
36
38 void reset();
39
42
45
47 size_t getNumberOfOptions() const;
48
58 size_t findOption(const std::string &optionName, bool optionNameMustMatch,
59 const std::string &optionType, bool optionTypeMustMatch,
60 const std::string &optionValue, bool optionValueMustMatch) const;
61
70 void appendOption(const std::string& optionName,
71 const std::string& optionType,
72 const std::string& optionValue);
73
86 MLErrorCode getOption(size_t index,
87 std::string& optionName,
88 std::string& optionType,
89 std::string& optionValue) const;
90
92 std::string toString() const;
93
102 MLErrorCode fromString(const std::string& state, size_t& readPos);
103
104private:
106 std::vector< std::vector< std::string > > _options;
107};
108
109ML_END_NAMESPACE
Project global and OS specific declarations.
#define MLMULTI_FILE_VOLUME_EXPORT
Only for diagnostic purposes.
Container which stores additional options for MultiFileVolumes which can have an arbitrary number of ...
MLErrorCode getOption(size_t index, std::string &optionName, std::string &optionType, std::string &optionValue) const
Return contents of the option at position index from the container.
size_t findOption(const std::string &optionName, bool optionNameMustMatch, const std::string &optionType, bool optionTypeMustMatch, const std::string &optionValue, bool optionValueMustMatch) const
Returns the index of the first option matching the method arguments.
MultiFileVolumeAdditionalOptions()
Creates an empty container.
size_t getNumberOfOptions() const
Returns number of options currently stored in the container.
bool operator!=(const MultiFileVolumeAdditionalOptions &other) const
Compares *this and other, returns true on inequality, false otherwise.
std::string toString() const
Converts *this to a std::string and returns it.
MLErrorCode fromString(const std::string &state, size_t &readPos)
Reads a complete instance of this from state at position readPos; readPos is incremented to position ...
MultiFileVolumeAdditionalOptions & operator=(const MultiFileVolumeAdditionalOptions &)=default
Default assignment operator.
bool operator==(const MultiFileVolumeAdditionalOptions &other) const
Compares *this and other, returns true on equality, false otherwise.
void appendOption(const std::string &optionName, const std::string &optionType, const std::string &optionValue)
Appends a new option to the container.
void reset()
Clears all options and resets the instance to the construction state.
MultiFileVolumeAdditionalOptions(const MultiFileVolumeAdditionalOptions &)=default
Default copy constructor.
MLint32 MLErrorCode
Type of an ML Error code.
Definition mlTypeDefs.h:715