Authorize
class Authorize (View source)
Properties
| protected Gate | $gate | The gate instance. |
Methods
void
static string
using(UnitEnum|string $ability, string ...$models)
Specify the ability and models for the middleware.
mixed
array
bool
isClassName(string $value)
Checks if the given string looks like a fully qualified class name.
Details
void
__construct(Gate $gate)
Create a new middleware instance.
static string
using(UnitEnum|string $ability, string ...$models)
Specify the ability and models for the middleware.
mixed
handle(Request $request, Closure $next, string $ability, array|null ...$models)
Handle an incoming request.
protected array
getGateArguments(Request $request, array|null $models)
Get the arguments parameter for the gate.
protected bool
isClassName(string $value)
Checks if the given string looks like a fully qualified class name.
Laravel Cloud is the best place to deploy Laravel, Nuxt, Express, Hono, Node.js, Bun, Go, Flask, Python, and more, with dedicated infrastructure available on AWS through Laravel Private Cloud.