ad_tcl_vars_list_to_ns_set (public, deprecated)

 ad_tcl_vars_list_to_ns_set [ -set_id set_id ] [ -put ] vars_list

Defined in packages/acs-tcl/tcl/utilities-procs.tcl

Deprecated. Invoking this procedure generates a warning.

Takes a Tcl list of variable names and ns_set updates values in an ns_set correspondingly: key is the name of the var, value is the value of the var. The caller is (obviously) responsible for freeing the set if need be. DEPRECATED 5.10.1: modern ns_set idioms make this proc obsolete

Switches:
-set_id (optional)
If this switch is specified, it'll use this set instead of creating a new one.
-put (optional, boolean)
If this boolean switch is specified, it'll use ns_set put instead of ns_set update (update is default)
Parameters:
vars_list (required)
A Tcl list of variable names that will be transported into the ns_set.
Author:
Lars Pind <lars@pinds.com>
See Also:
  • ns_set

Partial Call Graph (max 5 caller/called nodes):
%3 ad_log_deprecated ad_log_deprecated (public) ad_tcl_vars_list_to_ns_set ad_tcl_vars_list_to_ns_set ad_tcl_vars_list_to_ns_set->ad_log_deprecated

Testcases:
No testcase defined.
Source code:
ad_log_deprecated proc ad_tcl_vars_list_to_ns_set
    ns_log notice "deprecated call: [info level [info level]]"
    if { ![info exists set_id] } {
        set set_id [ns_set create]
    }

    if { $put_p } {
        set command put
    } else {
        set command update
    }

    foreach varname $vars_list {
        upvar $varname var
        ns_set $command $set_id $varname $var
    }
    return $set_id
XQL Not present:
PostgreSQL, Oracle
Generic XQL file:
packages/acs-tcl/tcl/utilities-procs.xql

[ hide source ] | [ make this the default ]
Show another procedure: