You are here

public function FeedType::getCustomSource in Feeds 8.3

Gets a custom a source.

Parameters

string $name: The name of the custom source to get.

Return value

array|null The properties of the custom source:

  • label A human readable name.
  • value The value to extract from the feed.
  • description (optional) A description of the source.

Null if the custom source doesn't exist.

Overrides FeedTypeInterface::getCustomSource

File

src/Entity/FeedType.php, line 384

Class

FeedType
Defines the Feeds feed type entity.

Namespace

Drupal\feeds\Entity

Code

public function getCustomSource($name) {
  if (!isset($this->custom_sources[$name])) {
    return NULL;
  }
  return $this->custom_sources[$name];
}