ModelGuards
Bundles all guard layers for a model object: the abilities, the permissions and the validators. It also composes those layers for the actions of the model and is therefore the only layer that knows the full recipe for an action.
-
new ModelGuards()
-
$modelGuards->abilities()
-
$modelGuards->availability()
-
$modelGuards->ensureAvailable()
-
$modelGuards->ensureExecutable()
-
ModelGuards::for()
-
$modelGuards->has()
-
$modelGuards->isAvailable()
-
$modelGuards->isExecutable()
-
$modelGuards->permissions()
-
$modelGuards->user()
-
$modelGuards->validators()