interface ItemInterface in Feeds 8.3
The interface for a single feed item.
Hierarchy
- interface \Drupal\feeds\Feeds\Item\ItemInterface
Expanded class hierarchy of ItemInterface
All classes that implement ItemInterface
19 files declare their use of ItemInterface
- AfterParseBase.php in src/
EventSubscriber/ AfterParseBase.php - AfterParseBaseTest.php in tests/
src/ Unit/ EventSubscriber/ AfterParseBaseTest.php - BasicFieldSource.php in src/
Feeds/ Source/ BasicFieldSource.php - EntityEvent.php in src/
Event/ EntityEvent.php - EntityProcessorBase.php in src/
Feeds/ Processor/ EntityProcessorBase.php
File
- src/
Feeds/ Item/ ItemInterface.php, line 8
Namespace
Drupal\feeds\Feeds\ItemView source
interface ItemInterface {
/**
* Returns the value for a target field.
*
* @param string $field
* The name of the field.
*
* @return mixed|null
* The value that corresponds to this field, or null if it does not exist.
*/
public function get($field);
/**
* Sets a value for a field.
*
* @param string $field
* The name of the field.
* @param mixed $value
* The value for the field.
*
* @return $this
* An instance of this class.
*/
public function set($field, $value);
/**
* Converts the item to an array.
*
* @return array
* The data of the item.
*/
public function toArray();
/**
* Loads data in from an array.
*
* @param array $data
* The data to load in.
*
* @return $this
* An instance of this class.
*/
public function fromArray(array $data);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ItemInterface:: |
public | function | Loads data in from an array. | 2 |
ItemInterface:: |
public | function | Returns the value for a target field. | 2 |
ItemInterface:: |
public | function | Sets a value for a field. | 2 |
ItemInterface:: |
public | function | Converts the item to an array. | 2 |