public function TextProcessed::__construct

Overrides TypedData::__construct().

Overrides TypedData::__construct

File

drupal/core/modules/text/lib/Drupal/text/TextProcessed.php, line 40
Definition of Drupal\text\TextProcessed.

Class

TextProcessed
A computed property for processing text with a format.

Namespace

Drupal\text

Code

public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL) {
  parent::__construct($definition, $name, $parent);
  if (!isset($definition['settings']['text source'])) {
    throw new InvalidArgumentException("The definition's 'source' key has to specify the name of the text property to be processed.");
  }
}