class ViewPageController (View source)

Defines a page controller to execute and render a view.

Methods

array|Response
handle(string $view_id, string $display_id, RouteMatchInterface $route_match)

Handler a response for a given view and display.

getTitle(string $view_id, string $display_id = 'default')

Gets the title of the given view's display.

Details

array|Response handle(string $view_id, string $display_id, RouteMatchInterface $route_match)

Handler a response for a given view and display.

Parameters

string $view_id

The ID of the view

string $display_id

The ID of the display.

RouteMatchInterface $route_match

The route match.

Return Value

array|Response

A render array or a Response object.

string|MarkupInterface getTitle(string $view_id, string $display_id = 'default')

Gets the title of the given view's display.

Parameters

string $view_id

The id of the view.

string $display_id

The id of the display from the view.

Return Value

string|MarkupInterface

The title of the display of the view.