ObjectType
extends Type
in package
FinalYes
A runtime type check for values of type T.
Tags
Table of Contents
Properties
- $class : string
Methods
- __construct() : mixed
- accepts() : bool
- array() : ArrayType<TKey, TValue>
- bool() : BoolType
- float() : FloatType
- int() : IntType
- name() : string
- object() : ObjectType<string|int, TObject>
- string() : StringType
Properties
$class read-only
private
string
$class
Methods
__construct()
public
__construct(T> $class) : mixed
Parameters
- $class : T>
accepts()
public
accepts(mixed $value) : bool
Parameters
- $value : mixed
Return values
boolarray()
public
static array([Type<string|int, TValue>|null $valueType = null ][, Type<string|int, TKey>|null $keyType = null ]) : ArrayType<TKey, TValue>
Parameters
Tags
Return values
ArrayType<TKey, TValue>bool()
public
static bool() : BoolType
Return values
BoolTypefloat()
public
static float() : FloatType
Return values
FloatTypeint()
public
static int() : IntType
Return values
IntTypename()
public
name() : string
Return values
stringobject()
public
static object(TObject> $class) : ObjectType<string|int, TObject>
Parameters
- $class : TObject>
Tags
Return values
ObjectType<string|int, TObject>string()
public
static string() : StringType