Index: doc/cmdr_vcommon.man ================================================================== --- doc/cmdr_vcommon.man +++ doc/cmdr_vcommon.man @@ -12,17 +12,96 @@ The standard validation types defined in package [package cmdr::validate] make use of these commands. [section API] -[list_begin definitions] -[comment {- - -- --- ----- -------- -------------}] -[call [cmd ::cmdr::validate::common] [method fail] [arg p] [arg code] [arg type] [arg x]] +[list_begin definitions][comment {-- begin api definitions --}] + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::common] [method fail] \ + [arg p] [arg code] [arg type] [arg x] [opt [arg context]]] + +When invoked this command throws an error indicating a validation type +failure. The arguments provide the information used to construct both +error message and code. + +[para] The generated string has the form: +[example { + Expected $type for $p.type "$x"$context, got "$x" +}] + +[list_begin arguments] +[arg_def [package cmdr::parameter] p] +The [package cmdr::parameter] instance whose validation failed. The +error message will contain this parameter's type and label (flag in +case of an option). + +[arg_def list code] +A list providing additional elements for the error code, detailing the +internal name of the validation type triggering the error. + +[arg_def string type] +A string providing the human-readable name of the validation type +triggering the error. + +[arg_def string x] +The string value failing the validation. + +[arg_def string context] +Additional context to show in the message. Defaults to the empty string. +[list_end] + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::common] [method fail-unknown-thing] \ + [arg p] [arg code] [arg type] [arg x] [opt [arg context]]] + +When invoked this command throws an error indicating a validation type +failure. The arguments provide the information used to construct both +error message and code. + +[para] The generated string has the form: +[example { + Found a problem with $p.type "$p.the-name": + A(n) $type named "$x" does not exist$context. + Please use a different value. +}] + +[list_begin arguments] +[arg_def [package cmdr::parameter] p] +The [package cmdr::parameter] instance whose validation failed. The +error message will contain this parameter's type and label (flag in +case of an option). + +[arg_def list code] +A list providing additional elements for the error code, detailing the +internal name of the validation type triggering the error. + +[arg_def string type] +A string providing the human-readable name of the validation type +triggering the error. + +[arg_def string x] +The string value failing the validation. + +[arg_def string context] +Additional context to show in the message. Defaults to the empty string. +[list_end] + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::common] [method fail-known-thing] \ + [arg p] [arg code] [arg type] [arg x] [opt [arg context]]] When invoked this command throws an error indicating a validation type failure. The arguments provide the information used to construct both error message and code. + +[para] The generated string has the form: +[example { + Found a problem with $p.type "$p.the-name": + A(n) $type named "$x" already exists$context. + Please use a different name. +}] [list_begin arguments] [arg_def [package cmdr::parameter] p] The [package cmdr::parameter] instance whose validation failed. The error message will contain this parameter's type and label (flag in @@ -36,15 +115,18 @@ A string providing the human-readable name of the validation type triggering the error. [arg_def string x] The string value failing the validation. + +[arg_def string context] +Additional context to show in the message. Defaults to the empty string. [list_end] - -[comment {- - -- --- ----- -------- -------------}] -[call [cmd ::cmdr::validate::common] [method complete-enum] [arg choices] [arg nocase] [arg buffer]] +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::common] [method complete-enum] \ + [arg choices] [arg nocase] [arg buffer]] When invoked this command returns a list of strings containing just the elements of [arg choices] the value of [arg buffer] is a prefix of. When [arg nocase] is set the command will ignore letter case and treat the string in [arg buffer] as all-lowercase. @@ -53,19 +135,40 @@ [arg_def list choices] The list of values which can complete the data in [arg buffer]. [arg_def boolean nocase] A boolean flag specifying if the completion is done ignoring -letter-case ([const true]), or not ([const false])). +letter-case ([const true], [const nocase]), or not ([const false])). + +[arg_def string buffer] +The string to complete via the list of [arg choices]. +[list_end] + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::common] [method complete-substr] \ + [arg choices] [arg nocase] [arg buffer]] + +When invoked this command returns a list of strings containing just +the elements of [arg choices] the value of [arg buffer] is a substring +of. When [arg nocase] is set the command will ignore letter case and +treat the string in [arg buffer] as all-lowercase. + +[list_begin arguments] +[arg_def list choices] +The list of values which can complete the data in [arg buffer]. + +[arg_def boolean nocase] +A boolean flag specifying if the completion is done ignoring +letter-case ([const true], [const nocase]), or not ([const false])). [arg_def string buffer] The string to complete via the list of [arg choices]. - [list_end] -[comment {- - -- --- ----- -------- -------------}] -[call [cmd ::cmdr::validate::common] [method complete-glob] [arg filter] [arg buffer]] +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::common] [method complete-glob] \ + [arg filter] [arg buffer]] When invoked this command returns a list of strings, the paths in the filesystem the value of [arg buffer] is a prefix of, and not rejected by the [arg filter] command (prefix). @@ -81,8 +184,59 @@ [arg_def string buffer] The string, a partial path, to complete. [list_end] +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::common] [method ok-directory] \ + [arg path]] + +When invoked this command checks if the specified [arg path] is +suitable as a directory and returns the boolean value [const true] if +so, and [const false] else. + +[para] for the [arg path] to be suitable the following conditions must hold: +[list_begin enumerated] +[enum] If the [arg path] exists: +[list_begin enumerated] +[enum] The path has to refer to a directory. +[enum] The referenced directory must be writable. +[list_end] +[enum] Else: +[list_begin enumerated] +[enum] The parent path has to pass [cmd ok-directory]. +[enum] The above recursion stops at the root directory, and then fails. +[list_end] +[list_end] + +[list_begin arguments] +[arg_def string path] +The path to check. +[list_end] + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::common] [method lead-in] \ + [arg text]] + +A utility command supporting the construction of error messages. Given the +[arg text] the command returns a modified text with a proper prefix of +either [const A] or [const An]. + +[para] The basic heuristics is to use [const An] if [arg text] begins with +a vocal, and [const A] otherwise. This heuristic is bypassed if the the +[arg text] already has a prefix of [const An] or [const A] separated by a +space from the remainder of the string. In that case the [arg text] is +returned as-is. + +[para] This command is used by [cmd fail], [cmd fail-known-thing] and +[cmd fail-unknown-thing] provided by this package. All apply it to their +[arg type] argument. + +[list_begin arguments] +[arg_def string text] +The string to prefix with a leading [const A] or [const An]. [list_end] + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[list_end][comment {-- end api definitions --}] [include parts/feedback.inc] [manpage_end] ADDED doc/cmdr_vt_date.man Index: doc/cmdr_vt_date.man ================================================================== --- /dev/null +++ doc/cmdr_vt_date.man @@ -0,0 +1,37 @@ +[comment {-*- tcl -*- doctools manpage}] +[include parts/definitions.inc] +[manpage_begin [vset LABEL_VT_DATE] [vset MAN_SECTION] [vset VERSION]] +[include parts/module.inc] +[require try] +[require clock::iso8601] +[require cmdr::validate::common] +[require cmdr::validate::date] +[titledesc [vset TITLE_VT_DATE]] +[description] +[include parts/welcome.inc] + +[para] This package provides the validation type +[cmd ::cmdr::validate::date] which accepts dates in ISO 8601 syntax. + +[para] The internal representation is the epoch for the validated +input, at midnight. + +[para] The type has no input completion. + +[para] The details of the exported standard API can be found in +[term [vset TITLE_DEV_VT]]. The chosen default is "today". + +[para] A single non-standard method is provided: + +[list_begin definitions][comment {-- begin api definitions --}] +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::date] [method 2external] [arg epoch]] + +This method converts the epoch of a date to the form %Y-%m-%d and +returns the conversion result as its own. + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[list_end][comment {-- end api definitions --}] + +[include parts/feedback.inc] +[manpage_end] ADDED doc/cmdr_vt_posint.man Index: doc/cmdr_vt_posint.man ================================================================== --- /dev/null +++ doc/cmdr_vt_posint.man @@ -0,0 +1,23 @@ +[comment {-*- tcl -*- doctools manpage}] +[include parts/definitions.inc] +[manpage_begin [vset LABEL_VT_POSINT] [vset MAN_SECTION] [vset VERSION]] +[include parts/module.inc] +[require cmdr::validate::posint] +[titledesc [vset TITLE_VT_POSINT]] +[description] +[include parts/welcome.inc] + +[para] This package provides the validation type +[cmd ::cmdr::validate::posint] which accepts any positive integer +number, i.e. any integer greater than zero. + +[para] The internal representation is the decimal representation of +the validated input. + +[para] The type has no input completion. + +[para] The details of the exported API can be found in +[term [vset TITLE_DEV_VT]]. The chosen default is [const 1]. + +[include parts/feedback.inc] +[manpage_end] ADDED doc/cmdr_vt_time.man Index: doc/cmdr_vt_time.man ================================================================== --- /dev/null +++ doc/cmdr_vt_time.man @@ -0,0 +1,38 @@ +[comment {-*- tcl -*- doctools manpage}] +[include parts/definitions.inc] +[manpage_begin [vset LABEL_VT_TIME] [vset MAN_SECTION] [vset VERSION]] +[include parts/module.inc] +[require try] +[require clock::iso8601] +[require cmdr::validate::common] +[require cmdr::validate::time] +[titledesc [vset TITLE_VT_TIME]] +[description] +[include parts/welcome.inc] + +[para] This package provides the validation type +[cmd ::cmdr::validate::time] which accepts timestamps in ISO 8601 +syntax. + +[para] The internal representation is the epoch for the validated +input. + +[para] The type has no input completion. + +[para] The details of the exported standard API can be found in +[term [vset TITLE_DEV_VT]]. The chosen default is "now". + +[para] A single non-standard method is provided: + +[list_begin definitions][comment {-- begin api definitions --}] +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::time] [method 2external] [arg epoch]] + +This method converts the epoch of a time to the form %H:%M:%S and +returns the conversion result as its own. + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[list_end][comment {-- end api definitions --}] + +[include parts/feedback.inc] +[manpage_end] ADDED doc/cmdr_vt_weekday.man Index: doc/cmdr_vt_weekday.man ================================================================== --- /dev/null +++ doc/cmdr_vt_weekday.man @@ -0,0 +1,38 @@ +[comment {-*- tcl -*- doctools manpage}] +[include parts/definitions.inc] +[manpage_begin [vset LABEL_VT_WEEKDAY] [vset MAN_SECTION] [vset VERSION]] +[include parts/module.inc] +[require try] +[require clock::iso8601] +[require cmdr::validate::common] +[require cmdr::validate::weekday] +[titledesc [vset TITLE_VT_WEEKDAY]] +[description] +[include parts/welcome.inc] + +[para] This package provides the validation type +[cmd ::cmdr::validate::weekday] which accepts weekdays as names and +numbers. + +[para] The internal representation is the numeric weekday for the +validated input where [const 1] to [const 7] map to Monday to Sunday. + +[para] The type has no input completion. + +[para] The details of the exported standard API can be found in +[term [vset TITLE_DEV_VT]]. The chosen default is "today's weekday". + +[para] A single non-standard method is provided: + +[list_begin definitions][comment {-- begin api definitions --}] +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[call [cmd ::cmdr::validate::time] [method 2external] [arg weekday]] + +This method converts the numeric weekday to the form %A and returns +the conversion result as its own. + +[comment {- - -- --- ----- -------- ------------- ---------------------}] +[list_end][comment {-- end api definitions --}] + +[include parts/feedback.inc] +[manpage_end] ADDED doc/cmdr_vt_year.man Index: doc/cmdr_vt_year.man ================================================================== --- /dev/null +++ doc/cmdr_vt_year.man @@ -0,0 +1,23 @@ +[comment {-*- tcl -*- doctools manpage}] +[include parts/definitions.inc] +[manpage_begin [vset LABEL_VT_YEAR] [vset MAN_SECTION] [vset VERSION]] +[include parts/module.inc] +[require cmdr::validate::year] +[titledesc [vset TITLE_VT_YEAR]] +[description] +[include parts/welcome.inc] + +[para] This package provides the validation type +[cmd ::cmdr::validate::year] which accepts both short (2 digit) and +long (4 digit) year numbers. + +[para] The internal representation is the full number of the validated +input, i.e always 4 digits. + +[para] The type has no input completion. + +[para] The details of the exported API can be found in +[term [vset TITLE_DEV_VT]]. The chosen default is the "current year". + +[include parts/feedback.inc] +[manpage_end] Index: doc/parts/definitions.inc ================================================================== --- doc/parts/definitions.inc +++ doc/parts/definitions.inc @@ -32,10 +32,16 @@ [vset TITLE_UTIL "[vset PTITLE] - (Internal) General Utilities"] [vset TITLE_VALIDATE "[vset PTITLE] - Standard validation types for parameters"] [vset TITLE_VCOMMON "[vset PTITLE] - Utilities for Validation Types"] [vset TITLE_FLOW "[vset PTITLE] - Runtime Processing Flow"] +[vset TITLE_VT_YEAR "[vset PTITLE] - Validation type for years"] +[vset TITLE_VT_WEEKDAY "[vset PTITLE] - Validation type for weekday names"] +[vset TITLE_VT_TIME "[vset PTITLE] - Validation type for times"] +[vset TITLE_VT_POSINT "[vset PTITLE] - Validation type for positive integers"] +[vset TITLE_VT_DATE "[vset PTITLE] - Validation type for dates"] + [comment {- Miscellanea ............. - - -- --- ----- --------}] [vset LABEL_INTRO [vset PROJECT]-introduction] [vset LABEL_LICENSE [vset PROJECT]-license] [vset LABEL_CHANGES [vset PROJECT]-changes] [vset LABEL_SOURCES [vset PROJECT]-howto-get-sources] @@ -66,5 +72,11 @@ [vset LABEL_TTY [vset PROJECT]::tty] [vset LABEL_UTIL [vset PROJECT]::util] [vset LABEL_VALIDATE [vset PROJECT]::validate] [vset LABEL_VCOMMON [vset PROJECT]::validate::common] [vset LABEL_FLOW [vset PROJECT]-spec-flow] + +[vset LABEL_VT_YEAR [vset PROJECT]::validate::year] +[vset LABEL_VT_WEEKDAY [vset PROJECT]::validate::weekday] +[vset LABEL_VT_TIME [vset PROJECT]::validate::time] +[vset LABEL_VT_POSINT [vset PROJECT]::validate::posint] +[vset LABEL_VT_DATE [vset PROJECT]::validate::date] Index: embedded/man/files/cmdr_vcommon.n ================================================================== --- embedded/man/files/cmdr_vcommon.n +++ embedded/man/files/cmdr_vcommon.n @@ -275,15 +275,25 @@ .SH NAME cmdr::validate::common \- Cmdr - Utilities for Validation Types .SH SYNOPSIS package require \fBcmdr::validate::common \fR .sp -\fB::cmdr::validate::common\fR \fBfail\fR \fIp\fR \fIcode\fR \fItype\fR \fIx\fR +\fB::cmdr::validate::common\fR \fBfail\fR \fIp\fR \fIcode\fR \fItype\fR \fIx\fR ?\fIcontext\fR? +.sp +\fB::cmdr::validate::common\fR \fBfail-unknown-thing\fR \fIp\fR \fIcode\fR \fItype\fR \fIx\fR ?\fIcontext\fR? +.sp +\fB::cmdr::validate::common\fR \fBfail-known-thing\fR \fIp\fR \fIcode\fR \fItype\fR \fIx\fR ?\fIcontext\fR? .sp \fB::cmdr::validate::common\fR \fBcomplete-enum\fR \fIchoices\fR \fInocase\fR \fIbuffer\fR .sp +\fB::cmdr::validate::common\fR \fBcomplete-substr\fR \fIchoices\fR \fInocase\fR \fIbuffer\fR +.sp \fB::cmdr::validate::common\fR \fBcomplete-glob\fR \fIfilter\fR \fIbuffer\fR +.sp +\fB::cmdr::validate::common\fR \fBok-directory\fR \fIpath\fR +.sp +\fB::cmdr::validate::common\fR \fBlead-in\fR \fItext\fR .sp .BE .SH DESCRIPTION .PP Welcome to the Cmdr project, written by Andreas Kupries\&. @@ -294,14 +304,94 @@ implementation of validation types\&. The standard validation types defined in package \fBcmdr::validate\fR make use of these commands\&. .SH API .TP -\fB::cmdr::validate::common\fR \fBfail\fR \fIp\fR \fIcode\fR \fItype\fR \fIx\fR +\fB::cmdr::validate::common\fR \fBfail\fR \fIp\fR \fIcode\fR \fItype\fR \fIx\fR ?\fIcontext\fR? +When invoked this command throws an error indicating a validation type +failure\&. The arguments provide the information used to construct both +error message and code\&. +.sp +The generated string has the form: +.CS + + + Expected $type for $p\&.type "$x"$context, got "$x" + +.CE +.RS +.TP +\fBcmdr::parameter\fR \fIp\fR +The \fBcmdr::parameter\fR instance whose validation failed\&. The +error message will contain this parameter's type and label (flag in +case of an option)\&. +.TP +list \fIcode\fR +A list providing additional elements for the error code, detailing the +internal name of the validation type triggering the error\&. +.TP +string \fItype\fR +A string providing the human-readable name of the validation type +triggering the error\&. +.TP +string \fIx\fR +The string value failing the validation\&. +.TP +string \fIcontext\fR +Additional context to show in the message\&. Defaults to the empty string\&. +.RE +.TP +\fB::cmdr::validate::common\fR \fBfail-unknown-thing\fR \fIp\fR \fIcode\fR \fItype\fR \fIx\fR ?\fIcontext\fR? +When invoked this command throws an error indicating a validation type +failure\&. The arguments provide the information used to construct both +error message and code\&. +.sp +The generated string has the form: +.CS + + + Found a problem with $p\&.type "$p\&.the-name": + A(n) $type named "$x" does not exist$context\&. + Please use a different value\&. + +.CE +.RS +.TP +\fBcmdr::parameter\fR \fIp\fR +The \fBcmdr::parameter\fR instance whose validation failed\&. The +error message will contain this parameter's type and label (flag in +case of an option)\&. +.TP +list \fIcode\fR +A list providing additional elements for the error code, detailing the +internal name of the validation type triggering the error\&. +.TP +string \fItype\fR +A string providing the human-readable name of the validation type +triggering the error\&. +.TP +string \fIx\fR +The string value failing the validation\&. +.TP +string \fIcontext\fR +Additional context to show in the message\&. Defaults to the empty string\&. +.RE +.TP +\fB::cmdr::validate::common\fR \fBfail-known-thing\fR \fIp\fR \fIcode\fR \fItype\fR \fIx\fR ?\fIcontext\fR? When invoked this command throws an error indicating a validation type failure\&. The arguments provide the information used to construct both error message and code\&. +.sp +The generated string has the form: +.CS + + + Found a problem with $p\&.type "$p\&.the-name": + A(n) $type named "$x" already exists$context\&. + Please use a different name\&. + +.CE .RS .TP \fBcmdr::parameter\fR \fIp\fR The \fBcmdr::parameter\fR instance whose validation failed\&. The error message will contain this parameter's type and label (flag in @@ -315,10 +405,13 @@ A string providing the human-readable name of the validation type triggering the error\&. .TP string \fIx\fR The string value failing the validation\&. +.TP +string \fIcontext\fR +Additional context to show in the message\&. Defaults to the empty string\&. .RE .TP \fB::cmdr::validate::common\fR \fBcomplete-enum\fR \fIchoices\fR \fInocase\fR \fIbuffer\fR When invoked this command returns a list of strings containing just the elements of \fIchoices\fR the value of \fIbuffer\fR is a prefix @@ -329,11 +422,29 @@ list \fIchoices\fR The list of values which can complete the data in \fIbuffer\fR\&. .TP boolean \fInocase\fR A boolean flag specifying if the completion is done ignoring -letter-case (\fBtrue\fR), or not (\fBfalse\fR))\&. +letter-case (\fBtrue\fR, \fBnocase\fR), or not (\fBfalse\fR))\&. +.TP +string \fIbuffer\fR +The string to complete via the list of \fIchoices\fR\&. +.RE +.TP +\fB::cmdr::validate::common\fR \fBcomplete-substr\fR \fIchoices\fR \fInocase\fR \fIbuffer\fR +When invoked this command returns a list of strings containing just +the elements of \fIchoices\fR the value of \fIbuffer\fR is a substring +of\&. When \fInocase\fR is set the command will ignore letter case and +treat the string in \fIbuffer\fR as all-lowercase\&. +.RS +.TP +list \fIchoices\fR +The list of values which can complete the data in \fIbuffer\fR\&. +.TP +boolean \fInocase\fR +A boolean flag specifying if the completion is done ignoring +letter-case (\fBtrue\fR, \fBnocase\fR), or not (\fBfalse\fR))\&. .TP string \fIbuffer\fR The string to complete via the list of \fIchoices\fR\&. .RE .TP @@ -353,10 +464,60 @@ it\&. .TP string \fIbuffer\fR The string, a partial path, to complete\&. .RE +.TP +\fB::cmdr::validate::common\fR \fBok-directory\fR \fIpath\fR +When invoked this command checks if the specified \fIpath\fR is +suitable as a directory and returns the boolean value \fBtrue\fR if +so, and \fBfalse\fR else\&. +.sp +for the \fIpath\fR to be suitable the following conditions must hold: +.RS +.IP [1] +If the \fIpath\fR exists: +.RS +.IP [1] +The path has to refer to a directory\&. +.IP [2] +The referenced directory must be writable\&. +.RE +.IP [2] +Else: +.RS +.IP [1] +The parent path has to pass \fBok-directory\fR\&. +.IP [2] +The above recursion stops at the root directory, and then fails\&. +.RE +.RE +.RS +.TP +string \fIpath\fR +The path to check\&. +.RE +.TP +\fB::cmdr::validate::common\fR \fBlead-in\fR \fItext\fR +A utility command supporting the construction of error messages\&. Given the +\fItext\fR the command returns a modified text with a proper prefix of +either \fBA\fR or \fBAn\fR\&. +.sp +The basic heuristics is to use \fBAn\fR if \fItext\fR begins with +a vocal, and \fBA\fR otherwise\&. This heuristic is bypassed if the the +\fItext\fR already has a prefix of \fBAn\fR or \fBA\fR separated by a +space from the remainder of the string\&. In that case the \fItext\fR is +returned as-is\&. +.sp +This command is used by \fBfail\fR, \fBfail-known-thing\fR and +\fBfail-unknown-thing\fR provided by this package\&. All apply it to their +\fItype\fR argument\&. +.RS +.TP +string \fItext\fR +The string to prefix with a leading \fBA\fR or \fBAn\fR\&. +.RE .PP .SH "BUGS, IDEAS, FEEDBACK" Both the package(s) and this documentation will undoubtedly contain bugs and other problems\&. Please report such at ADDED embedded/man/files/cmdr_vt_date.n Index: embedded/man/files/cmdr_vt_date.n ================================================================== --- /dev/null +++ embedded/man/files/cmdr_vt_date.n @@ -0,0 +1,328 @@ +'\" +'\" Generated from file 'cmdr_vt_date\&.man' by tcllib/doctools with format 'nroff' +'\" Copyright (c) 2013 Andreas Kupries +'\" Copyright (c) 2013 Documentation, Andreas Kupries +'\" +.TH "cmdr::validate::date" n 1\&.1 doc "Cmdr, a framework for command line parsing and dispatch" +.\" The -*- nroff -*- definitions below are for supplemental macros used +.\" in Tcl/Tk manual entries. +.\" +.\" .AP type name in/out ?indent? +.\" Start paragraph describing an argument to a library procedure. +.\" type is type of argument (int, etc.), in/out is either "in", "out", +.\" or "in/out" to describe whether procedure reads or modifies arg, +.\" and indent is equivalent to second arg of .IP (shouldn't ever be +.\" needed; use .AS below instead) +.\" +.\" .AS ?type? ?name? +.\" Give maximum sizes of arguments for setting tab stops. Type and +.\" name are examples of largest possible arguments that will be passed +.\" to .AP later. If args are omitted, default tab stops are used. +.\" +.\" .BS +.\" Start box enclosure. From here until next .BE, everything will be +.\" enclosed in one large box. +.\" +.\" .BE +.\" End of box enclosure. +.\" +.\" .CS +.\" Begin code excerpt. +.\" +.\" .CE +.\" End code excerpt. +.\" +.\" .VS ?version? ?br? +.\" Begin vertical sidebar, for use in marking newly-changed parts +.\" of man pages. The first argument is ignored and used for recording +.\" the version when the .VS was added, so that the sidebars can be +.\" found and removed when they reach a certain age. If another argument +.\" is present, then a line break is forced before starting the sidebar. +.\" +.\" .VE +.\" End of vertical sidebar. +.\" +.\" .DS +.\" Begin an indented unfilled display. +.\" +.\" .DE +.\" End of indented unfilled display. +.\" +.\" .SO ?manpage? +.\" Start of list of standard options for a Tk widget. The manpage +.\" argument defines where to look up the standard options; if +.\" omitted, defaults to "options". The options follow on successive +.\" lines, in three columns separated by tabs. +.\" +.\" .SE +.\" End of list of standard options for a Tk widget. +.\" +.\" .OP cmdName dbName dbClass +.\" Start of description of a specific option. cmdName gives the +.\" option's name as specified in the class command, dbName gives +.\" the option's name in the option database, and dbClass gives +.\" the option's class in the option database. +.\" +.\" .UL arg1 arg2 +.\" Print arg1 underlined, then print arg2 normally. +.\" +.\" .QW arg1 ?arg2? +.\" Print arg1 in quotes, then arg2 normally (for trailing punctuation). +.\" +.\" .PQ arg1 ?arg2? +.\" Print an open parenthesis, arg1 in quotes, then arg2 normally +.\" (for trailing punctuation) and then a closing parenthesis. +.\" +.\" # Set up traps and other miscellaneous stuff for Tcl/Tk man pages. +.if t .wh -1.3i ^B +.nr ^l \n(.l +.ad b +.\" # Start an argument description +.de AP +.ie !"\\$4"" .TP \\$4 +.el \{\ +. ie !"\\$2"" .TP \\n()Cu +. el .TP 15 +.\} +.ta \\n()Au \\n()Bu +.ie !"\\$3"" \{\ +\&\\$1 \\fI\\$2\\fP (\\$3) +.\".b +.\} +.el \{\ +.br +.ie !"\\$2"" \{\ +\&\\$1 \\fI\\$2\\fP +.\} +.el \{\ +\&\\fI\\$1\\fP +.\} +.\} +.. +.\" # define tabbing values for .AP +.de AS +.nr )A 10n +.if !"\\$1"" .nr )A \\w'\\$1'u+3n +.nr )B \\n()Au+15n +.\" +.if !"\\$2"" .nr )B \\w'\\$2'u+\\n()Au+3n +.nr )C \\n()Bu+\\w'(in/out)'u+2n +.. +.AS Tcl_Interp Tcl_CreateInterp in/out +.\" # BS - start boxed text +.\" # ^y = starting y location +.\" # ^b = 1 +.de BS +.br +.mk ^y +.nr ^b 1u +.if n .nf +.if n .ti 0 +.if n \l'\\n(.lu\(ul' +.if n .fi +.. +.\" # BE - end boxed text (draw box now) +.de BE +.nf +.ti 0 +.mk ^t +.ie n \l'\\n(^lu\(ul' +.el \{\ +.\" Draw four-sided box normally, but don't draw top of +.\" box if the box started on an earlier page. +.ie !\\n(^b-1 \{\ +\h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.el \}\ +\h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.\} +.fi +.br +.nr ^b 0 +.. +.\" # VS - start vertical sidebar +.\" # ^Y = starting y location +.\" # ^v = 1 (for troff; for nroff this doesn't matter) +.de VS +.if !"\\$2"" .br +.mk ^Y +.ie n 'mc \s12\(br\s0 +.el .nr ^v 1u +.. +.\" # VE - end of vertical sidebar +.de VE +.ie n 'mc +.el \{\ +.ev 2 +.nf +.ti 0 +.mk ^t +\h'|\\n(^lu+3n'\L'|\\n(^Yu-1v\(bv'\v'\\n(^tu+1v-\\n(^Yu'\h'-|\\n(^lu+3n' +.sp -1 +.fi +.ev +.\} +.nr ^v 0 +.. +.\" # Special macro to handle page bottom: finish off current +.\" # box/sidebar if in box/sidebar mode, then invoked standard +.\" # page bottom macro. +.de ^B +.ev 2 +'ti 0 +'nf +.mk ^t +.if \\n(^b \{\ +.\" Draw three-sided box if this is the box's first page, +.\" draw two sides but no top otherwise. +.ie !\\n(^b-1 \h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.el \h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.\} +.if \\n(^v \{\ +.nr ^x \\n(^tu+1v-\\n(^Yu +\kx\h'-\\nxu'\h'|\\n(^lu+3n'\ky\L'-\\n(^xu'\v'\\n(^xu'\h'|0u'\c +.\} +.bp +'fi +.ev +.if \\n(^b \{\ +.mk ^y +.nr ^b 2 +.\} +.if \\n(^v \{\ +.mk ^Y +.\} +.. +.\" # DS - begin display +.de DS +.RS +.nf +.sp +.. +.\" # DE - end display +.de DE +.fi +.RE +.sp +.. +.\" # SO - start of list of standard options +.de SO +'ie '\\$1'' .ds So \\fBoptions\\fR +'el .ds So \\fB\\$1\\fR +.SH "STANDARD OPTIONS" +.LP +.nf +.ta 5.5c 11c +.ft B +.. +.\" # SE - end of list of standard options +.de SE +.fi +.ft R +.LP +See the \\*(So manual entry for details on the standard options. +.. +.\" # OP - start of full description for a single option +.de OP +.LP +.nf +.ta 4c +Command-Line Name: \\fB\\$1\\fR +Database Name: \\fB\\$2\\fR +Database Class: \\fB\\$3\\fR +.fi +.IP +.. +.\" # CS - begin code excerpt +.de CS +.RS +.nf +.ta .25i .5i .75i 1i +.. +.\" # CE - end code excerpt +.de CE +.fi +.RE +.. +.\" # UL - underline word +.de UL +\\$1\l'|0\(ul'\\$2 +.. +.\" # QW - apply quotation marks to word +.de QW +.ie '\\*(lq'"' ``\\$1''\\$2 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\$2 +.. +.\" # PQ - apply parens and quotation marks to word +.de PQ +.ie '\\*(lq'"' (``\\$1''\\$2)\\$3 +.\"" fix emacs highlighting +.el (\\*(lq\\$1\\*(rq\\$2)\\$3 +.. +.\" # QR - quoted range +.de QR +.ie '\\*(lq'"' ``\\$1''\\-``\\$2''\\$3 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\-\\*(lq\\$2\\*(rq\\$3 +.. +.\" # MT - "empty" string +.de MT +.QW "" +.. +.BS +.SH NAME +cmdr::validate::date \- Cmdr - Validation type for dates +.SH SYNOPSIS +package require \fBtry \fR +.sp +package require \fBclock::iso8601 \fR +.sp +package require \fBcmdr::validate::common \fR +.sp +package require \fBcmdr::validate::date \fR +.sp +\fB::cmdr::validate::date\fR \fB2external\fR \fIepoch\fR +.sp +.BE +.SH DESCRIPTION +.PP +Welcome to the Cmdr project, written by Andreas Kupries\&. +.PP +For availability please read \fICmdr - How To Get The Sources\fR\&. +.PP +.PP +This package provides the validation type +\fB::cmdr::validate::date\fR which accepts dates in ISO 8601 syntax\&. +.PP +The internal representation is the epoch for the validated +input, at midnight\&. +.PP +The type has no input completion\&. +.PP +The details of the exported standard API can be found in +\fICmdr - Writing custom validation types\fR\&. The chosen default is "today"\&. +.PP +A single non-standard method is provided: +.TP +\fB::cmdr::validate::date\fR \fB2external\fR \fIepoch\fR +This method converts the epoch of a date to the form %Y-%m-%d and +returns the conversion result as its own\&. +.PP +.SH "BUGS, IDEAS, FEEDBACK" +Both the package(s) and this documentation will undoubtedly contain +bugs and other problems\&. +Please report such at +\fICmdr Tickets\fR [https:/core\&.tcl\&.tk/akupries/cmdr]\&. +.PP +Please also report any ideas you may have for enhancements of +either package(s) and/or documentation\&. +.SH KEYWORDS +arguments, command hierarchy, command line completion, command line handling, command tree, editing command line, help for command line, hierarchy of commands, interactive command shell, optional arguments, options, parameters, processing command line, tree of commands +.SH COPYRIGHT +.nf +Copyright (c) 2013 Andreas Kupries +Copyright (c) 2013 Documentation, Andreas Kupries + +.fi ADDED embedded/man/files/cmdr_vt_posint.n Index: embedded/man/files/cmdr_vt_posint.n ================================================================== --- /dev/null +++ embedded/man/files/cmdr_vt_posint.n @@ -0,0 +1,314 @@ +'\" +'\" Generated from file 'cmdr_vt_posint\&.man' by tcllib/doctools with format 'nroff' +'\" Copyright (c) 2013 Andreas Kupries +'\" Copyright (c) 2013 Documentation, Andreas Kupries +'\" +.TH "cmdr::validate::posint" n 1\&.1 doc "Cmdr, a framework for command line parsing and dispatch" +.\" The -*- nroff -*- definitions below are for supplemental macros used +.\" in Tcl/Tk manual entries. +.\" +.\" .AP type name in/out ?indent? +.\" Start paragraph describing an argument to a library procedure. +.\" type is type of argument (int, etc.), in/out is either "in", "out", +.\" or "in/out" to describe whether procedure reads or modifies arg, +.\" and indent is equivalent to second arg of .IP (shouldn't ever be +.\" needed; use .AS below instead) +.\" +.\" .AS ?type? ?name? +.\" Give maximum sizes of arguments for setting tab stops. Type and +.\" name are examples of largest possible arguments that will be passed +.\" to .AP later. If args are omitted, default tab stops are used. +.\" +.\" .BS +.\" Start box enclosure. From here until next .BE, everything will be +.\" enclosed in one large box. +.\" +.\" .BE +.\" End of box enclosure. +.\" +.\" .CS +.\" Begin code excerpt. +.\" +.\" .CE +.\" End code excerpt. +.\" +.\" .VS ?version? ?br? +.\" Begin vertical sidebar, for use in marking newly-changed parts +.\" of man pages. The first argument is ignored and used for recording +.\" the version when the .VS was added, so that the sidebars can be +.\" found and removed when they reach a certain age. If another argument +.\" is present, then a line break is forced before starting the sidebar. +.\" +.\" .VE +.\" End of vertical sidebar. +.\" +.\" .DS +.\" Begin an indented unfilled display. +.\" +.\" .DE +.\" End of indented unfilled display. +.\" +.\" .SO ?manpage? +.\" Start of list of standard options for a Tk widget. The manpage +.\" argument defines where to look up the standard options; if +.\" omitted, defaults to "options". The options follow on successive +.\" lines, in three columns separated by tabs. +.\" +.\" .SE +.\" End of list of standard options for a Tk widget. +.\" +.\" .OP cmdName dbName dbClass +.\" Start of description of a specific option. cmdName gives the +.\" option's name as specified in the class command, dbName gives +.\" the option's name in the option database, and dbClass gives +.\" the option's class in the option database. +.\" +.\" .UL arg1 arg2 +.\" Print arg1 underlined, then print arg2 normally. +.\" +.\" .QW arg1 ?arg2? +.\" Print arg1 in quotes, then arg2 normally (for trailing punctuation). +.\" +.\" .PQ arg1 ?arg2? +.\" Print an open parenthesis, arg1 in quotes, then arg2 normally +.\" (for trailing punctuation) and then a closing parenthesis. +.\" +.\" # Set up traps and other miscellaneous stuff for Tcl/Tk man pages. +.if t .wh -1.3i ^B +.nr ^l \n(.l +.ad b +.\" # Start an argument description +.de AP +.ie !"\\$4"" .TP \\$4 +.el \{\ +. ie !"\\$2"" .TP \\n()Cu +. el .TP 15 +.\} +.ta \\n()Au \\n()Bu +.ie !"\\$3"" \{\ +\&\\$1 \\fI\\$2\\fP (\\$3) +.\".b +.\} +.el \{\ +.br +.ie !"\\$2"" \{\ +\&\\$1 \\fI\\$2\\fP +.\} +.el \{\ +\&\\fI\\$1\\fP +.\} +.\} +.. +.\" # define tabbing values for .AP +.de AS +.nr )A 10n +.if !"\\$1"" .nr )A \\w'\\$1'u+3n +.nr )B \\n()Au+15n +.\" +.if !"\\$2"" .nr )B \\w'\\$2'u+\\n()Au+3n +.nr )C \\n()Bu+\\w'(in/out)'u+2n +.. +.AS Tcl_Interp Tcl_CreateInterp in/out +.\" # BS - start boxed text +.\" # ^y = starting y location +.\" # ^b = 1 +.de BS +.br +.mk ^y +.nr ^b 1u +.if n .nf +.if n .ti 0 +.if n \l'\\n(.lu\(ul' +.if n .fi +.. +.\" # BE - end boxed text (draw box now) +.de BE +.nf +.ti 0 +.mk ^t +.ie n \l'\\n(^lu\(ul' +.el \{\ +.\" Draw four-sided box normally, but don't draw top of +.\" box if the box started on an earlier page. +.ie !\\n(^b-1 \{\ +\h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.el \}\ +\h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.\} +.fi +.br +.nr ^b 0 +.. +.\" # VS - start vertical sidebar +.\" # ^Y = starting y location +.\" # ^v = 1 (for troff; for nroff this doesn't matter) +.de VS +.if !"\\$2"" .br +.mk ^Y +.ie n 'mc \s12\(br\s0 +.el .nr ^v 1u +.. +.\" # VE - end of vertical sidebar +.de VE +.ie n 'mc +.el \{\ +.ev 2 +.nf +.ti 0 +.mk ^t +\h'|\\n(^lu+3n'\L'|\\n(^Yu-1v\(bv'\v'\\n(^tu+1v-\\n(^Yu'\h'-|\\n(^lu+3n' +.sp -1 +.fi +.ev +.\} +.nr ^v 0 +.. +.\" # Special macro to handle page bottom: finish off current +.\" # box/sidebar if in box/sidebar mode, then invoked standard +.\" # page bottom macro. +.de ^B +.ev 2 +'ti 0 +'nf +.mk ^t +.if \\n(^b \{\ +.\" Draw three-sided box if this is the box's first page, +.\" draw two sides but no top otherwise. +.ie !\\n(^b-1 \h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.el \h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.\} +.if \\n(^v \{\ +.nr ^x \\n(^tu+1v-\\n(^Yu +\kx\h'-\\nxu'\h'|\\n(^lu+3n'\ky\L'-\\n(^xu'\v'\\n(^xu'\h'|0u'\c +.\} +.bp +'fi +.ev +.if \\n(^b \{\ +.mk ^y +.nr ^b 2 +.\} +.if \\n(^v \{\ +.mk ^Y +.\} +.. +.\" # DS - begin display +.de DS +.RS +.nf +.sp +.. +.\" # DE - end display +.de DE +.fi +.RE +.sp +.. +.\" # SO - start of list of standard options +.de SO +'ie '\\$1'' .ds So \\fBoptions\\fR +'el .ds So \\fB\\$1\\fR +.SH "STANDARD OPTIONS" +.LP +.nf +.ta 5.5c 11c +.ft B +.. +.\" # SE - end of list of standard options +.de SE +.fi +.ft R +.LP +See the \\*(So manual entry for details on the standard options. +.. +.\" # OP - start of full description for a single option +.de OP +.LP +.nf +.ta 4c +Command-Line Name: \\fB\\$1\\fR +Database Name: \\fB\\$2\\fR +Database Class: \\fB\\$3\\fR +.fi +.IP +.. +.\" # CS - begin code excerpt +.de CS +.RS +.nf +.ta .25i .5i .75i 1i +.. +.\" # CE - end code excerpt +.de CE +.fi +.RE +.. +.\" # UL - underline word +.de UL +\\$1\l'|0\(ul'\\$2 +.. +.\" # QW - apply quotation marks to word +.de QW +.ie '\\*(lq'"' ``\\$1''\\$2 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\$2 +.. +.\" # PQ - apply parens and quotation marks to word +.de PQ +.ie '\\*(lq'"' (``\\$1''\\$2)\\$3 +.\"" fix emacs highlighting +.el (\\*(lq\\$1\\*(rq\\$2)\\$3 +.. +.\" # QR - quoted range +.de QR +.ie '\\*(lq'"' ``\\$1''\\-``\\$2''\\$3 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\-\\*(lq\\$2\\*(rq\\$3 +.. +.\" # MT - "empty" string +.de MT +.QW "" +.. +.BS +.SH NAME +cmdr::validate::posint \- Cmdr - Validation type for positive integers +.SH SYNOPSIS +package require \fBcmdr::validate::posint \fR +.sp +.BE +.SH DESCRIPTION +.PP +Welcome to the Cmdr project, written by Andreas Kupries\&. +.PP +For availability please read \fICmdr - How To Get The Sources\fR\&. +.PP +.PP +This package provides the validation type +\fB::cmdr::validate::posint\fR which accepts any positive integer +number, i\&.e\&. any integer greater than zero\&. +.PP +The internal representation is the decimal representation of +the validated input\&. +.PP +The type has no input completion\&. +.PP +The details of the exported API can be found in +\fICmdr - Writing custom validation types\fR\&. The chosen default is \fB1\fR\&. +.SH "BUGS, IDEAS, FEEDBACK" +Both the package(s) and this documentation will undoubtedly contain +bugs and other problems\&. +Please report such at +\fICmdr Tickets\fR [https:/core\&.tcl\&.tk/akupries/cmdr]\&. +.PP +Please also report any ideas you may have for enhancements of +either package(s) and/or documentation\&. +.SH KEYWORDS +arguments, command hierarchy, command line completion, command line handling, command tree, editing command line, help for command line, hierarchy of commands, interactive command shell, optional arguments, options, parameters, processing command line, tree of commands +.SH COPYRIGHT +.nf +Copyright (c) 2013 Andreas Kupries +Copyright (c) 2013 Documentation, Andreas Kupries + +.fi ADDED embedded/man/files/cmdr_vt_time.n Index: embedded/man/files/cmdr_vt_time.n ================================================================== --- /dev/null +++ embedded/man/files/cmdr_vt_time.n @@ -0,0 +1,329 @@ +'\" +'\" Generated from file 'cmdr_vt_time\&.man' by tcllib/doctools with format 'nroff' +'\" Copyright (c) 2013 Andreas Kupries +'\" Copyright (c) 2013 Documentation, Andreas Kupries +'\" +.TH "cmdr::validate::time" n 1\&.1 doc "Cmdr, a framework for command line parsing and dispatch" +.\" The -*- nroff -*- definitions below are for supplemental macros used +.\" in Tcl/Tk manual entries. +.\" +.\" .AP type name in/out ?indent? +.\" Start paragraph describing an argument to a library procedure. +.\" type is type of argument (int, etc.), in/out is either "in", "out", +.\" or "in/out" to describe whether procedure reads or modifies arg, +.\" and indent is equivalent to second arg of .IP (shouldn't ever be +.\" needed; use .AS below instead) +.\" +.\" .AS ?type? ?name? +.\" Give maximum sizes of arguments for setting tab stops. Type and +.\" name are examples of largest possible arguments that will be passed +.\" to .AP later. If args are omitted, default tab stops are used. +.\" +.\" .BS +.\" Start box enclosure. From here until next .BE, everything will be +.\" enclosed in one large box. +.\" +.\" .BE +.\" End of box enclosure. +.\" +.\" .CS +.\" Begin code excerpt. +.\" +.\" .CE +.\" End code excerpt. +.\" +.\" .VS ?version? ?br? +.\" Begin vertical sidebar, for use in marking newly-changed parts +.\" of man pages. The first argument is ignored and used for recording +.\" the version when the .VS was added, so that the sidebars can be +.\" found and removed when they reach a certain age. If another argument +.\" is present, then a line break is forced before starting the sidebar. +.\" +.\" .VE +.\" End of vertical sidebar. +.\" +.\" .DS +.\" Begin an indented unfilled display. +.\" +.\" .DE +.\" End of indented unfilled display. +.\" +.\" .SO ?manpage? +.\" Start of list of standard options for a Tk widget. The manpage +.\" argument defines where to look up the standard options; if +.\" omitted, defaults to "options". The options follow on successive +.\" lines, in three columns separated by tabs. +.\" +.\" .SE +.\" End of list of standard options for a Tk widget. +.\" +.\" .OP cmdName dbName dbClass +.\" Start of description of a specific option. cmdName gives the +.\" option's name as specified in the class command, dbName gives +.\" the option's name in the option database, and dbClass gives +.\" the option's class in the option database. +.\" +.\" .UL arg1 arg2 +.\" Print arg1 underlined, then print arg2 normally. +.\" +.\" .QW arg1 ?arg2? +.\" Print arg1 in quotes, then arg2 normally (for trailing punctuation). +.\" +.\" .PQ arg1 ?arg2? +.\" Print an open parenthesis, arg1 in quotes, then arg2 normally +.\" (for trailing punctuation) and then a closing parenthesis. +.\" +.\" # Set up traps and other miscellaneous stuff for Tcl/Tk man pages. +.if t .wh -1.3i ^B +.nr ^l \n(.l +.ad b +.\" # Start an argument description +.de AP +.ie !"\\$4"" .TP \\$4 +.el \{\ +. ie !"\\$2"" .TP \\n()Cu +. el .TP 15 +.\} +.ta \\n()Au \\n()Bu +.ie !"\\$3"" \{\ +\&\\$1 \\fI\\$2\\fP (\\$3) +.\".b +.\} +.el \{\ +.br +.ie !"\\$2"" \{\ +\&\\$1 \\fI\\$2\\fP +.\} +.el \{\ +\&\\fI\\$1\\fP +.\} +.\} +.. +.\" # define tabbing values for .AP +.de AS +.nr )A 10n +.if !"\\$1"" .nr )A \\w'\\$1'u+3n +.nr )B \\n()Au+15n +.\" +.if !"\\$2"" .nr )B \\w'\\$2'u+\\n()Au+3n +.nr )C \\n()Bu+\\w'(in/out)'u+2n +.. +.AS Tcl_Interp Tcl_CreateInterp in/out +.\" # BS - start boxed text +.\" # ^y = starting y location +.\" # ^b = 1 +.de BS +.br +.mk ^y +.nr ^b 1u +.if n .nf +.if n .ti 0 +.if n \l'\\n(.lu\(ul' +.if n .fi +.. +.\" # BE - end boxed text (draw box now) +.de BE +.nf +.ti 0 +.mk ^t +.ie n \l'\\n(^lu\(ul' +.el \{\ +.\" Draw four-sided box normally, but don't draw top of +.\" box if the box started on an earlier page. +.ie !\\n(^b-1 \{\ +\h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.el \}\ +\h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.\} +.fi +.br +.nr ^b 0 +.. +.\" # VS - start vertical sidebar +.\" # ^Y = starting y location +.\" # ^v = 1 (for troff; for nroff this doesn't matter) +.de VS +.if !"\\$2"" .br +.mk ^Y +.ie n 'mc \s12\(br\s0 +.el .nr ^v 1u +.. +.\" # VE - end of vertical sidebar +.de VE +.ie n 'mc +.el \{\ +.ev 2 +.nf +.ti 0 +.mk ^t +\h'|\\n(^lu+3n'\L'|\\n(^Yu-1v\(bv'\v'\\n(^tu+1v-\\n(^Yu'\h'-|\\n(^lu+3n' +.sp -1 +.fi +.ev +.\} +.nr ^v 0 +.. +.\" # Special macro to handle page bottom: finish off current +.\" # box/sidebar if in box/sidebar mode, then invoked standard +.\" # page bottom macro. +.de ^B +.ev 2 +'ti 0 +'nf +.mk ^t +.if \\n(^b \{\ +.\" Draw three-sided box if this is the box's first page, +.\" draw two sides but no top otherwise. +.ie !\\n(^b-1 \h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.el \h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.\} +.if \\n(^v \{\ +.nr ^x \\n(^tu+1v-\\n(^Yu +\kx\h'-\\nxu'\h'|\\n(^lu+3n'\ky\L'-\\n(^xu'\v'\\n(^xu'\h'|0u'\c +.\} +.bp +'fi +.ev +.if \\n(^b \{\ +.mk ^y +.nr ^b 2 +.\} +.if \\n(^v \{\ +.mk ^Y +.\} +.. +.\" # DS - begin display +.de DS +.RS +.nf +.sp +.. +.\" # DE - end display +.de DE +.fi +.RE +.sp +.. +.\" # SO - start of list of standard options +.de SO +'ie '\\$1'' .ds So \\fBoptions\\fR +'el .ds So \\fB\\$1\\fR +.SH "STANDARD OPTIONS" +.LP +.nf +.ta 5.5c 11c +.ft B +.. +.\" # SE - end of list of standard options +.de SE +.fi +.ft R +.LP +See the \\*(So manual entry for details on the standard options. +.. +.\" # OP - start of full description for a single option +.de OP +.LP +.nf +.ta 4c +Command-Line Name: \\fB\\$1\\fR +Database Name: \\fB\\$2\\fR +Database Class: \\fB\\$3\\fR +.fi +.IP +.. +.\" # CS - begin code excerpt +.de CS +.RS +.nf +.ta .25i .5i .75i 1i +.. +.\" # CE - end code excerpt +.de CE +.fi +.RE +.. +.\" # UL - underline word +.de UL +\\$1\l'|0\(ul'\\$2 +.. +.\" # QW - apply quotation marks to word +.de QW +.ie '\\*(lq'"' ``\\$1''\\$2 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\$2 +.. +.\" # PQ - apply parens and quotation marks to word +.de PQ +.ie '\\*(lq'"' (``\\$1''\\$2)\\$3 +.\"" fix emacs highlighting +.el (\\*(lq\\$1\\*(rq\\$2)\\$3 +.. +.\" # QR - quoted range +.de QR +.ie '\\*(lq'"' ``\\$1''\\-``\\$2''\\$3 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\-\\*(lq\\$2\\*(rq\\$3 +.. +.\" # MT - "empty" string +.de MT +.QW "" +.. +.BS +.SH NAME +cmdr::validate::time \- Cmdr - Validation type for times +.SH SYNOPSIS +package require \fBtry \fR +.sp +package require \fBclock::iso8601 \fR +.sp +package require \fBcmdr::validate::common \fR +.sp +package require \fBcmdr::validate::time \fR +.sp +\fB::cmdr::validate::time\fR \fB2external\fR \fIepoch\fR +.sp +.BE +.SH DESCRIPTION +.PP +Welcome to the Cmdr project, written by Andreas Kupries\&. +.PP +For availability please read \fICmdr - How To Get The Sources\fR\&. +.PP +.PP +This package provides the validation type +\fB::cmdr::validate::time\fR which accepts timestamps in ISO 8601 +syntax\&. +.PP +The internal representation is the epoch for the validated +input\&. +.PP +The type has no input completion\&. +.PP +The details of the exported standard API can be found in +\fICmdr - Writing custom validation types\fR\&. The chosen default is "now"\&. +.PP +A single non-standard method is provided: +.TP +\fB::cmdr::validate::time\fR \fB2external\fR \fIepoch\fR +This method converts the epoch of a time to the form %H:%M:%S and +returns the conversion result as its own\&. +.PP +.SH "BUGS, IDEAS, FEEDBACK" +Both the package(s) and this documentation will undoubtedly contain +bugs and other problems\&. +Please report such at +\fICmdr Tickets\fR [https:/core\&.tcl\&.tk/akupries/cmdr]\&. +.PP +Please also report any ideas you may have for enhancements of +either package(s) and/or documentation\&. +.SH KEYWORDS +arguments, command hierarchy, command line completion, command line handling, command tree, editing command line, help for command line, hierarchy of commands, interactive command shell, optional arguments, options, parameters, processing command line, tree of commands +.SH COPYRIGHT +.nf +Copyright (c) 2013 Andreas Kupries +Copyright (c) 2013 Documentation, Andreas Kupries + +.fi ADDED embedded/man/files/cmdr_vt_weekday.n Index: embedded/man/files/cmdr_vt_weekday.n ================================================================== --- /dev/null +++ embedded/man/files/cmdr_vt_weekday.n @@ -0,0 +1,329 @@ +'\" +'\" Generated from file 'cmdr_vt_weekday\&.man' by tcllib/doctools with format 'nroff' +'\" Copyright (c) 2013 Andreas Kupries +'\" Copyright (c) 2013 Documentation, Andreas Kupries +'\" +.TH "cmdr::validate::weekday" n 1\&.1 doc "Cmdr, a framework for command line parsing and dispatch" +.\" The -*- nroff -*- definitions below are for supplemental macros used +.\" in Tcl/Tk manual entries. +.\" +.\" .AP type name in/out ?indent? +.\" Start paragraph describing an argument to a library procedure. +.\" type is type of argument (int, etc.), in/out is either "in", "out", +.\" or "in/out" to describe whether procedure reads or modifies arg, +.\" and indent is equivalent to second arg of .IP (shouldn't ever be +.\" needed; use .AS below instead) +.\" +.\" .AS ?type? ?name? +.\" Give maximum sizes of arguments for setting tab stops. Type and +.\" name are examples of largest possible arguments that will be passed +.\" to .AP later. If args are omitted, default tab stops are used. +.\" +.\" .BS +.\" Start box enclosure. From here until next .BE, everything will be +.\" enclosed in one large box. +.\" +.\" .BE +.\" End of box enclosure. +.\" +.\" .CS +.\" Begin code excerpt. +.\" +.\" .CE +.\" End code excerpt. +.\" +.\" .VS ?version? ?br? +.\" Begin vertical sidebar, for use in marking newly-changed parts +.\" of man pages. The first argument is ignored and used for recording +.\" the version when the .VS was added, so that the sidebars can be +.\" found and removed when they reach a certain age. If another argument +.\" is present, then a line break is forced before starting the sidebar. +.\" +.\" .VE +.\" End of vertical sidebar. +.\" +.\" .DS +.\" Begin an indented unfilled display. +.\" +.\" .DE +.\" End of indented unfilled display. +.\" +.\" .SO ?manpage? +.\" Start of list of standard options for a Tk widget. The manpage +.\" argument defines where to look up the standard options; if +.\" omitted, defaults to "options". The options follow on successive +.\" lines, in three columns separated by tabs. +.\" +.\" .SE +.\" End of list of standard options for a Tk widget. +.\" +.\" .OP cmdName dbName dbClass +.\" Start of description of a specific option. cmdName gives the +.\" option's name as specified in the class command, dbName gives +.\" the option's name in the option database, and dbClass gives +.\" the option's class in the option database. +.\" +.\" .UL arg1 arg2 +.\" Print arg1 underlined, then print arg2 normally. +.\" +.\" .QW arg1 ?arg2? +.\" Print arg1 in quotes, then arg2 normally (for trailing punctuation). +.\" +.\" .PQ arg1 ?arg2? +.\" Print an open parenthesis, arg1 in quotes, then arg2 normally +.\" (for trailing punctuation) and then a closing parenthesis. +.\" +.\" # Set up traps and other miscellaneous stuff for Tcl/Tk man pages. +.if t .wh -1.3i ^B +.nr ^l \n(.l +.ad b +.\" # Start an argument description +.de AP +.ie !"\\$4"" .TP \\$4 +.el \{\ +. ie !"\\$2"" .TP \\n()Cu +. el .TP 15 +.\} +.ta \\n()Au \\n()Bu +.ie !"\\$3"" \{\ +\&\\$1 \\fI\\$2\\fP (\\$3) +.\".b +.\} +.el \{\ +.br +.ie !"\\$2"" \{\ +\&\\$1 \\fI\\$2\\fP +.\} +.el \{\ +\&\\fI\\$1\\fP +.\} +.\} +.. +.\" # define tabbing values for .AP +.de AS +.nr )A 10n +.if !"\\$1"" .nr )A \\w'\\$1'u+3n +.nr )B \\n()Au+15n +.\" +.if !"\\$2"" .nr )B \\w'\\$2'u+\\n()Au+3n +.nr )C \\n()Bu+\\w'(in/out)'u+2n +.. +.AS Tcl_Interp Tcl_CreateInterp in/out +.\" # BS - start boxed text +.\" # ^y = starting y location +.\" # ^b = 1 +.de BS +.br +.mk ^y +.nr ^b 1u +.if n .nf +.if n .ti 0 +.if n \l'\\n(.lu\(ul' +.if n .fi +.. +.\" # BE - end boxed text (draw box now) +.de BE +.nf +.ti 0 +.mk ^t +.ie n \l'\\n(^lu\(ul' +.el \{\ +.\" Draw four-sided box normally, but don't draw top of +.\" box if the box started on an earlier page. +.ie !\\n(^b-1 \{\ +\h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.el \}\ +\h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.\} +.fi +.br +.nr ^b 0 +.. +.\" # VS - start vertical sidebar +.\" # ^Y = starting y location +.\" # ^v = 1 (for troff; for nroff this doesn't matter) +.de VS +.if !"\\$2"" .br +.mk ^Y +.ie n 'mc \s12\(br\s0 +.el .nr ^v 1u +.. +.\" # VE - end of vertical sidebar +.de VE +.ie n 'mc +.el \{\ +.ev 2 +.nf +.ti 0 +.mk ^t +\h'|\\n(^lu+3n'\L'|\\n(^Yu-1v\(bv'\v'\\n(^tu+1v-\\n(^Yu'\h'-|\\n(^lu+3n' +.sp -1 +.fi +.ev +.\} +.nr ^v 0 +.. +.\" # Special macro to handle page bottom: finish off current +.\" # box/sidebar if in box/sidebar mode, then invoked standard +.\" # page bottom macro. +.de ^B +.ev 2 +'ti 0 +'nf +.mk ^t +.if \\n(^b \{\ +.\" Draw three-sided box if this is the box's first page, +.\" draw two sides but no top otherwise. +.ie !\\n(^b-1 \h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.el \h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.\} +.if \\n(^v \{\ +.nr ^x \\n(^tu+1v-\\n(^Yu +\kx\h'-\\nxu'\h'|\\n(^lu+3n'\ky\L'-\\n(^xu'\v'\\n(^xu'\h'|0u'\c +.\} +.bp +'fi +.ev +.if \\n(^b \{\ +.mk ^y +.nr ^b 2 +.\} +.if \\n(^v \{\ +.mk ^Y +.\} +.. +.\" # DS - begin display +.de DS +.RS +.nf +.sp +.. +.\" # DE - end display +.de DE +.fi +.RE +.sp +.. +.\" # SO - start of list of standard options +.de SO +'ie '\\$1'' .ds So \\fBoptions\\fR +'el .ds So \\fB\\$1\\fR +.SH "STANDARD OPTIONS" +.LP +.nf +.ta 5.5c 11c +.ft B +.. +.\" # SE - end of list of standard options +.de SE +.fi +.ft R +.LP +See the \\*(So manual entry for details on the standard options. +.. +.\" # OP - start of full description for a single option +.de OP +.LP +.nf +.ta 4c +Command-Line Name: \\fB\\$1\\fR +Database Name: \\fB\\$2\\fR +Database Class: \\fB\\$3\\fR +.fi +.IP +.. +.\" # CS - begin code excerpt +.de CS +.RS +.nf +.ta .25i .5i .75i 1i +.. +.\" # CE - end code excerpt +.de CE +.fi +.RE +.. +.\" # UL - underline word +.de UL +\\$1\l'|0\(ul'\\$2 +.. +.\" # QW - apply quotation marks to word +.de QW +.ie '\\*(lq'"' ``\\$1''\\$2 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\$2 +.. +.\" # PQ - apply parens and quotation marks to word +.de PQ +.ie '\\*(lq'"' (``\\$1''\\$2)\\$3 +.\"" fix emacs highlighting +.el (\\*(lq\\$1\\*(rq\\$2)\\$3 +.. +.\" # QR - quoted range +.de QR +.ie '\\*(lq'"' ``\\$1''\\-``\\$2''\\$3 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\-\\*(lq\\$2\\*(rq\\$3 +.. +.\" # MT - "empty" string +.de MT +.QW "" +.. +.BS +.SH NAME +cmdr::validate::weekday \- Cmdr - Validation type for weekday names +.SH SYNOPSIS +package require \fBtry \fR +.sp +package require \fBclock::iso8601 \fR +.sp +package require \fBcmdr::validate::common \fR +.sp +package require \fBcmdr::validate::weekday \fR +.sp +\fB::cmdr::validate::time\fR \fB2external\fR \fIweekday\fR +.sp +.BE +.SH DESCRIPTION +.PP +Welcome to the Cmdr project, written by Andreas Kupries\&. +.PP +For availability please read \fICmdr - How To Get The Sources\fR\&. +.PP +.PP +This package provides the validation type +\fB::cmdr::validate::weekday\fR which accepts weekdays as names and +numbers\&. +.PP +The internal representation is the numeric weekday for the +validated input where \fB1\fR to \fB7\fR map to Monday to Sunday\&. +.PP +The type has no input completion\&. +.PP +The details of the exported standard API can be found in +\fICmdr - Writing custom validation types\fR\&. The chosen default is "today's weekday"\&. +.PP +A single non-standard method is provided: +.TP +\fB::cmdr::validate::time\fR \fB2external\fR \fIweekday\fR +This method converts the numeric weekday to the form %A and returns +the conversion result as its own\&. +.PP +.SH "BUGS, IDEAS, FEEDBACK" +Both the package(s) and this documentation will undoubtedly contain +bugs and other problems\&. +Please report such at +\fICmdr Tickets\fR [https:/core\&.tcl\&.tk/akupries/cmdr]\&. +.PP +Please also report any ideas you may have for enhancements of +either package(s) and/or documentation\&. +.SH KEYWORDS +arguments, command hierarchy, command line completion, command line handling, command tree, editing command line, help for command line, hierarchy of commands, interactive command shell, optional arguments, options, parameters, processing command line, tree of commands +.SH COPYRIGHT +.nf +Copyright (c) 2013 Andreas Kupries +Copyright (c) 2013 Documentation, Andreas Kupries + +.fi ADDED embedded/man/files/cmdr_vt_year.n Index: embedded/man/files/cmdr_vt_year.n ================================================================== --- /dev/null +++ embedded/man/files/cmdr_vt_year.n @@ -0,0 +1,314 @@ +'\" +'\" Generated from file 'cmdr_vt_year\&.man' by tcllib/doctools with format 'nroff' +'\" Copyright (c) 2013 Andreas Kupries +'\" Copyright (c) 2013 Documentation, Andreas Kupries +'\" +.TH "cmdr::validate::year" n 1\&.1 doc "Cmdr, a framework for command line parsing and dispatch" +.\" The -*- nroff -*- definitions below are for supplemental macros used +.\" in Tcl/Tk manual entries. +.\" +.\" .AP type name in/out ?indent? +.\" Start paragraph describing an argument to a library procedure. +.\" type is type of argument (int, etc.), in/out is either "in", "out", +.\" or "in/out" to describe whether procedure reads or modifies arg, +.\" and indent is equivalent to second arg of .IP (shouldn't ever be +.\" needed; use .AS below instead) +.\" +.\" .AS ?type? ?name? +.\" Give maximum sizes of arguments for setting tab stops. Type and +.\" name are examples of largest possible arguments that will be passed +.\" to .AP later. If args are omitted, default tab stops are used. +.\" +.\" .BS +.\" Start box enclosure. From here until next .BE, everything will be +.\" enclosed in one large box. +.\" +.\" .BE +.\" End of box enclosure. +.\" +.\" .CS +.\" Begin code excerpt. +.\" +.\" .CE +.\" End code excerpt. +.\" +.\" .VS ?version? ?br? +.\" Begin vertical sidebar, for use in marking newly-changed parts +.\" of man pages. The first argument is ignored and used for recording +.\" the version when the .VS was added, so that the sidebars can be +.\" found and removed when they reach a certain age. If another argument +.\" is present, then a line break is forced before starting the sidebar. +.\" +.\" .VE +.\" End of vertical sidebar. +.\" +.\" .DS +.\" Begin an indented unfilled display. +.\" +.\" .DE +.\" End of indented unfilled display. +.\" +.\" .SO ?manpage? +.\" Start of list of standard options for a Tk widget. The manpage +.\" argument defines where to look up the standard options; if +.\" omitted, defaults to "options". The options follow on successive +.\" lines, in three columns separated by tabs. +.\" +.\" .SE +.\" End of list of standard options for a Tk widget. +.\" +.\" .OP cmdName dbName dbClass +.\" Start of description of a specific option. cmdName gives the +.\" option's name as specified in the class command, dbName gives +.\" the option's name in the option database, and dbClass gives +.\" the option's class in the option database. +.\" +.\" .UL arg1 arg2 +.\" Print arg1 underlined, then print arg2 normally. +.\" +.\" .QW arg1 ?arg2? +.\" Print arg1 in quotes, then arg2 normally (for trailing punctuation). +.\" +.\" .PQ arg1 ?arg2? +.\" Print an open parenthesis, arg1 in quotes, then arg2 normally +.\" (for trailing punctuation) and then a closing parenthesis. +.\" +.\" # Set up traps and other miscellaneous stuff for Tcl/Tk man pages. +.if t .wh -1.3i ^B +.nr ^l \n(.l +.ad b +.\" # Start an argument description +.de AP +.ie !"\\$4"" .TP \\$4 +.el \{\ +. ie !"\\$2"" .TP \\n()Cu +. el .TP 15 +.\} +.ta \\n()Au \\n()Bu +.ie !"\\$3"" \{\ +\&\\$1 \\fI\\$2\\fP (\\$3) +.\".b +.\} +.el \{\ +.br +.ie !"\\$2"" \{\ +\&\\$1 \\fI\\$2\\fP +.\} +.el \{\ +\&\\fI\\$1\\fP +.\} +.\} +.. +.\" # define tabbing values for .AP +.de AS +.nr )A 10n +.if !"\\$1"" .nr )A \\w'\\$1'u+3n +.nr )B \\n()Au+15n +.\" +.if !"\\$2"" .nr )B \\w'\\$2'u+\\n()Au+3n +.nr )C \\n()Bu+\\w'(in/out)'u+2n +.. +.AS Tcl_Interp Tcl_CreateInterp in/out +.\" # BS - start boxed text +.\" # ^y = starting y location +.\" # ^b = 1 +.de BS +.br +.mk ^y +.nr ^b 1u +.if n .nf +.if n .ti 0 +.if n \l'\\n(.lu\(ul' +.if n .fi +.. +.\" # BE - end boxed text (draw box now) +.de BE +.nf +.ti 0 +.mk ^t +.ie n \l'\\n(^lu\(ul' +.el \{\ +.\" Draw four-sided box normally, but don't draw top of +.\" box if the box started on an earlier page. +.ie !\\n(^b-1 \{\ +\h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.el \}\ +\h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul' +.\} +.\} +.fi +.br +.nr ^b 0 +.. +.\" # VS - start vertical sidebar +.\" # ^Y = starting y location +.\" # ^v = 1 (for troff; for nroff this doesn't matter) +.de VS +.if !"\\$2"" .br +.mk ^Y +.ie n 'mc \s12\(br\s0 +.el .nr ^v 1u +.. +.\" # VE - end of vertical sidebar +.de VE +.ie n 'mc +.el \{\ +.ev 2 +.nf +.ti 0 +.mk ^t +\h'|\\n(^lu+3n'\L'|\\n(^Yu-1v\(bv'\v'\\n(^tu+1v-\\n(^Yu'\h'-|\\n(^lu+3n' +.sp -1 +.fi +.ev +.\} +.nr ^v 0 +.. +.\" # Special macro to handle page bottom: finish off current +.\" # box/sidebar if in box/sidebar mode, then invoked standard +.\" # page bottom macro. +.de ^B +.ev 2 +'ti 0 +'nf +.mk ^t +.if \\n(^b \{\ +.\" Draw three-sided box if this is the box's first page, +.\" draw two sides but no top otherwise. +.ie !\\n(^b-1 \h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.el \h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c +.\} +.if \\n(^v \{\ +.nr ^x \\n(^tu+1v-\\n(^Yu +\kx\h'-\\nxu'\h'|\\n(^lu+3n'\ky\L'-\\n(^xu'\v'\\n(^xu'\h'|0u'\c +.\} +.bp +'fi +.ev +.if \\n(^b \{\ +.mk ^y +.nr ^b 2 +.\} +.if \\n(^v \{\ +.mk ^Y +.\} +.. +.\" # DS - begin display +.de DS +.RS +.nf +.sp +.. +.\" # DE - end display +.de DE +.fi +.RE +.sp +.. +.\" # SO - start of list of standard options +.de SO +'ie '\\$1'' .ds So \\fBoptions\\fR +'el .ds So \\fB\\$1\\fR +.SH "STANDARD OPTIONS" +.LP +.nf +.ta 5.5c 11c +.ft B +.. +.\" # SE - end of list of standard options +.de SE +.fi +.ft R +.LP +See the \\*(So manual entry for details on the standard options. +.. +.\" # OP - start of full description for a single option +.de OP +.LP +.nf +.ta 4c +Command-Line Name: \\fB\\$1\\fR +Database Name: \\fB\\$2\\fR +Database Class: \\fB\\$3\\fR +.fi +.IP +.. +.\" # CS - begin code excerpt +.de CS +.RS +.nf +.ta .25i .5i .75i 1i +.. +.\" # CE - end code excerpt +.de CE +.fi +.RE +.. +.\" # UL - underline word +.de UL +\\$1\l'|0\(ul'\\$2 +.. +.\" # QW - apply quotation marks to word +.de QW +.ie '\\*(lq'"' ``\\$1''\\$2 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\$2 +.. +.\" # PQ - apply parens and quotation marks to word +.de PQ +.ie '\\*(lq'"' (``\\$1''\\$2)\\$3 +.\"" fix emacs highlighting +.el (\\*(lq\\$1\\*(rq\\$2)\\$3 +.. +.\" # QR - quoted range +.de QR +.ie '\\*(lq'"' ``\\$1''\\-``\\$2''\\$3 +.\"" fix emacs highlighting +.el \\*(lq\\$1\\*(rq\\-\\*(lq\\$2\\*(rq\\$3 +.. +.\" # MT - "empty" string +.de MT +.QW "" +.. +.BS +.SH NAME +cmdr::validate::year \- Cmdr - Validation type for years +.SH SYNOPSIS +package require \fBcmdr::validate::year \fR +.sp +.BE +.SH DESCRIPTION +.PP +Welcome to the Cmdr project, written by Andreas Kupries\&. +.PP +For availability please read \fICmdr - How To Get The Sources\fR\&. +.PP +.PP +This package provides the validation type +\fB::cmdr::validate::year\fR which accepts both short (2 digit) and +long (4 digit) year numbers\&. +.PP +The internal representation is the full number of the validated +input, i\&.e always 4 digits\&. +.PP +The type has no input completion\&. +.PP +The details of the exported API can be found in +\fICmdr - Writing custom validation types\fR\&. The chosen default is the "current year"\&. +.SH "BUGS, IDEAS, FEEDBACK" +Both the package(s) and this documentation will undoubtedly contain +bugs and other problems\&. +Please report such at +\fICmdr Tickets\fR [https:/core\&.tcl\&.tk/akupries/cmdr]\&. +.PP +Please also report any ideas you may have for enhancements of +either package(s) and/or documentation\&. +.SH KEYWORDS +arguments, command hierarchy, command line completion, command line handling, command tree, editing command line, help for command line, hierarchy of commands, interactive command shell, optional arguments, options, parameters, processing command line, tree of commands +.SH COPYRIGHT +.nf +Copyright (c) 2013 Andreas Kupries +Copyright (c) 2013 Documentation, Andreas Kupries + +.fi Index: embedded/man/index.n ================================================================== --- embedded/man/index.n +++ embedded/man/index.n @@ -359,10 +359,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -458,10 +473,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -557,10 +587,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -656,10 +701,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -755,10 +815,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -854,10 +929,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -953,10 +1043,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -1052,10 +1157,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -1151,10 +1271,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -1250,10 +1385,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -1349,10 +1499,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -1448,10 +1613,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -1547,10 +1727,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR @@ -1646,10 +1841,25 @@ \fBfiles/cmdr_validate\&.n\fR cmdr::validate .TP \fBfiles/cmdr_vcommon\&.n\fR cmdr::validate::common +.TP +\fBfiles/cmdr_vt_date\&.n\fR +cmdr::validate::date +.TP +\fBfiles/cmdr_vt_posint\&.n\fR +cmdr::validate::posint +.TP +\fBfiles/cmdr_vt_time\&.n\fR +cmdr::validate::time +.TP +\fBfiles/cmdr_vt_weekday\&.n\fR +cmdr::validate::weekday +.TP +\fBfiles/cmdr_vt_year\&.n\fR +cmdr::validate::year .TP \fBfiles/cmdr_howto_development\&.n\fR cmdr_development .TP \fBfiles/cmdr_dev_completion\&.n\fR Index: embedded/man/toc.n ================================================================== --- embedded/man/toc.n +++ embedded/man/toc.n @@ -358,10 +358,25 @@ \fIfiles/cmdr_validate\&.n\fR: Cmdr - Standard validation types for parameters .TP \fBcmdr::validate::common\fR \fIfiles/cmdr_vcommon\&.n\fR: Cmdr - Utilities for Validation Types .TP +\fBcmdr::validate::date\fR +\fIfiles/cmdr_vt_date\&.n\fR: Cmdr - Validation type for dates +.TP +\fBcmdr::validate::posint\fR +\fIfiles/cmdr_vt_posint\&.n\fR: Cmdr - Validation type for positive integers +.TP +\fBcmdr::validate::time\fR +\fIfiles/cmdr_vt_time\&.n\fR: Cmdr - Validation type for times +.TP +\fBcmdr::validate::weekday\fR +\fIfiles/cmdr_vt_weekday\&.n\fR: Cmdr - Validation type for weekday names +.TP +\fBcmdr::validate::year\fR +\fIfiles/cmdr_vt_year\&.n\fR: Cmdr - Validation type for years +.TP \fBcmdr_development\fR \fIfiles/cmdr_howto_development\&.n\fR: Cmdr - The Developer's Guide .TP \fBcmdr_dev~completion\fR \fIfiles/cmdr_dev_completion\&.n\fR: Cmdr - Internals of command line completion Index: embedded/www/doc/files/cmdr_vcommon.html ================================================================== --- embedded/www/doc/files/cmdr_vcommon.html +++ embedded/www/doc/files/cmdr_vcommon.html @@ -124,13 +124,18 @@

Description

Welcome to the Cmdr project, written by Andreas Kupries.

@@ -140,14 +145,70 @@ The standard validation types defined in package cmdr::validate make use of these commands.

API

-
::cmdr::validate::common fail p code type x
+
::cmdr::validate::common fail p code type x ?context?
+

When invoked this command throws an error indicating a validation type +failure. The arguments provide the information used to construct both +error message and code.

+

The generated string has the form:

+
+    Expected $type for $p.type "$x"$context, got "$x"
+
+
+
cmdr::parameter p
+

The cmdr::parameter instance whose validation failed. The +error message will contain this parameter's type and label (flag in +case of an option).

+
list code
+

A list providing additional elements for the error code, detailing the +internal name of the validation type triggering the error.

+
string type
+

A string providing the human-readable name of the validation type +triggering the error.

+
string x
+

The string value failing the validation.

+
string context
+

Additional context to show in the message. Defaults to the empty string.

+
+
::cmdr::validate::common fail-unknown-thing p code type x ?context?
+

When invoked this command throws an error indicating a validation type +failure. The arguments provide the information used to construct both +error message and code.

+

The generated string has the form:

+
+    Found a problem with $p.type "$p.the-name":
+    A(n) $type named "$x" does not exist$context.
+    Please use a different value.
+
+
+
cmdr::parameter p
+

The cmdr::parameter instance whose validation failed. The +error message will contain this parameter's type and label (flag in +case of an option).

+
list code
+

A list providing additional elements for the error code, detailing the +internal name of the validation type triggering the error.

+
string type
+

A string providing the human-readable name of the validation type +triggering the error.

+
string x
+

The string value failing the validation.

+
string context
+

Additional context to show in the message. Defaults to the empty string.

+
+
::cmdr::validate::common fail-known-thing p code type x ?context?

When invoked this command throws an error indicating a validation type failure. The arguments provide the information used to construct both error message and code.

+

The generated string has the form:

+
+    Found a problem with $p.type "$p.the-name":
+    A(n) $type named "$x" already exists$context.
+    Please use a different name.
+
cmdr::parameter p

The cmdr::parameter instance whose validation failed. The error message will contain this parameter's type and label (flag in case of an option).

@@ -157,26 +218,42 @@
string type

A string providing the human-readable name of the validation type triggering the error.

string x

The string value failing the validation.

+
string context
+

Additional context to show in the message. Defaults to the empty string.

-
::cmdr::validate::common complete-enum choices nocase buffer
+
::cmdr::validate::common complete-enum choices nocase buffer

When invoked this command returns a list of strings containing just the elements of choices the value of buffer is a prefix of. When nocase is set the command will ignore letter case and treat the string in buffer as all-lowercase.

list choices

The list of values which can complete the data in buffer.

boolean nocase

A boolean flag specifying if the completion is done ignoring -letter-case (true), or not (false)).

+letter-case (true, nocase), or not (false)).

+
string buffer
+

The string to complete via the list of choices.

+
+
::cmdr::validate::common complete-substr choices nocase buffer
+

When invoked this command returns a list of strings containing just +the elements of choices the value of buffer is a substring +of. When nocase is set the command will ignore letter case and +treat the string in buffer as all-lowercase.

+
+
list choices
+

The list of values which can complete the data in buffer.

+
boolean nocase
+

A boolean flag specifying if the completion is done ignoring +letter-case (true, nocase), or not (false)).

string buffer

The string to complete via the list of choices.

-
::cmdr::validate::common complete-glob filter buffer
+
::cmdr::validate::common complete-glob filter buffer

When invoked this command returns a list of strings, the paths in the filesystem the value of buffer is a prefix of, and not rejected by the filter command (prefix).

Note that when the value of buffer is a relative path the current working directory is used to locate matches.

@@ -186,10 +263,49 @@ returning a boolean value indicating (non-)acceptance of the path. A result of true accepts the candidate, false rejects it.

string buffer

The string, a partial path, to complete.

+ +
::cmdr::validate::common ok-directory path
+

When invoked this command checks if the specified path is +suitable as a directory and returns the boolean value true if +so, and false else.

+

for the path to be suitable the following conditions must hold:

+
    +
  1. If the path exists:

    +
      +
    1. The path has to refer to a directory.

    2. +
    3. The referenced directory must be writable.

    4. +
    +
  2. +
  3. Else:

    +
      +
    1. The parent path has to pass ok-directory.

    2. +
    3. The above recursion stops at the root directory, and then fails.

    4. +
    +
  4. +
+
+
string path
+

The path to check.

+
+
::cmdr::validate::common lead-in text
+

A utility command supporting the construction of error messages. Given the +text the command returns a modified text with a proper prefix of +either A or An.

+

The basic heuristics is to use An if text begins with +a vocal, and A otherwise. This heuristic is bypassed if the the +text already has a prefix of An or A separated by a +space from the remainder of the string. In that case the text is +returned as-is.

+

This command is used by fail, fail-known-thing and +fail-unknown-thing provided by this package. All apply it to their +type argument.

+
+
string text
+

The string to prefix with a leading A or An.

Bugs, Ideas, Feedback

Both the package(s) and this documentation will undoubtedly contain ADDED embedded/www/doc/files/cmdr_vt_date.html Index: embedded/www/doc/files/cmdr_vt_date.html ================================================================== --- /dev/null +++ embedded/www/doc/files/cmdr_vt_date.html @@ -0,0 +1,167 @@ + + +cmdr::validate::date - Cmdr, a framework for command line parsing and dispatch + + + + + +

+
[ + Home +| Main Table Of Contents +| Table Of Contents +| Keyword Index + ]
+

cmdr::validate::date(n) 1.1 doc "Cmdr, a framework for command line parsing and dispatch"

+

Name

+

cmdr::validate::date - Cmdr - Validation type for dates

+
+ +

Synopsis

+
+
    +
  • package require try
  • +
  • package require clock::iso8601
  • +
  • package require cmdr::validate::common
  • +
  • package require cmdr::validate::date
  • +
+ +
+
+

Description

+

Welcome to the Cmdr project, written by Andreas Kupries.

+

For availability please read Cmdr - How To Get The Sources.

+

This package provides the validation type +::cmdr::validate::date which accepts dates in ISO 8601 syntax.

+

The internal representation is the epoch for the validated +input, at midnight.

+

The type has no input completion.

+

The details of the exported standard API can be found in +Cmdr - Writing custom validation types. The chosen default is "today".

+

A single non-standard method is provided:

+
+
::cmdr::validate::date 2external epoch
+

This method converts the epoch of a date to the form %Y-%m-%d and +returns the conversion result as its own.

+
+
+

Bugs, Ideas, Feedback

+

Both the package(s) and this documentation will undoubtedly contain +bugs and other problems. +Please report such at +Cmdr Tickets.

+

Please also report any ideas you may have for enhancements of +either package(s) and/or documentation.

+
+ + +
ADDED embedded/www/doc/files/cmdr_vt_posint.html Index: embedded/www/doc/files/cmdr_vt_posint.html ================================================================== --- /dev/null +++ embedded/www/doc/files/cmdr_vt_posint.html @@ -0,0 +1,156 @@ + + +cmdr::validate::posint - Cmdr, a framework for command line parsing and dispatch + + + + + +
+
[ + Home +| Main Table Of Contents +| Table Of Contents +| Keyword Index + ]
+

cmdr::validate::posint(n) 1.1 doc "Cmdr, a framework for command line parsing and dispatch"

+

Name

+

cmdr::validate::posint - Cmdr - Validation type for positive integers

+
+ +

Synopsis

+
+
    +
  • package require cmdr::validate::posint
  • +
+
+
+

Description

+

Welcome to the Cmdr project, written by Andreas Kupries.

+

For availability please read Cmdr - How To Get The Sources.

+

This package provides the validation type +::cmdr::validate::posint which accepts any positive integer +number, i.e. any integer greater than zero.

+

The internal representation is the decimal representation of +the validated input.

+

The type has no input completion.

+

The details of the exported API can be found in +Cmdr - Writing custom validation types. The chosen default is 1.

+
+

Bugs, Ideas, Feedback

+

Both the package(s) and this documentation will undoubtedly contain +bugs and other problems. +Please report such at +Cmdr Tickets.

+

Please also report any ideas you may have for enhancements of +either package(s) and/or documentation.

+
+ + +
ADDED embedded/www/doc/files/cmdr_vt_time.html Index: embedded/www/doc/files/cmdr_vt_time.html ================================================================== --- /dev/null +++ embedded/www/doc/files/cmdr_vt_time.html @@ -0,0 +1,168 @@ + + +cmdr::validate::time - Cmdr, a framework for command line parsing and dispatch + + + + + +
+
[ + Home +| Main Table Of Contents +| Table Of Contents +| Keyword Index + ]
+

cmdr::validate::time(n) 1.1 doc "Cmdr, a framework for command line parsing and dispatch"

+

Name

+

cmdr::validate::time - Cmdr - Validation type for times

+
+ +

Synopsis

+
+
    +
  • package require try
  • +
  • package require clock::iso8601
  • +
  • package require cmdr::validate::common
  • +
  • package require cmdr::validate::time
  • +
+ +
+
+

Description

+

Welcome to the Cmdr project, written by Andreas Kupries.

+

For availability please read Cmdr - How To Get The Sources.

+

This package provides the validation type +::cmdr::validate::time which accepts timestamps in ISO 8601 +syntax.

+

The internal representation is the epoch for the validated +input.

+

The type has no input completion.

+

The details of the exported standard API can be found in +Cmdr - Writing custom validation types. The chosen default is "now".

+

A single non-standard method is provided:

+
+
::cmdr::validate::time 2external epoch
+

This method converts the epoch of a time to the form %H:%M:%S and +returns the conversion result as its own.

+
+
+

Bugs, Ideas, Feedback

+

Both the package(s) and this documentation will undoubtedly contain +bugs and other problems. +Please report such at +Cmdr Tickets.

+

Please also report any ideas you may have for enhancements of +either package(s) and/or documentation.

+
+ + +
ADDED embedded/www/doc/files/cmdr_vt_weekday.html Index: embedded/www/doc/files/cmdr_vt_weekday.html ================================================================== --- /dev/null +++ embedded/www/doc/files/cmdr_vt_weekday.html @@ -0,0 +1,168 @@ + + +cmdr::validate::weekday - Cmdr, a framework for command line parsing and dispatch + + + + + +
+
[ + Home +| Main Table Of Contents +| Table Of Contents +| Keyword Index + ]
+

cmdr::validate::weekday(n) 1.1 doc "Cmdr, a framework for command line parsing and dispatch"

+

Name

+

cmdr::validate::weekday - Cmdr - Validation type for weekday names

+
+ +

Synopsis

+
+
    +
  • package require try
  • +
  • package require clock::iso8601
  • +
  • package require cmdr::validate::common
  • +
  • package require cmdr::validate::weekday
  • +
+ +
+
+

Description

+

Welcome to the Cmdr project, written by Andreas Kupries.

+

For availability please read Cmdr - How To Get The Sources.

+

This package provides the validation type +::cmdr::validate::weekday which accepts weekdays as names and +numbers.

+

The internal representation is the numeric weekday for the +validated input where 1 to 7 map to Monday to Sunday.

+

The type has no input completion.

+

The details of the exported standard API can be found in +Cmdr - Writing custom validation types. The chosen default is "today's weekday".

+

A single non-standard method is provided:

+
+
::cmdr::validate::time 2external weekday
+

This method converts the numeric weekday to the form %A and returns +the conversion result as its own.

+
+
+

Bugs, Ideas, Feedback

+

Both the package(s) and this documentation will undoubtedly contain +bugs and other problems. +Please report such at +Cmdr Tickets.

+

Please also report any ideas you may have for enhancements of +either package(s) and/or documentation.

+
+ + +
ADDED embedded/www/doc/files/cmdr_vt_year.html Index: embedded/www/doc/files/cmdr_vt_year.html ================================================================== --- /dev/null +++ embedded/www/doc/files/cmdr_vt_year.html @@ -0,0 +1,156 @@ + + +cmdr::validate::year - Cmdr, a framework for command line parsing and dispatch + + + + + +
+
[ + Home +| Main Table Of Contents +| Table Of Contents +| Keyword Index + ]
+

cmdr::validate::year(n) 1.1 doc "Cmdr, a framework for command line parsing and dispatch"

+

Name

+

cmdr::validate::year - Cmdr - Validation type for years

+
+ +

Synopsis

+
+
    +
  • package require cmdr::validate::year
  • +
+
+
+

Description

+

Welcome to the Cmdr project, written by Andreas Kupries.

+

For availability please read Cmdr - How To Get The Sources.

+

This package provides the validation type +::cmdr::validate::year which accepts both short (2 digit) and +long (4 digit) year numbers.

+

The internal representation is the full number of the validated +input, i.e always 4 digits.

+

The type has no input completion.

+

The details of the exported API can be found in +Cmdr - Writing custom validation types. The chosen default is the "current year".

+
+

Bugs, Ideas, Feedback

+

Both the package(s) and this documentation will undoubtedly contain +bugs and other problems. +Please report such at +Cmdr Tickets.

+

Please also report any ideas you may have for enhancements of +either package(s) and/or documentation.

+
+ + +
Index: embedded/www/doc/toc.html ================================================================== --- embedded/www/doc/toc.html +++ embedded/www/doc/toc.html @@ -128,18 +128,38 @@ cmdr::validate::common Cmdr - Utilities for Validation Types +cmdr::validate::date +Cmdr - Validation type for dates + + +cmdr::validate::posint +Cmdr - Validation type for positive integers + + +cmdr::validate::time +Cmdr - Validation type for times + + +cmdr::validate::weekday +Cmdr - Validation type for weekday names + + +cmdr::validate::year +Cmdr - Validation type for years + + cmdr_development Cmdr - The Developer's Guide - + cmdr_dev~completion Cmdr - Internals of command line completion - + cmdr_dev~dsl Cmdr - Internals of DSL handling
Index: embedded/www/index.html ================================================================== --- embedded/www/index.html +++ embedded/www/index.html @@ -20,95 +20,95 @@ Keywords: A arguments - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl Keywords: C command hierarchy - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl command line completion - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl command line handling - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl command tree - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl Keywords: E editing command line - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl Keywords: H help for command line - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl hierarchy of commands - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl Keywords: I interactive command shell - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl Keywords: O optional arguments - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl options - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl Keywords: P parameters - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl processing command line - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl Keywords: T tree of commands - cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl + cmdr · cmdr-changes · cmdr-howto-get-sources · cmdr-installation · cmdr-introduction · cmdr-license · cmdr-spec-dsl · cmdr-spec-dsl-officer · cmdr-spec-dsl-parameter · cmdr-spec-dsl-private · cmdr-spec-flow · cmdr-user-helpformats · cmdr-user-vtypes · cmdr::actor · cmdr::ask · cmdr::color · cmdr::config · cmdr::help · cmdr::help::json · cmdr::help::sql · cmdr::help::tcl · cmdr::officer · cmdr::pager · cmdr::parameter · cmdr::private · cmdr::tty · cmdr::util · cmdr::validate · cmdr::validate::common · cmdr::validate::date · cmdr::validate::posint · cmdr::validate::time · cmdr::validate::weekday · cmdr::validate::year · cmdr_development · cmdr_dev~completion · cmdr_dev~dsl Index: embedded/www/toc.html ================================================================== --- embedded/www/toc.html +++ embedded/www/toc.html @@ -128,18 +128,38 @@ cmdr::validate::common Cmdr - Utilities for Validation Types +cmdr::validate::date +Cmdr - Validation type for dates + + +cmdr::validate::posint +Cmdr - Validation type for positive integers + + +cmdr::validate::time +Cmdr - Validation type for times + + +cmdr::validate::weekday +Cmdr - Validation type for weekday names + + +cmdr::validate::year +Cmdr - Validation type for years + + cmdr_development Cmdr - The Developer's Guide - + cmdr_dev~completion Cmdr - Internals of command line completion - + cmdr_dev~dsl Cmdr - Internals of DSL handling
Index: vcommon.tcl ================================================================== --- vcommon.tcl +++ vcommon.tcl @@ -167,11 +167,10 @@ return $candidates } proc ::cmdr::validate::common::ok-directory {path} { if {![file exists $path]} { - # The directory is allowed to not exist if its parent # directory exists and is writable. # Note: Prevent us from walking up the chain if the directory # has no parent. # Note 2: Switch to absolute notation if path is the relative