PHP Trait Collective\Annotations\Routing\Annotations\EndpointTrait

Mostra file Open project: laravelcollective/annotations

Public Methods

Method Description
addPath ( AbstractPath $path ) : void Add the given path definition to the endpoint.
getMethodForPath ( AbstractPath $path ) : string Get the controller method for the given endpoint path.

Protected Methods

Method Description
implodeArray ( array $array ) : string Implode the given list into a comma separated string.
middlewareAppliesToMethod ( string $method, array $middleware ) : boolean Determine if the middleware applies to a given method.

Method Details

addPath() public method

Add the given path definition to the endpoint.
public addPath ( AbstractPath $path ) : void
$path AbstractPath
return void

getMethodForPath() public method

Get the controller method for the given endpoint path.
public getMethodForPath ( AbstractPath $path ) : string
$path AbstractPath
return string

implodeArray() protected method

Implode the given list into a comma separated string.
protected implodeArray ( array $array ) : string
$array array
return string

middlewareAppliesToMethod() protected method

Determine if the middleware applies to a given method.
protected middlewareAppliesToMethod ( string $method, array $middleware ) : boolean
$method string
$middleware array
return boolean