abstract class MediaFeedsProvider in Media Feeds 7
Same name and namespace in other branches
- 7.2 includes/MediaFeedsProvider.inc \MediaFeedsProvider
Base class for different Media Feeds providers.
Hierarchy
- class \MediaFeedsProvider
Expanded class hierarchy of MediaFeedsProvider
File
- includes/
MediaFeedsProvider.inc, line 11 - The MediaFeedsProvider base class.
View source
abstract class MediaFeedsProvider {
/**
* The FeedsSource.
*/
protected $source;
/**
* The target entity.
*/
protected $entity;
/**
* The target name.
*/
protected $target;
/**
* The values to save.
*/
protected $value;
/**
* An associative array of configuration options.
*/
protected $config;
/**
* Constructor of MediaFeedsProvider.
*
* @param $value
* The value to save.
*
* @param $config
* An associative array of configuration options.
*/
public function __construct($value, $config = array()) {
// Explicitly support FeedsEnclosure.
if ($value instanceof FeedsEnclosure) {
$value = $value
->getValue();
}
$this->value = $value;
$this->config = $config;
}
/**
* Validate the source value.
*/
public function validate() {
}
/**
* Create a file object from the source value.
*
* @return
* File object on success, FALSE on failure.
*/
public abstract function getFileObject();
/**
* Save the file in the database.
*
* @return
* The file object as it has been saved or FALSE on failure.
*/
public abstract function save();
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
MediaFeedsProvider:: |
protected | property | An associative array of configuration options. | |
MediaFeedsProvider:: |
protected | property | The target entity. | |
MediaFeedsProvider:: |
protected | property | The FeedsSource. | |
MediaFeedsProvider:: |
protected | property | The target name. | |
MediaFeedsProvider:: |
protected | property | The values to save. | |
MediaFeedsProvider:: |
abstract public | function | Create a file object from the source value. | 3 |
MediaFeedsProvider:: |
abstract public | function | Save the file in the database. | 3 |
MediaFeedsProvider:: |
public | function | Validate the source value. | 1 |
MediaFeedsProvider:: |
public | function | Constructor of MediaFeedsProvider. | 3 |