final class Expect

Schema generator.

Methods

static Type
__callStatic(string $name, array $args)

No description

static Type
type(string $type)

No description

static AnyOf
anyOf(mixed ...$set)

No description

static Structure
structure(array $shape)

No description

static Structure
from(object|string $object, array $items = [])

No description

static Type
array(array|null $shape = [])

No description

static Type
arrayOf(Schema $valueType, Schema|null $keyType = null)

No description

static Type
listOf(Schema $type)

No description

static Type
scalar(mixed $default)

No description

static Type
string(mixed $default)

No description

static Type
int(mixed $default)

No description

static Type
float(mixed $default)

No description

static Type
bool(mixed $default)

No description

static Type
null()

No description

static Type
list(mixed $default)

No description

static Type
mixed(mixed $default)

No description

static Type
email(mixed $default)

No description

static Type
unicode(mixed $default)

No description

Details

at line 34
static Type __callStatic(string $name, array $args)

No description

Parameters

string $name
array $args

Return Value

Type

at line 45
static Type type(string $type)

No description

Parameters

string $type

Return Value

Type

at line 51
static AnyOf anyOf(mixed ...$set)

No description

Parameters

mixed ...$set

Return Value

AnyOf

at line 60
static Structure structure(array $shape)

No description

Parameters

array $shape

Return Value

Structure

at line 66
static Structure from(object|string $object, array $items = [])

No description

Parameters

object|string $object
array $items

Return Value

Structure

at line 112
static Type array(array|null $shape = [])

No description

Parameters

array|null $shape

Return Value

Type

at line 120
static Type arrayOf(Schema $valueType, Schema|null $keyType = null)

No description

Parameters

Schema $valueType
Schema|null $keyType

Return Value

Type

at line 126
static Type listOf(Schema $type)

No description

Parameters

Schema $type

Return Value

Type

at line 32
static Type scalar(mixed $default)

No description

Parameters

mixed $default

Return Value

Type

at line 32
static Type string(mixed $default)

No description

Parameters

mixed $default

Return Value

Type

at line 32
static Type int(mixed $default)

No description

Parameters

mixed $default

Return Value

Type

at line 32
static Type float(mixed $default)

No description

Parameters

mixed $default

Return Value

Type

at line 32
static Type bool(mixed $default)

No description

Parameters

mixed $default

Return Value

Type

at line 32
static Type null()

No description

Return Value

Type

at line 32
static Type list(mixed $default)

No description

Parameters

mixed $default

Return Value

Type

at line 32
static Type mixed(mixed $default)

No description

Parameters

mixed $default

Return Value

Type

at line 32
static Type email(mixed $default)

No description

Parameters

mixed $default

Return Value

Type

at line 32
static Type unicode(mixed $default)

No description

Parameters

mixed $default

Return Value

Type