EntityDisplayBase::removeComponent

public EntityDisplayBase::removeComponent($name)

Sets a component to be hidden.

Parameters

string $name: The name of the component.

Return value

$this

Overrides EntityDisplayInterface::removeComponent

File

core/lib/Drupal/Core/Entity/EntityDisplayBase.php, line 347

Class

EntityDisplayBase
Provides a common base class for entity view and form displays.

Namespace

Drupal\Core\Entity

Code

public function removeComponent($name) {
  $this->hidden[$name] = TRUE;
  unset($this->content[$name]);
  unset($this->plugins[$name]);

  return $this;
}
doc_Drupal
2016-10-29 09:05:18
Comments
Leave a Comment

Please login to continue.