You are here

public function Group::setSource in RNG - Events and Registrations 8

Same name and namespace in other branches
  1. 8.2 src/Entity/Group.php \Drupal\rng\Entity\Group::setSource()
  2. 3.x src/Entity/Group.php \Drupal\rng\Entity\Group::setSource()

Set which module created this group.

Parameters

string $module: Name of a module.

Return value

\Drupal\rng\GroupInterface Returns group for chaining.

Overrides GroupInterface::setSource

File

src/Entity/Group.php, line 81

Class

Group
Defines the application group entity class.

Namespace

Drupal\rng\Entity

Code

public function setSource($module = NULL) {
  $this
    ->set('source', [
    'value' => $module,
  ]);
  return $this;
}