class CerPresetFeaturesController in Corresponding Entity References 7.3
Contains the controller class for exporting CER presets via Features.
Hierarchy
Expanded class hierarchy of CerPresetFeaturesController
1 string reference to 'CerPresetFeaturesController'
- cer_entity_info in ./
cer.module - Implements hook_entity_info().
File
- includes/
CerPresetFeaturesController.inc, line 7
View source
class CerPresetFeaturesController extends EntityDefaultFeaturesController {
/**
* Overridden.
*/
public function export($data, &$export, $module = '') {
$pipe = parent::export($data, $export, $module);
// Every field in both chains may need to export additional things (the
// field base and instance definitions at least, plus any extra dependencies).
// All that logic is delegated to CerFieldChain.
foreach (entity_load_multiple_by_name($this->type, $data) as $preset) {
$pipe = array_merge_recursive($pipe, $preset->wrapper->cer_left->chain
->value()
->export());
$pipe = array_merge_recursive($pipe, $preset->wrapper->cer_right->chain
->value()
->export());
}
return $pipe;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
CerPresetFeaturesController:: |
public | function |
Overridden. Overrides EntityDefaultFeaturesController:: |
|
EntityDefaultFeaturesController:: |
protected | property | ||
EntityDefaultFeaturesController:: |
public | function | Defines the result for hook_features_api(). | |
EntityDefaultFeaturesController:: |
public | function | Generates the result for hook_features_export_options(). | |
EntityDefaultFeaturesController:: |
public | function | Generates the result for hook_features_export_render(). | |
EntityDefaultFeaturesController:: |
public | function | Generates the result for hook_features_revert(). | |
EntityDefaultFeaturesController:: |
public | function |