protected function getViewLayout( PhpView $view ) {
		$layout_headers = array_filter( get_file_data(
			$view->getFilepath(),
			['App Layout']
		) );

		if ( empty( $layout_headers ) ) {
			return null;
		}

		$layout_file = trim( $layout_headers[0] );

		if ( ! $this->exists( $layout_file ) ) {
			throw new ViewNotFoundException( 'View layout not found for "' . $layout_file . '"' );
		}

		return $this->makeView( $this->canonical( $layout_file ), $this->resolveFilepath( $layout_file ) );
	}
protected function getViewLayout( PhpView $view ) {
		$layout_headers = array_filter( get_file_data(
			$view->getFilepath(),
			['App Layout']
		) );

		if ( empty( $layout_headers ) ) {
			return null;
		}

		$layout_file = trim( $layout_headers[0] );

		if ( ! $this->exists( $layout_file ) ) {
			throw new ViewNotFoundException( 'View layout not found for "' . $layout_file . '"' );
		}

		return $this->makeView( $this->canonical( $layout_file ), $this->resolveFilepath( $layout_file ) );
	}
protected function getViewLayout ( PhpView $ view ) { $ layout_headers = array_filter ( get_file_data ( $ view -> getFilepath ( ) , [ 'App Layout' ] ) ) ; if ( empty ( $ layout_headers ) ) { return null ; } $ layout_file = trim ( $ layout_headers [ 0 ] ) ; if ( ! $ this -> exists ( $ layout_file ) ) { throw new ViewNotFoundException ( 'View layout not found for "' . $ layout_file . '"' ) ; } return $ this -> makeView ( $ this -> canonical ( $ layout_file ) , $ this -> resolveFilepath ( $ layout_file ) ) ; }
Create a view instance for the given view's layout header, if any.

@param  PhpView $view
@return ViewInterface
@throws ViewNotFoundException
Create a view instance for the given view s layout header if any .