You are here

public function TestDisplayVariant::setMainContent in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/system/tests/modules/display_variant_test/src/Plugin/DisplayVariant/TestDisplayVariant.php \Drupal\display_variant_test\Plugin\DisplayVariant\TestDisplayVariant::setMainContent()

Sets the main content for the page being rendered.

Parameters

array $main_content: The render array representing the main content.

Return value

$this

Overrides PageVariantInterface::setMainContent

File

core/modules/system/tests/modules/display_variant_test/src/Plugin/DisplayVariant/TestDisplayVariant.php, line 74
Contains \Drupal\display_variant_test\Plugin\DisplayVariant\TestDisplayVariant.

Class

TestDisplayVariant
Provides a display variant that requires configuration.

Namespace

Drupal\display_variant_test\Plugin\DisplayVariant

Code

public function setMainContent(array $main_content) {
  $this->mainContent = $main_content;
  return $this;
}