Purgeable
Table of Contents
- $originalPurgeableValues : array<string|int, mixed>
- addPurgeable() : $this
- Adds an attribute to the purgeable attributes list
- bootPurgeable() : void
- Boot the purgeable trait for a model.
- getOriginalPurgeValue() : mixed
- Returns the original values of any purged attributes.
- getOriginalPurgeValues() : mixed
- Returns the original values of any purged attributes.
- getPurgeableAttributes() : mixed
- Returns a collection of fields that will be hashed.
- purgeAttributes() : array<string|int, mixed>
- Removes purged attributes from the dataset, used before saving.
- restorePurgedValues() : mixed
- Restores the original values of any purged attributes.
Properties
$originalPurgeableValues
protected
array<string|int, mixed>
$originalPurgeableValues
= []
List of original attribute values before they were purged.
Methods
addPurgeable()
Adds an attribute to the purgeable attributes list
public
addPurgeable([array<string|int, mixed>|string|null $attributes = null ]) : $this
Parameters
- $attributes : array<string|int, mixed>|string|null = null
Return values
$this —bootPurgeable()
Boot the purgeable trait for a model.
public
static bootPurgeable() : void
Return values
void —getOriginalPurgeValue()
Returns the original values of any purged attributes.
public
getOriginalPurgeValue(mixed $attribute) : mixed
Parameters
- $attribute : mixed
Return values
mixed —getOriginalPurgeValues()
Returns the original values of any purged attributes.
public
getOriginalPurgeValues() : mixed
Return values
mixed —getPurgeableAttributes()
Returns a collection of fields that will be hashed.
public
getPurgeableAttributes() : mixed
Return values
mixed —purgeAttributes()
Removes purged attributes from the dataset, used before saving.
public
purgeAttributes([mixed $attributesToPurge = null ]) : array<string|int, mixed>
Parameters
- $attributesToPurge : mixed = null
Return values
array<string|int, mixed> —Current attribute set
restorePurgedValues()
Restores the original values of any purged attributes.
public
restorePurgedValues() : mixed