Class SimpleTestCompatibility

Description

Static methods for compatibility between different PHP versions.

Located in /compatibility.php (line 13)


	
			
Method Summary
 static object A copy (object $object)
 static boolean isA (object $object, string $class)
 static boolean isArrayOfIdenticalTypes (mixed $first, mixed $second)
 static boolean isIdentical (mixed $first, mixed $second)
 static boolean isIdenticalType (mixed $first, mixed $second)
 static boolean isReference ( &$first,  &$second, mixed $first, mixed $second)
 static void setTimeout (resource $handle, integer $timeout)
Methods
static copy (line 21)

Creates a copy whether in PHP5 or PHP4.

  • return: copy.
  • access: public
object A copy (object $object)
  • object $object: Thing to copy.
static isA (line 131)

Test to see if an object is a member of a class hiearchy.

  • return: True if class in hiearchy.
  • access: public
boolean isA (object $object, string $class)
  • object $object: Object to test.
  • string $class: Root name of hiearchy.
static isArrayOfIdenticalTypes (line 83)

Recursive type test for each element of an array.

  • return: True if identical.
  • access: protected
boolean isArrayOfIdenticalTypes (mixed $first, mixed $second)
  • mixed $first: Test subject.
  • mixed $second: Comparison object.
static isIdentical (line 38)

Identity test. Drops back to equality + types for PHP5 objects as the === operator counts as the stronger reference constraint.

  • return: True if identical.
  • access: public
boolean isIdentical (mixed $first, mixed $second)
  • mixed $first: Test subject.
  • mixed $second: Comparison object.
static isIdenticalType (line 55)

Recursive type test.

  • return: True if same type.
  • access: protected
boolean isIdenticalType (mixed $first, mixed $second)
  • mixed $first: Test subject.
  • mixed $second: Comparison object.
static isReference (line 105)

Test for two variables being aliases.

  • return: True if same.
  • access: public
boolean isReference ( &$first,  &$second, mixed $first, mixed $second)
  • mixed $first: Test subject.
  • mixed $second: Comparison object.
  • &$first
  • &$second
static setTimeout (line 156)

Sets a socket timeout for each chunk.

  • access: public
void setTimeout (resource $handle, integer $timeout)
  • resource $handle: Socket handle.
  • integer $timeout: Limit in seconds.

Documentation generated on Sun, 31 Oct 2010 16:31:03 -0500 by phpDocumentor 1.4.3