|
compare
|
Comparison of Function values is a valid operation.
A function's object id is simply the function name itself. The compare function
returns 0 if two function arguments have the same object id: {func1} and {func2}.
If the object id of the first function {func1} is less than the object id of the
second function {func2}, then -1 is returned. If the object id of the {func1}
is greater than {func2}, then +1 is returned.
Use the compare function when you wish to compare two arguments of the same Data Type and the result value needs to be represented as a numeric (0, 1 or -1). If a Boolean result is desired, then the Comparison Functions (=, <>, <, <=, >, >=) or the compareEQ, compareNE, compareGT, compareGE, compareLT, compareLE should be used instead.
Returns 0 if the two Function object ids are equal.
Returns -1 if the func1 object id is less than func2 object id.
Returns +1 if func1 object id is greater than func2 object id.
Here are a number of links to Lambda coding examples which contain this instruction in various use cases.
Here are the links to the data types of the function arguments. Here are also a number of links to functions having arguments with any of these data types.
You can always talk with the AIS at aiserver.sourceforge.net.
Name
Description
AIS Types func1 The first Function to be compared. Function func2 The second Function to be compared Function
Returns:
Examples
Argument Types
How do I contact the AIS team?