You are here

class TestComplexData in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 core/modules/serialization/tests/src/Unit/Normalizer/ComplexDataNormalizerTest.php \Drupal\Tests\serialization\Unit\Normalizer\TestComplexData

Test class implementing ComplexDataInterface and IteratorAggregate.

Hierarchy

Expanded class hierarchy of TestComplexData

File

core/modules/serialization/tests/src/Unit/Normalizer/ComplexDataNormalizerTest.php, line 77
Contains \Drupal\Tests\serialization\Unit\Normalizer\ComplexDataNormalizerTest.

Namespace

Drupal\Tests\serialization\Unit\Normalizer
View source
class TestComplexData implements \IteratorAggregate, ComplexDataInterface {
  private $values;
  public function __construct(array $values = []) {
    $this->values = $values;
  }
  public function getIterator() {
    return new \ArrayIterator($this->values);
  }
  public function applyDefaultValue($notify = TRUE) {
  }
  public static function createInstance($definition, $name = NULL, TraversableTypedDataInterface $parent = NULL) {
  }
  public function get($property_name) {
  }
  public function getConstraints() {
  }
  public function getDataDefinition() {
  }
  public function getName() {
  }
  public function getParent() {
  }
  public function getProperties($include_computed = FALSE) {
  }
  public function getPropertyPath() {
  }
  public function getRoot() {
  }
  public function getString() {
  }
  public function getValue() {
  }
  public function isEmpty() {
  }
  public function onChange($name) {
  }
  public function set($property_name, $value, $notify = TRUE) {
  }
  public function setContext($name = NULL, TraversableTypedDataInterface $parent = NULL) {
  }
  public function setValue($value, $notify = TRUE) {
  }
  public function toArray() {
  }
  public function validate() {
  }

}

Members

Namesort descending Modifiers Type Description Overrides
TestComplexData::$values private property
TestComplexData::applyDefaultValue public function Applies the default value. Overrides TypedDataInterface::applyDefaultValue
TestComplexData::createInstance public static function Constructs a TypedData object given its definition and context. Overrides TypedDataInterface::createInstance
TestComplexData::get public function Gets a property object. Overrides ComplexDataInterface::get
TestComplexData::getConstraints public function Gets a list of validation constraints. Overrides TypedDataInterface::getConstraints
TestComplexData::getDataDefinition public function Gets the data definition. Overrides TypedDataInterface::getDataDefinition
TestComplexData::getIterator public function
TestComplexData::getName public function Returns the name of a property or item. Overrides TypedDataInterface::getName
TestComplexData::getParent public function Returns the parent data structure; i.e. either complex data or a list. Overrides TypedDataInterface::getParent
TestComplexData::getProperties public function Gets an array of property objects. Overrides ComplexDataInterface::getProperties
TestComplexData::getPropertyPath public function Returns the property path of the data. Overrides TypedDataInterface::getPropertyPath
TestComplexData::getRoot public function Returns the root of the typed data tree. Overrides TypedDataInterface::getRoot
TestComplexData::getString public function Returns a string representation of the data. Overrides TypedDataInterface::getString
TestComplexData::getValue public function Gets the data value. Overrides TypedDataInterface::getValue
TestComplexData::isEmpty public function Determines whether the data structure is empty. Overrides ComplexDataInterface::isEmpty
TestComplexData::onChange public function React to changes to a child property or item. Overrides TraversableTypedDataInterface::onChange
TestComplexData::set public function Sets a property value. Overrides ComplexDataInterface::set
TestComplexData::setContext public function Sets the context of a property or item via a context aware parent. Overrides TypedDataInterface::setContext
TestComplexData::setValue public function Sets the data value. Overrides TypedDataInterface::setValue
TestComplexData::toArray public function Returns an array of all property values. Overrides ComplexDataInterface::toArray
TestComplexData::validate public function Validates the currently set data value. Overrides TypedDataInterface::validate
TestComplexData::__construct public function