public function ResourceFieldBase::executeProcessCallbacks in RESTful 7.2
Executes the process callbacks.
Parameters
mixed $value: The initial value.
Return value
mixed The processed value.
Overrides ResourceFieldInterface::executeProcessCallbacks
1 call to ResourceFieldBase::executeProcessCallbacks()
- ResourceField::render in src/
Plugin/ resource/ Field/ ResourceField.php - Gets the value of a field and applies all process callbacks to it.
File
- src/
Plugin/ resource/ Field/ ResourceFieldBase.php, line 341 - Contains \Drupal\restful\Plugin\resource\Field\ResourceFieldBase.
Class
Namespace
Drupal\restful\Plugin\resource\FieldCode
public function executeProcessCallbacks($value) {
$process_callbacks = $this
->getProcessCallbacks();
if (!isset($value) || empty($process_callbacks)) {
return $value;
}
foreach ($process_callbacks as $process_callback) {
$value = ResourceManager::executeCallback($process_callback, array(
$value,
));
}
return $value;
}