| @@ 875-883 (lines=9) @@ | ||
| 872 | } |
|
| 873 | } |
|
| 874 | ||
| 875 | public static function propertyExists($classOrObject, $property, $message = '') |
|
| 876 | { |
|
| 877 | if (!property_exists($classOrObject, $property)) { |
|
| 878 | static::reportInvalidArgument(sprintf( |
|
| 879 | $message ?: 'Expected the property %s to exist.', |
|
| 880 | static::valueToString($property) |
|
| 881 | )); |
|
| 882 | } |
|
| 883 | } |
|
| 884 | ||
| 885 | public static function propertyNotExists($classOrObject, $property, $message = '') |
|
| 886 | { |
|
| @@ 885-893 (lines=9) @@ | ||
| 882 | } |
|
| 883 | } |
|
| 884 | ||
| 885 | public static function propertyNotExists($classOrObject, $property, $message = '') |
|
| 886 | { |
|
| 887 | if (property_exists($classOrObject, $property)) { |
|
| 888 | static::reportInvalidArgument(sprintf( |
|
| 889 | $message ?: 'Expected the property %s to not exist.', |
|
| 890 | static::valueToString($property) |
|
| 891 | )); |
|
| 892 | } |
|
| 893 | } |
|
| 894 | ||
| 895 | public static function methodExists($classOrObject, $method, $message = '') |
|
| 896 | { |
|