PHP 클래스 Neos\Flow\Mvc\Routing\Router

상속: implements Neos\Flow\Mvc\Routing\RouterInterface
파일 보기 프로젝트 열기: neos/flow-development-collection 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$configurationManager Neos\Flow\Configuration\ConfigurationManager
$lastMatchedRoute Route
$lastResolvedRoute Route
$routerCachingService RouterCachingService
$routes array Array of routes to match against
$routesConfiguration array Array containing the configuration for all routes
$routesCreated boolean TRUE if route object have been created, otherwise FALSE
$systemLogger Neos\Flow\Log\SystemLoggerInterface

공개 메소드들

메소드 설명
addRoute ( Route $route ) : void Manually adds a route to the beginning of the configured routes
getLastMatchedRoute ( ) : Route Returns the route that has been matched with the last route() call.
getLastResolvedRoute ( ) : Route Returns the route that has been resolved with the last resolve() call.
getRoutes ( ) : array Returns a list of configured routes
resolve ( array $routeValues ) : string Builds the corresponding uri (excluding protocol and host) by iterating through all configured routes and calling their respective resolves() method. If no matching route is found, an empty string is returned.
route ( Request $httpRequest ) : array Iterates through all configured routes and calls matches() on them.
setRoutesConfiguration ( array $routesConfiguration = null ) : void Sets the routes configuration.

보호된 메소드들

메소드 설명
createRoutesFromConfiguration ( ) : void Creates \Neos\Flow\Mvc\Routing\Route objects from the injected routes configuration.
initializeRoutesConfiguration ( ) : void Checks if a routes configuration was set and otherwise loads the configuration from the configuration manager.

메소드 상세

addRoute() 공개 메소드

Manually adds a route to the beginning of the configured routes
public addRoute ( Route $route ) : void
$route Route
리턴 void

createRoutesFromConfiguration() 보호된 메소드

Creates \Neos\Flow\Mvc\Routing\Route objects from the injected routes configuration.
protected createRoutesFromConfiguration ( ) : void
리턴 void

getLastMatchedRoute() 공개 메소드

Returns NULL if no route matched or route() has not been called yet
public getLastMatchedRoute ( ) : Route
리턴 Route

getLastResolvedRoute() 공개 메소드

Returns NULL if no route was found or resolve() has not been called yet
public getLastResolvedRoute ( ) : Route
리턴 Route

getRoutes() 공개 메소드

Returns a list of configured routes
public getRoutes ( ) : array
리턴 array

initializeRoutesConfiguration() 보호된 메소드

Checks if a routes configuration was set and otherwise loads the configuration from the configuration manager.
protected initializeRoutesConfiguration ( ) : void
리턴 void

resolve() 공개 메소드

Note: calls of this message are cached by RouterCachingAspect
public resolve ( array $routeValues ) : string
$routeValues array Key/value pairs to be resolved. E.g. array('@package' => 'MyPackage', '@controller' => 'MyController');
리턴 string

route() 공개 메소드

Returns the matchResults of the matching route or NULL if no matching route could be found.
public route ( Request $httpRequest ) : array
$httpRequest Neos\Flow\Http\Request The web request to be analyzed. Will be modified by the router.
리턴 array The results of the matching route or NULL if no route matched

setRoutesConfiguration() 공개 메소드

Sets the routes configuration.
public setRoutesConfiguration ( array $routesConfiguration = null ) : void
$routesConfiguration array The routes configuration or NULL if it should be fetched from configuration
리턴 void

프로퍼티 상세

$configurationManager 보호되어 있는 프로퍼티

protected ConfigurationManager,Neos\Flow\Configuration $configurationManager
리턴 Neos\Flow\Configuration\ConfigurationManager

$lastMatchedRoute 보호되어 있는 프로퍼티

protected Route,Neos\Flow\Mvc\Routing $lastMatchedRoute
리턴 Route

$lastResolvedRoute 보호되어 있는 프로퍼티

protected Route,Neos\Flow\Mvc\Routing $lastResolvedRoute
리턴 Route

$routerCachingService 보호되어 있는 프로퍼티

protected RouterCachingService,Neos\Flow\Mvc\Routing $routerCachingService
리턴 RouterCachingService

$routes 보호되어 있는 프로퍼티

Array of routes to match against
protected array $routes
리턴 array

$routesConfiguration 보호되어 있는 프로퍼티

Array containing the configuration for all routes
protected array $routesConfiguration
리턴 array

$routesCreated 보호되어 있는 프로퍼티

TRUE if route object have been created, otherwise FALSE
protected bool $routesCreated
리턴 boolean

$systemLogger 보호되어 있는 프로퍼티

protected SystemLoggerInterface,Neos\Flow\Log $systemLogger
리턴 Neos\Flow\Log\SystemLoggerInterface