PHP Класс Adamgoose\Routing\Annotations\MethodEndpoint

Наследование: implements Adamgoose\Routing\Annotations\EndpointInterface, use trait EndpointTrait
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$classMiddleware array All of the class level "inherited" middleware defined for the pathless endpoint.
$method string The method that handles the route.
$middleware array All of the middleware defined for the pathless endpoint.
$paths array[Path] The route paths for the definition.
$reflection ReflectionClass The ReflectionClass instance for the controller class.
$uses string The controller and method that handles the route.

Открытые методы

Метод Описание
__construct ( array $attributes = [] ) : void Create a new route definition instance.
getPaths ( ) : array Get all of the path definitions for an endpoint.
hasPaths ( ) : boolean Determine if the endpoint has any paths.
toRouteDefinition ( ) : string Transform the endpoint into a route definition.

Защищенные методы

Метод Описание
getClassMiddlewareForPath ( AbstractPath $path ) : array Get the class middleware for the given path.
getMiddleware ( AbstractPath $path ) : array Get the middleware for the path.
getTemplate ( ) : string Get the template for the endpoint.

Описание методов

__construct() публичный метод

Create a new route definition instance.
public __construct ( array $attributes = [] ) : void
$attributes array
Результат void

getClassMiddlewareForPath() защищенный метод

Get the class middleware for the given path.
protected getClassMiddlewareForPath ( AbstractPath $path ) : array
$path AbstractPath
Результат array

getMiddleware() защищенный метод

Get the middleware for the path.
protected getMiddleware ( AbstractPath $path ) : array
$path AbstractPath
Результат array

getPaths() публичный метод

Get all of the path definitions for an endpoint.
public getPaths ( ) : array
Результат array

getTemplate() защищенный метод

Get the template for the endpoint.
protected getTemplate ( ) : string
Результат string

hasPaths() публичный метод

Determine if the endpoint has any paths.
public hasPaths ( ) : boolean
Результат boolean

toRouteDefinition() публичный метод

Transform the endpoint into a route definition.
public toRouteDefinition ( ) : string
Результат string

Описание свойств

$classMiddleware публичное свойство

All of the class level "inherited" middleware defined for the pathless endpoint.
public array $classMiddleware
Результат array

$method публичное свойство

The method that handles the route.
public string $method
Результат string

$middleware публичное свойство

All of the middleware defined for the pathless endpoint.
public array $middleware
Результат array

$paths публичное свойство

The route paths for the definition.
public array[Path] $paths
Результат array[Path]

$reflection публичное свойство

The ReflectionClass instance for the controller class.
public ReflectionClass $reflection
Результат ReflectionClass

$uses публичное свойство

The controller and method that handles the route.
public string $uses
Результат string