Wrapper class for accessing file name option information.
|
| FileNameOptionInfo (FileNameOptionStorage *option) |
| Creates an option info object for the given option.
|
|
bool | isInputFile () const |
| Whether the option specifies an input file.
|
|
bool | isOutputFile () const |
| Whether the option specifies an output file.
|
|
bool | isInputOutputFile () const |
| Whether the option specifies a file used for both input and output.
|
|
bool | isLibraryFile () const |
| Whether the option specifies a library file. More...
|
|
bool | allowMissing () const |
| Whether the (input) option allows missing files to be provided.
|
|
bool | isDirectoryOption () const |
| Whether the option specifies directories.
|
|
bool | isTrajectoryOption () const |
| Whether the option specifies a generic trajectory file.
|
|
const char * | defaultExtension () const |
| Returns the default extension for this option.
|
|
ExtensionList | extensions () const |
| Returns the list of extensions this option accepts.
|
|
bool | isValidType (int fileType) const |
| Returns whether fileType (from filetypes.h) is accepted for this option.
|
|
ArrayRef< const int > | fileTypes () const |
| Returns the list of file types this option accepts.
|
|
template<class InfoType > |
bool | isType () const |
| Test whether the option is of a particular type. More...
|
|
template<class InfoType > |
InfoType * | toType () |
| Convert the info object to a particular type if the type is correct. More...
|
|
template<class InfoType > |
const InfoType * | toType () const |
| Convert the info object to a particular type if the type is correct. More...
|
|
bool | isSet () const |
| Returns true if the option has been set.
|
|
bool | isHidden () const |
| Returns true if the option is a hidden option.
|
|
bool | isRequired () const |
| Returns true if the option is required.
|
|
int | minValueCount () const |
| Returns the minimum number of values that this option accepts.
|
|
int | maxValueCount () const |
| Returns the maximum number of values that this option accepts.
|
|
const std::string & | name () const |
| Returns the name of the option.
|
|
std::string | type () const |
| Returns the type of the option as a string.
|
|
std::string | formatDescription () const |
| Returns the description of the option.
|
|
std::vector< Any > | defaultValues () const |
| Returns the default value(s) of the option. More...
|
|
std::vector< std::string > | defaultValuesAsStrings () const |
| Returns the default value(s) of the option as strings. More...
|
|
std::vector< Any > | normalizeValues (const std::vector< Any > &values) const |
| Converts given values to native representation for this option. More...
|
|
std::vector< Any > gmx::OptionInfo::defaultValues |
( |
| ) |
const |
|
inherited |
Returns the default value(s) of the option.
The returned values should all be of the same type, but returning each as a separate any is currently simpler.
Currently, this can only be called before option values have been assigned.
std::vector< std::string > gmx::OptionInfo::defaultValuesAsStrings |
( |
| ) |
const |
|
inherited |
Returns the default value(s) of the option as strings.
If there is no default value, but defaultValueIfSet() is set, that is returned instead.
Currently, this can only be called before option values have been assigned.
std::vector< Any > gmx::OptionInfo::normalizeValues |
( |
const std::vector< Any > & |
values | ) |
const |
|
inherited |
Converts given values to native representation for this option.
For example, strings are parsed to the type that is actually used to store the options.
The return value only depends on the option type, not on the current value of the option, and the current value in the option is not changed.