Class RSArrayComparator

Description

A comparator for arrays.

Located in /code/framework/RSArrayUtil/RSArrayUtil.php (line 435)

RSComparator
   |
   --RSArrayComparator
Variable Summary
Method Summary
RSArrayComparator RSArrayComparator ([RSComperator $subComparator = false], [mixed $ignoreOrder = false])
void compare (mixed $array1, mixed $array2)
Variables
boolean $_ignoreOrder = false (line 446)

Whether to ignore the order of the elements. Gets set inside the constructor method.

mixed $_subComparator = false (line 441)

Holds the boolean value false or an instance of the cass RSComperator or a class that extends it. Gets initialized in the construtor method.

Methods
Constructor RSArrayComparator (line 452)

Constructor method that initializes the private field _subComparator.

RSArrayComparator RSArrayComparator ([RSComperator $subComparator = false], [mixed $ignoreOrder = false])
  • RSComperator $subComparator: An instance of the cass RSComperator or a class that extends it. This argument is optional.
compare (line 465)

Returns 0 if both arrays contain the same elements.

Note that the order of the elements is NOT ignored.

void compare (mixed $array1, mixed $array2)

Redefinition of:
RSComparator::compare()
Returns 0 if objects passed as first and second argument are equal. They have to implement the method hashCode.

Inherited Methods

Inherited From RSComparator

RSComparator::compare()

Documentation generated on Mon, 8 Dec 2003 13:10:38 +0100 by phpDocumentor 1.2.3