MergesProps
trait MergesProps
Properties
| protected bool | $merge | Indicates if the property should be merged. |
|
| protected bool | $deepMerge | Indicates if the property should be deep merged. |
|
| protected array<int, string> | $matchOn | The properties to match on for merging. |
|
| protected bool | $append | Indicates if the property values should be appended or prepended. |
|
| protected array<int, string> | $appendsAtPaths | The paths to append. |
|
| protected array<int, string> | $prependsAtPaths | The paths to prepend. |
Methods
Mark the property for merging.
Mark the property for deep merging.
Set the properties to match on for merging.
Determine if the property should be merged.
Determine if the property should be deep merged.
Get the properties to match on for merging.
Determine if the property should be appended at the root level.
Determine if the property should be prepended at the root level.
Determine if the property merges at the root level.
Specify that the value should be appended, optionally providing a key to append and a property to match on.
Specify that the value should be prepended, optionally providing a key to prepend and a property to match on.
Get the paths to append.
Get the paths to prepend.
Details
at line 50
MergesProps
merge()
Mark the property for merging.
at line 60
MergesProps
deepMerge()
Mark the property for deep merging.
at line 72
MergesProps
matchOn(string|array $matchOn)
Set the properties to match on for merging.
at line 82
bool
shouldMerge()
Determine if the property should be merged.
at line 90
bool
shouldDeepMerge()
Determine if the property should be deep merged.
at line 100
array
matchesOn()
Get the properties to match on for merging.
at line 108
bool
appendsAtRoot()
Determine if the property should be appended at the root level.
at line 116
bool
prependsAtRoot()
Determine if the property should be prepended at the root level.
at line 124
protected bool
mergesAtRoot()
Determine if the property merges at the root level.
at line 134
MergesProps
append(bool|string|array $path = true, string|null $matchOn = null)
Specify that the value should be appended, optionally providing a key to append and a property to match on.
at line 156
MergesProps
prepend(bool|string|array $path = true, string|null $matchOn = null)
Specify that the value should be prepended, optionally providing a key to prepend and a property to match on.
at line 178
array
appendsAtPaths()
Get the paths to append.
at line 188
array
prependsAtPaths()
Get the paths to prepend.