trait IncludeableData

Traits

Properties

protected PartialsDefinition|false|null $partialDefinitions

Null before defaults are inspected, false when they are empty, or the mutable definition store.

Methods

getPartialsDefinition()

Get the current partial definitions.

include(string ...$includes)

Include properties for the next transformation.

includePermanently(string ...$includes)

Include properties for every transformation.

exclude(string ...$excludes)

Exclude lazy properties for the next transformation.

excludePermanently(string ...$excludes)

Exclude lazy properties for every transformation.

only(string ...$only)

Keep only properties for the next transformation.

onlyPermanently(string ...$only)

Keep only properties for every transformation.

except(string ...$except)

Exclude properties for the next transformation.

exceptPermanently(string ...$except)

Exclude properties for every transformation.

includeWhen(string $include, bool|Closure $condition, bool $permanent = false)

Include a property when the condition passes.

excludeWhen(string $exclude, bool|Closure $condition, bool $permanent = false)

Exclude a lazy property when the condition passes.

onlyWhen(string $only, bool|Closure $condition, bool $permanent = false)

Keep only a property when the condition passes.

exceptWhen(string $except, bool|Closure $condition, bool $permanent = false)

Exclude a property when the condition passes.

bool
hasPartialsDefinition()

Determine whether this object has partial definitions.

array
includeProperties()

Get class-owned permanent include definitions.

array
excludeProperties()

Get class-owned permanent exclude definitions.

array
onlyProperties()

Get class-owned permanent only definitions.

array
exceptProperties()

Get class-owned permanent except definitions.

Details

at line 65
PartialsDefinition getPartialsDefinition()

Get the current partial definitions.

Return Value

PartialsDefinition

ForwardsToPartialsDefinition include(string ...$includes)

Include properties for the next transformation.

Parameters

string ...$includes

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition includePermanently(string ...$includes)

Include properties for every transformation.

Parameters

string ...$includes

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition exclude(string ...$excludes)

Exclude lazy properties for the next transformation.

Parameters

string ...$excludes

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition excludePermanently(string ...$excludes)

Exclude lazy properties for every transformation.

Parameters

string ...$excludes

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition only(string ...$only)

Keep only properties for the next transformation.

Parameters

string ...$only

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition onlyPermanently(string ...$only)

Keep only properties for every transformation.

Parameters

string ...$only

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition except(string ...$except)

Exclude properties for the next transformation.

Parameters

string ...$except

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition exceptPermanently(string ...$except)

Exclude properties for every transformation.

Parameters

string ...$except

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition includeWhen(string $include, bool|Closure $condition, bool $permanent = false)

Include a property when the condition passes.

Parameters

string $include
bool|Closure $condition
bool $permanent

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition excludeWhen(string $exclude, bool|Closure $condition, bool $permanent = false)

Exclude a lazy property when the condition passes.

Parameters

string $exclude
bool|Closure $condition
bool $permanent

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition onlyWhen(string $only, bool|Closure $condition, bool $permanent = false)

Keep only a property when the condition passes.

Parameters

string $only
bool|Closure $condition
bool $permanent

Return Value

ForwardsToPartialsDefinition

ForwardsToPartialsDefinition exceptWhen(string $except, bool|Closure $condition, bool $permanent = false)

Exclude a property when the condition passes.

Parameters

string $except
bool|Closure $condition
bool $permanent

Return Value

ForwardsToPartialsDefinition

at line 24
bool hasPartialsDefinition()

Determine whether this object has partial definitions.

Return Value

bool

at line 88
protected array includeProperties()

Get class-owned permanent include definitions.

Return Value

array

at line 96
protected array excludeProperties()

Get class-owned permanent exclude definitions.

Return Value

array

at line 104
protected array onlyProperties()

Get class-owned permanent only definitions.

Return Value

array

at line 112
protected array exceptProperties()

Get class-owned permanent except definitions.

Return Value

array