October\Rain\Router\CoreRouter

Overview

CoreRouter adds extra events to the base router and ensures late routes are registered with the caching system.

Extends
  • Illuminate\Routing\Router
Implements
  • Illuminate\Contracts\Routing\Registrar
  • Illuminate\Contracts\Routing\BindingRegistrar

Public Properties

There are no public properties in the class.

Show inherited public properties

Inherited Public Properties

  • $middlewarePriority - The priority-sorted list of middleware. (defined in Illuminate\Routing\Router)
  • $verbs - All of the verbs supported by the router. (defined in Illuminate\Routing\Router)

Protected Properties

protected bool $routerEventsBooted

Show inherited protected properties

Inherited Protected Properties

  • $events - The event dispatcher instance. (defined in Illuminate\Routing\Router)
  • $container - The IoC container instance. (defined in Illuminate\Routing\Router)
  • $routes - The route collection instance. (defined in Illuminate\Routing\Router)
  • $current - The currently dispatched route instance. (defined in Illuminate\Routing\Router)
  • $currentRequest - The request currently being dispatched. (defined in Illuminate\Routing\Router)
  • $middleware - All of the short-hand keys for middlewares. (defined in Illuminate\Routing\Router)
  • $middlewareGroups - All of the middleware groups. (defined in Illuminate\Routing\Router)
  • $binders - The registered route value binders. (defined in Illuminate\Routing\Router)
  • $patterns - The globally available parameter patterns. (defined in Illuminate\Routing\Router)
  • $groupStack - The route group attribute stack. (defined in Illuminate\Routing\Router)
  • $macros - The registered string macros. (defined in Illuminate\Routing\Router)

Public Methods

public after()

public after(string|callable $callback): void 

after is a new filter registered with the router.

public before()

public before(string|callable $callback): void 

before is a new filter registered with the router.

public dispatch()

public dispatch(
    Illuminate\Http\Request $request
): Illuminate\Http\Response|\Illuminate\Http\JsonResponse 

dispatch the request to the application.

public registerLateRoutes()

public registerLateRoutes(): void 

registerLateRoutes found within "before" filter, some are registered here.

Show inherited public methods

Inherited Public Methods

  • __call() - Dynamically handle calls into the router instance. (defined in Illuminate\Routing\Router)
  • __callStatic() - Dynamically handle calls to the class. (defined in Illuminate\Routing\Router)
  • __construct() - Create a new Router instance. (defined in Illuminate\Routing\Router)
  • addRoute() - Add a route to the underlying route collection. (defined in Illuminate\Routing\Router)
  • aliasMiddleware() - Register a short-hand name for a middleware. (defined in Illuminate\Routing\Router)
  • any() - Register a new route responding to all verbs. (defined in Illuminate\Routing\Router)
  • apiResource() - Route an API resource to a controller. (defined in Illuminate\Routing\Router)
  • apiResources() - Register an array of API resource controllers. (defined in Illuminate\Routing\Router)
  • apiSingleton() - Route an API singleton resource to a controller. (defined in Illuminate\Routing\Router)
  • apiSingletons() - Register an array of API singleton resource controllers. (defined in Illuminate\Routing\Router)
  • bind() - Add a new route parameter binder. (defined in Illuminate\Routing\Router)
  • current() - Get the currently dispatched route instance. (defined in Illuminate\Routing\Router)
  • currentRouteAction() - Get the current route action. (defined in Illuminate\Routing\Router)
  • currentRouteName() - Get the current route name. (defined in Illuminate\Routing\Router)
  • currentRouteNamed() - Determine if the current route matches a pattern. (defined in Illuminate\Routing\Router)
  • currentRouteUses() - Determine if the current route action matches a given action. (defined in Illuminate\Routing\Router)
  • delete() - Register a new DELETE route with the router. (defined in Illuminate\Routing\Router)
  • dispatchToRoute() - Dispatch the request to a route and return the response. (defined in Illuminate\Routing\Router)
  • fallback() - Register a new Fallback route with the router. (defined in Illuminate\Routing\Router)
  • flushMacros() - Flush the existing macros. (defined in Illuminate\Routing\Router)
  • flushMiddlewareGroups() - Flush the router's middleware groups. (defined in Illuminate\Routing\Router)
  • gatherRouteMiddleware() - Gather the middleware for the given route with resolved class names. (defined in Illuminate\Routing\Router)
  • get() - Register a new GET route with the router. (defined in Illuminate\Routing\Router)
  • getBindingCallback() - Get the binding callback for a given binding. (defined in Illuminate\Routing\Router)
  • getCurrentRequest() - Get the request currently being dispatched. (defined in Illuminate\Routing\Router)
  • getCurrentRoute() - Get the currently dispatched route instance. (defined in Illuminate\Routing\Router)
  • getGroupStack() - Get the current group stack for the router. (defined in Illuminate\Routing\Router)
  • getLastGroupPrefix() - Get the prefix from the last group on the stack. (defined in Illuminate\Routing\Router)
  • getMiddleware() - Get all of the defined middleware short-hand names. (defined in Illuminate\Routing\Router)
  • getMiddlewareGroups() - Get all of the defined middleware groups. (defined in Illuminate\Routing\Router)
  • getPatterns() - Get the global "where" patterns. (defined in Illuminate\Routing\Router)
  • getRoutes() - Get the underlying route collection. (defined in Illuminate\Routing\Router)
  • group() - Create a route group with shared attributes. (defined in Illuminate\Routing\Router)
  • has() - Check if a route with the given name exists. (defined in Illuminate\Routing\Router)
  • hasGroupStack() - Determine if the router currently has a group stack. (defined in Illuminate\Routing\Router)
  • hasMacro() - Checks if macro is registered. (defined in Illuminate\Routing\Router)
  • hasMiddlewareGroup() - Check if a middlewareGroup with the given name exists. (defined in Illuminate\Routing\Router)
  • input() - Get a route parameter for the current route. (defined in Illuminate\Routing\Router)
  • is() - Alias for the "currentRouteNamed" method. (defined in Illuminate\Routing\Router)
  • macro() - Register a custom macro. (defined in Illuminate\Routing\Router)
  • macroCall() - Dynamically handle calls to the class. (defined in Illuminate\Routing\Router)
  • match() - Register a new route with the given verbs. (defined in Illuminate\Routing\Router)
  • matched() - Register a route matched event listener. (defined in Illuminate\Routing\Router)
  • mergeWithLastGroup() - Merge the given array with the last group stack. (defined in Illuminate\Routing\Router)
  • middlewareGroup() - Register a group of middleware. (defined in Illuminate\Routing\Router)
  • mixin() - Mix another object into the class. (defined in Illuminate\Routing\Router)
  • model() - Register a model binder for a wildcard. (defined in Illuminate\Routing\Router)
  • newRoute() - Create a new Route object. (defined in Illuminate\Routing\Router)
  • options() - Register a new OPTIONS route with the router. (defined in Illuminate\Routing\Router)
  • patch() - Register a new PATCH route with the router. (defined in Illuminate\Routing\Router)
  • pattern() - Set a global where pattern on all routes. (defined in Illuminate\Routing\Router)
  • patterns() - Set a group of global where patterns on all routes. (defined in Illuminate\Routing\Router)
  • permanentRedirect() - Create a permanent redirect from one URI to another. (defined in Illuminate\Routing\Router)
  • post() - Register a new POST route with the router. (defined in Illuminate\Routing\Router)
  • prepareResponse() - Create a response instance from the given value. (defined in Illuminate\Routing\Router)
  • prependMiddlewareToGroup() - Add a middleware to the beginning of a middleware group. (defined in Illuminate\Routing\Router)
  • pushMiddlewareToGroup() - Add a middleware to the end of a middleware group. (defined in Illuminate\Routing\Router)
  • put() - Register a new PUT route with the router. (defined in Illuminate\Routing\Router)
  • redirect() - Create a redirect from one URI to another. (defined in Illuminate\Routing\Router)
  • removeMiddlewareFromGroup() - Remove the given middleware from the specified group. (defined in Illuminate\Routing\Router)
  • resolveMiddleware() - Resolve a flat array of middleware classes from the provided array. (defined in Illuminate\Routing\Router)
  • resource() - Route a resource to a controller. (defined in Illuminate\Routing\Router)
  • resourceParameters() - Set the global resource parameter mapping. (defined in Illuminate\Routing\Router)
  • resourceVerbs() - Get or set the verbs used in the resource URIs. (defined in Illuminate\Routing\Router)
  • resources() - Register an array of resource controllers. (defined in Illuminate\Routing\Router)
  • respondWithRoute() - Return the response returned by the given route. (defined in Illuminate\Routing\Router)
  • setCompiledRoutes() - Set the compiled route collection instance. (defined in Illuminate\Routing\Router)
  • setContainer() - Set the container instance used by the router. (defined in Illuminate\Routing\Router)
  • setRoutes() - Set the route collection instance. (defined in Illuminate\Routing\Router)
  • singleton() - Route a singleton resource to a controller. (defined in Illuminate\Routing\Router)
  • singletons() - Register an array of singleton resource controllers. (defined in Illuminate\Routing\Router)
  • singularResourceParameters() - Set the unmapped global resource parameters to singular. (defined in Illuminate\Routing\Router)
  • substituteBindings() - Substitute the route bindings onto the route. (defined in Illuminate\Routing\Router)
  • substituteImplicitBindings() - Substitute the implicit route bindings for the given route. (defined in Illuminate\Routing\Router)
  • toResponse() - Static version of prepareResponse. (defined in Illuminate\Routing\Router)
  • uniqueMiddleware() - Remove any duplicate middleware from the given array. (defined in Illuminate\Routing\Router)
  • uses() - Alias for the "currentRouteUses" method. (defined in Illuminate\Routing\Router)
  • view() - Register a new route that returns a view. (defined in Illuminate\Routing\Router)

Protected Methods

Show inherited protected methods

Inherited Protected Methods

  • actionReferencesController() - Determine if the action is routing to a controller. (defined in Illuminate\Routing\Router)
  • addWhereClausesToRoute() - Add the necessary where clauses to the route based on its initial registration. (defined in Illuminate\Routing\Router)
  • convertToControllerAction() - Add a controller based route action to the action array. (defined in Illuminate\Routing\Router)
  • createRoute() - Create a new route instance. (defined in Illuminate\Routing\Router)
  • findRoute() - Find the route matching a given request. (defined in Illuminate\Routing\Router)
  • loadRoutes() - Load the provided routes. (defined in Illuminate\Routing\Router)
  • mergeGroupAttributesIntoRoute() - Merge the group stack with the controller action. (defined in Illuminate\Routing\Router)
  • performBinding() - Call the binding callback for the given key. (defined in Illuminate\Routing\Router)
  • prefix() - Prefix the given URI with the last prefix. (defined in Illuminate\Routing\Router)
  • prependGroupController() - Prepend the last group controller onto the use clause. (defined in Illuminate\Routing\Router)
  • prependGroupNamespace() - Prepend the last group namespace onto the use clause. (defined in Illuminate\Routing\Router)
  • runRoute() - Return the response for the given route. (defined in Illuminate\Routing\Router)
  • runRouteWithinStack() - Run the given route within a Stack "onion" instance. (defined in Illuminate\Routing\Router)
  • sortMiddleware() - Sort the given middleware by priority. (defined in Illuminate\Routing\Router)
  • updateGroupStack() - Update the group stack with the given attributes. (defined in Illuminate\Routing\Router)