#include <tcl/argspec.h>
Public Member Functions | |
arg_spec (int nmin, int nmax=-1, bool ex=false) | |
Construct with initial values for m_argc_min/m_argc_max/m_is_exact. | |
arg_spec & | min (int nmin) |
arg_spec & | max (int nmax) |
arg_spec & | exact (bool ex) |
arg_spec & | nolimit () |
bool | allows_argc (unsigned int objc) const |
unsigned int | argc_min () const |
unsigned int | argc_max () const |
bool | is_exact () const |
By convention, argc_min() and argc_max() INCLUDE the zero'th argument (i.e. the command name) in the arg count. Thus a command that takes no parameters would have an arg count of 1. If is_exact() is true, then the argc of a command invocation is required to be exactly equal either argc_min() or argc_max(); if it is false, then argc must be between argc_min() and argc_max(), inclusive.
Definition at line 49 of file argspec.h.
tcl::arg_spec::arg_spec | ( | int | nmin, | |
int | nmax = -1 , |
|||
bool | ex = false | |||
) | [inline, explicit] |