function Node::setTitle

Same name in other branches
  1. 9 core/modules/node/src/Entity/Node.php \Drupal\node\Entity\Node::setTitle()
  2. 10 core/modules/node/src/Entity/Node.php \Drupal\node\Entity\Node::setTitle()
  3. 11.x core/modules/node/src/Entity/Node.php \Drupal\node\Entity\Node::setTitle()

Overrides NodeInterface::setTitle

File

core/modules/node/src/Entity/Node.php, line 208

Class

Node
Defines the node entity class.

Namespace

Drupal\node\Entity

Code

public function setTitle($title) {
    $this->set('title', $title);
    return $this;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.