function ComputedItemListTrait::setValue

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/TypedData/ComputedItemListTrait.php \Drupal\Core\TypedData\ComputedItemListTrait::setValue()
  2. 8.9.x core/lib/Drupal/Core/TypedData/ComputedItemListTrait.php \Drupal\Core\TypedData\ComputedItemListTrait::setValue()
  3. 10 core/lib/Drupal/Core/TypedData/ComputedItemListTrait.php \Drupal\Core\TypedData\ComputedItemListTrait::setValue()
1 method overrides ComputedItemListTrait::setValue()
ModerationStateFieldItemList::setValue in core/modules/content_moderation/src/Plugin/Field/ModerationStateFieldItemList.php
Overrides \Drupal\Core\TypedData\TypedData::setValue().

File

core/lib/Drupal/Core/TypedData/ComputedItemListTrait.php, line 50

Class

ComputedItemListTrait
Provides common functionality for computed item lists.

Namespace

Drupal\Core\TypedData

Code

public function setValue($values, $notify = TRUE) {
    parent::setValue($values, $notify);
    // Make sure that subsequent getter calls do not try to compute the values
    // again.
    $this->valueComputed = TRUE;
}

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