argstream

argstream is a class that facilitates easy parsing of command line arguments in C .
Download

argstream Ranking & Summary

Advertisement

  • Rating:
  • License:
  • GPL
  • Price:
  • FREE
  • Publisher Name:
  • Xavier Decoret
  • Publisher web site:
  • http://artis.imag.fr/Membres/Xavier.Decoret/resources/argstream/

argstream Tags


argstream Description

argstream is a class that facilitates easy parsing of command line arguments in C . argstream is a class that facilitates easy parsing of command line arguments in C . The syntax is very simple and uses stream operators to parse various types of arguments.Here is a list of functionalities offered for the parsing of command line arguments :· Short (-c) and long ( --color) names for switches, short names being optional (there is only a limited number of character so you might need to define switches without short names); · Case sensitive switches (-c is different of -C); · Three types of arguments : · option: associated to bool variables that are set to true if the switch is present on the command line or false otherwise (ex: ls -l); · parameter: associated to a variable of any type whose value is set to the argument following on command line (ex: dvips -o foo.ps); · values: sequence of specifiable length (eventually variable) of arguments on the command line (ex: gzip foo.txt bar.txt foobar.eps); · Possibility for optional parameter with default value; · Possibility for parameter values starting with - through the use of the special -- switch; · Automatic handling of help and errors; · Possibility for complex parsing such as switches available only if a condition is met by previously parsed switches; · Groupable options (ex: tar -xvf foo.tar as a shorthand for tar -x -v -f foo.tar); · Possibility to extend to user defined types very simply; · Simple and concise interface, with just a header file to include (no library to link with);What's New in This Release:· added wrappers for option/parametes without either short or long names.· Added the patch from Jean-baptiste Denis (evadream@evadream.net) for gcc 3.4.· Updated the documentation.


argstream Related Software