| Methods |
public
static
|
fromProperties<T, U is array<string, mixed>>(PrimitiveSchemaDefinitionBuilder<out T, out U> ...$properties): self
|
#
|
public
|
addProperty<T, U is array<string, mixed>>(PrimitiveSchemaDefinitionBuilder<out T, out U> $property): self
Adds a property to the schema. If a property with the same name already exists, it will not be added again.
This method does not mark the property as required. Use markAsRequired for that.
Adds a property to the schema. If a property with the same name already exists, it will not be added again.
This method does not mark the property as required. Use markAsRequired for that.
|
#
|
public
|
markAsRequired(non-empty-string $name): self
Marks a property as required in the schema.
Marks a property as required in the schema.
|
#
|
public
|
toArray(): array
|
#
|
public
|
jsonSerialize(): template-type<self, Arrayable, 'T'>
|
#
|