Phlyty\App::response PHP Method

response() public method

Retrieve the response environment
public response ( ) : Zend\Http\PhpEnvironment\Response
return Zend\Http\PhpEnvironment\Response
    public function response()
    {
        if (!$this->response instanceof Response) {
            $this->setResponse(new Response());
        }
        return $this->response;
    }

Usage Example

Esempio n. 1
0
 public function testLazyLoadsResponse()
 {
     $app = new App();
     $response = $app->response();
     $this->assertInstanceOf('Zend\\Http\\PhpEnvironment\\Response', $response);
 }