class TamperItem in Tamper 8
Defines a single tamper item class.
Hierarchy
- class \Drupal\tamper\TamperItem implements TamperableItemInterface
Expanded class hierarchy of TamperItem
1 file declares its use of TamperItem
- CopyTest.php in tests/
src/ Unit/ Plugin/ Tamper/ CopyTest.php
File
- src/
TamperItem.php, line 10
Namespace
Drupal\tamperView source
class TamperItem implements TamperableItemInterface {
/**
* {@inheritdoc}
*/
public function getSource() {
return get_object_vars($this);
}
/**
* {@inheritdoc}
*/
public function getSourceProperty($property) {
return isset($this->{$property}) ? $this->{$property} : NULL;
}
/**
* {@inheritdoc}
*/
public function setSourceProperty($property, $data) {
$this->{$property} = $data;
return $this;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
TamperItem:: |
public | function |
Returns the whole item as an array. Overrides TamperableItemInterface:: |
|
TamperItem:: |
public | function |
Retrieves a source property. Overrides TamperableItemInterface:: |
|
TamperItem:: |
public | function |
Sets a source property. Overrides TamperableItemInterface:: |