You are here

class TestAttribute in Drupal 10

Same name and namespace in other branches
  1. 8 core/tests/Drupal/Tests/Core/Template/TwigSandboxTest.php \Drupal\Tests\Core\Template\TestAttribute
  2. 9 core/tests/Drupal/Tests/Core/Template/TwigSandboxTest.php \Drupal\Tests\Core\Template\TestAttribute

Hierarchy

  • class \Drupal\Core\Template\Attribute implements \Drupal\Core\Template\ArrayAccess, \Drupal\Core\Template\IteratorAggregate, MarkupInterface

Expanded class hierarchy of TestAttribute

File

core/tests/Drupal/Tests/Core/Template/TwigSandboxTest.php, line 162
Contains \Drupal\Tests\Core\Template\TwigSandboxTest.

Namespace

Drupal\Tests\Core\Template
View source
class TestAttribute extends Attribute {

}

Members

Namesort descending Modifiers Type Description Overrides
Attribute::$storage protected property Stores the attribute data.
Attribute::addClass public function Adds classes or merges them on to array of existing CSS classes.
Attribute::createAttributeValue protected function Creates the different types of attribute values.
Attribute::getClass public function Gets the class attribute value if set.
Attribute::getIterator public function
Attribute::hasAttribute public function Checks if the storage has an attribute with the given name.
Attribute::hasClass public function Checks if the class array has the given CSS class.
Attribute::jsonSerialize public function
Attribute::merge public function Merges an Attribute object into the current storage.
Attribute::offsetExists public function
Attribute::offsetGet public function
Attribute::offsetSet public function
Attribute::offsetUnset public function
Attribute::removeAttribute public function Removes an attribute from an Attribute object.
Attribute::removeClass public function Removes argument values from array of existing CSS classes.
Attribute::setAttribute public function Sets values for an attribute key.
Attribute::storage public function Returns the whole array.
Attribute::toArray public function Returns all storage elements as an array.
Attribute::__clone public function Implements the magic __clone() method.
Attribute::__construct public function Constructs a \Drupal\Core\Template\Attribute object.
Attribute::__toString public function Implements the magic __toString() method. Overrides MarkupInterface::__toString