Imbo\Http\Request\Request::getRoute PHP Метод

getRoute() публичный Метод

Get the current route
public getRoute ( ) : Imbo\Router\Route
Результат Imbo\Router\Route
    public function getRoute()
    {
        return $this->route;
    }

Usage Example

Пример #1
0
 /**
  * @covers Imbo\Http\Request\Request::getRoute
  * @covers Imbo\Http\Request\Request::setRoute
  */
 public function testCanSetAndGetARoute()
 {
     $this->assertNull($this->request->getRoute());
     $route = $this->getMockBuilder('Imbo\\Router\\Route')->disableOriginalConstructor()->getMock();
     $this->assertSame($this->request, $this->request->setRoute($route));
     $this->assertSame($route, $this->request->getRoute());
 }