class TestAttribute
Same name in this branch
- 10 core/tests/Drupal/Tests/Component/Plugin/Discovery/AttributeBridgeDecoratorTest.php \Drupal\Tests\Component\Plugin\Discovery\TestAttribute
Same name and namespace in other branches
- 9 core/tests/Drupal/Tests/Core/Template/TwigSandboxTest.php \Drupal\Tests\Core\Template\TestAttribute
- 8.9.x core/tests/Drupal/Tests/Core/Template/TwigSandboxTest.php \Drupal\Tests\Core\Template\TestAttribute
- 11.x core/tests/Drupal/Tests/Core/Template/TwigSandboxTest.php \Drupal\Tests\Core\Template\TestAttribute
- 11.x core/tests/Drupal/Tests/Component/Plugin/Discovery/AttributeBridgeDecoratorTest.php \Drupal\Tests\Component\Plugin\Discovery\TestAttribute
Hierarchy
- class \Drupal\Core\Template\Attribute extends \Drupal\Core\Template\ArrayAccess, \Drupal\Core\Template\IteratorAggregate, \Drupal\Component\Render\MarkupInterface
- class \Drupal\Tests\Core\Template\TestAttribute implements \Drupal\Core\Template\Attribute
Expanded class hierarchy of TestAttribute
File
-
core/
tests/ Drupal/ Tests/ Core/ Template/ TwigSandboxTest.php, line 160
Namespace
Drupal\Tests\Core\TemplateView source
class TestAttribute extends Attribute {
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title |
---|---|---|---|---|
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 | #[\ReturnTypeWillChange] | |
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 | Returns a representation of the object for use in JSON serialization. | |
Attribute::merge | public | function | Merges an Attribute object into the current storage. | |
Attribute::offsetExists | public | function | #[\ReturnTypeWillChange] | |
Attribute::offsetGet | public | function | #[\ReturnTypeWillChange] | |
Attribute::offsetSet | public | function | #[\ReturnTypeWillChange] | |
Attribute::offsetUnset | public | function | #[\ReturnTypeWillChange] | |
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 |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.