TABLE OF CONTENTS


::pwtk::type::optionlist

SYNOPSIS

proc ::pwtk::type::optionlist {args} {

USAGE

   ::pwtk::type::optionlist allowedValues ?-strict? value

PURPOSE

Query if the value is one among the allowed values (allowed values are values of the optionlist).

OPTION

ARGUMENTS

RETURN VALUE

1 or 0

SOURCE

    args_
    set allowedValues $type
    set value $number
    if { $strict eq {} && $value eq {} } {
        return 1
    } else {        
        return [expr {$value in $allowedValues}]
    }
}