template::util::is_nil (public)

 template::util::is_nil ref

Defined in packages/acs-templating/tcl/util-procs.tcl

Determines whether a variable both exists and is not an empty string.

Parameters:
ref (required)
The name of a variable to test in the calling frame.
Returns:
1 if the variable either not exist or is an empty string. 0 if the variable is either an array reference or a nonempty scalar.

Partial Call Graph (max 5 caller/called nodes):
%3 test_util_is_nil util_is_nil (test acs-templating) template::util::is_nil template::util::is_nil test_util_is_nil->template::util::is_nil content::get_content content::get_content (public) content::get_content->template::util::is_nil packages/acs-templating/tcl/tag-init.tcl packages/acs-templating/ tcl/tag-init.tcl packages/acs-templating/tcl/tag-init.tcl->template::util::is_nil publish::foreach_publish_path publish::foreach_publish_path (private) publish::foreach_publish_path->template::util::is_nil publish::get_main_item_id publish::get_main_item_id (private) publish::get_main_item_id->template::util::is_nil publish::get_main_revision_id publish::get_main_revision_id (private) publish::get_main_revision_id->template::util::is_nil

Testcases:
util_is_nil
Source code:
    upvar $ref var

    return [expr { ![array exists var] && (![info exists var] || $var eq "") }]
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: