Comparison Commands (Template Language)

Comparison commands of Software Ideas Modeler template language.
Command Result Type Description
Equals(obj1:Object, obj2:Object) Boolean

Returns true if the two objects are equal. This command is useful for comparing values for equality.

Parameters: Two objects to compare.

Example: Equals("text", "text") returns true.

Eq (alias for Equals) Boolean

Alias for the Equals command; performs the same function.

IsSame(obj1:Object, obj2:Object) Boolean

Compares the string or numeric representation of provided objects. Returns true if representations are the same.

Parameters: Two objects to compare.

Example: IsSame("123", 123) returns true because their string representations match.

GreaterThan(obj1:Object, obj2:Object) Boolean

Returns true if the first object is greater than the second object. Useful for numerical comparisons primarily.

Parameters: Two objects to compare.

Example: GreaterThan(5, 2) returns true.

GT (alias for GreaterThan) Boolean

Alias for the GreaterThan command; performs the same function.

LessThan(obj1:Object, obj2:Object) Boolean

Returns true if the first object is less than the second object. Often used for numerical comparisons.

Parameters: Two objects to compare.

Example: LessThan(2, 5) returns true.

LT (alias for LessThan) Boolean

Alias for the LessThan command; performs the same function.

IsEmpty(obj:Object) Boolean

Returns true if the object is null, undefined, an empty string, or otherwise considered "empty".

Parameter: The object to evaluate.

Example: IsEmpty("") returns true.

New Comment

Comment