findInPlist()

Synopsis

Returns the value following the name in the list. If the name is not found in the list, or no value follows the name, NoValue is returned.

PList is shorthand for "Property List", which a list of name-value pairs. The name is called the indicator.

Syntax

findInPlist ( indicator As Name, _
              plist As List ) As Any 
Argument Type Description
indicator Name The name to find in plist. The value following the first name to match will be returned.
plist List A list of name/value pairs - commonly referred to as a property list.

Example 1

Intent >findInPlist(:b, {:a, 1, :b, 2, :c, 3}) 
--> 2 

Example 2

Intent >findInPlist(:d, {:a, 1, :b, 2, :c, 3}) 
--> NoValue 
The name 'd' is not found in the list.

Example 3

Intent >findInPlist(:d, {:a, 1, :b, 2, :c, 3, :d}) 
--> NoValue 
The name 'd' is found in the list, but no value follows to be returned.