vibe.d beta banner
get vibe.d
0.7.31

Function readOption

Finds and reads an option from the configuration file or command line.

bool readOption(T) (
  string names,
  T* pvalue,
  string help_text
);

Command line options take precedence over configuration file entries.

Parameters

NameDescription
names Option names. Separate multiple name variants with "|", as for std.getopt.
pvalue Pointer to store the value. Unchanged if value was not found.
help_text Text to be displayed when the application is run with --help.

Returns

true if the value was found, false otherwise.

See Also

readRequiredOption

Authors

Sönke Ludwig, Vladimir Panteleev

Copyright

© 2012 RejectedSoftware e.K.

License

Subject to the terms of the MIT license, as written in the included LICENSE.txt file.