class Illuminate / Routing / PendingResourceRegistration

PendingResourceRegistration

Uses

Properties

protected

$registrar ResourceRegistrar

The resource registrar.

Default: null
protected

$name string

The resource name.

Default: null
protected

$controller string

The resource controller.

Default: null
protected

$options array

The resource options.

Default: []
protected

$registered bool

The resource's registration status.

Default: false

Methods

public

__construct ( ResourceRegistrar $registrar , $name , $controller , array $options ) : void

Create a new pending resource registration instance.

Parameters

public

only ( $methods ) : PendingResourceRegistration

Set the methods the controller should apply to.

Parameters

  • $methods array|string|mixed
public

except ( $methods ) : PendingResourceRegistration

Set the methods the controller should exclude.

Parameters

  • $methods array|string|mixed
public

names ( $names ) : PendingResourceRegistration

Set the route names for controller actions.

Parameters

  • $names array|string
public

name ( $method , $name ) : PendingResourceRegistration

Set the route name for a controller action.

Parameters

  • $method string
  • $name string
public

parameters ( $parameters ) : PendingResourceRegistration

Override the route parameter names.

Parameters

  • $parameters array|string
public

parameter ( $previous , $new ) : PendingResourceRegistration

Override a route parameter's name.

Parameters

  • $previous string
  • $new string
public

middleware ( $middleware ) : PendingResourceRegistration

Add middleware to the resource routes.

Parameters

  • $middleware mixed
public

withoutMiddleware ( $middleware ) : $this|array

Specify middleware that should be removed from the resource routes.

Parameters

  • $middleware array|string
public

where ( $wheres ) : PendingResourceRegistration

Add "where" constraints to the resource routes.

Parameters

  • $wheres mixed
public

shallow ( $shallow ) : PendingResourceRegistration

Indicate that the resource routes should have "shallow" nesting.

Parameters

  • $shallow bool
public

missing ( $callback ) : $this

Define the callable that should be invoked on a missing model exception.

Parameters

  • $callback callable
public

scoped ( array $fields ) : PendingResourceRegistration

Indicate that the resource routes should be scoped using the given binding fields.

Parameters

  • $fields array
public

withTrashed ( array $methods ) : PendingResourceRegistration

Define which routes should allow "trashed" models to be retrieved when resolving implicit model bindings.

Parameters

  • $methods array
public

register ( ) : RouteCollection

Register the resource route.

public

__destruct ( ) : void

Handle the object's destruction.