#members()
DESCRIPTION
returns the number of keys in the specified list of associative array keys;
maps those keys to a string variable when used as
'for <stringvar> in #members(<arraykey>,<arraykey>,...)';
the keys are sequenced in the order specified in the #members() function
or:
returns the number of keys in the specified list of associative array keys;
maps those keys to string variable s1 when used as
'foreach #members(<stringvar>,<arraykey>,<arraykey>,...)';
the keys are sequenced in the order specified in the #members() function
SYNOPSIS
#members(s2,s3,s4,...)
or:
#members(s1,s2,s3,s4,...)
ARGUMENTS
s2,s3,s4,... - a list of associative array keys, separated by commas
or:
s1 - a string variable name
s2,s3,s4,... - a list of associative array keys, separated by commas
EXAMPLES
rule
for $u in #members("root", "daemon", "bin", "sys")
if ! -e $shell[$u]
output mail "for user $u, $shell[$u] doesn't exist!"
fi
endfor
rule
foreach #members($u, "root", "daemon", "bin", "sys")
if ! -e $shell[$u]
output mail "for user $u, $shell[$u] doesn't exist!"
fi
endfor
SEE ALSO
#keys()
#rkeys(), #reversekeys()
#skeys(), #sortkeys()
Numerical Functions
String Functions