You are here

public function ClosureStrategy::extract in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/zendframework/zend-hydrator/src/Strategy/ClosureStrategy.php \Zend\Hydrator\Strategy\ClosureStrategy::extract()

Converts the given value so that it can be extracted by the hydrator.

Parameters

mixed $value The original value.:

array $object The object is optionally provided as context.:

Return value

mixed Returns the value that should be extracted.

Overrides StrategyInterface::extract

File

vendor/zendframework/zend-hydrator/src/Strategy/ClosureStrategy.php, line 93

Class

ClosureStrategy

Namespace

Zend\Hydrator\Strategy

Code

public function extract($value, $object = null) {
  $func = $this->extractFunc;
  return $func($value, $object);
}