Transformer/ArrayMapTransformer.php
public function transform($values, array $options = [])
    {
        if (!\is_array($values) && !$values instanceof \Traversable) {
            throw new \UnexpectedValueException('Input value must be an array or traversable');
        }

        $resolver = new OptionsResolver();
        $this->configureOptions($resolver);
        /** @noinspection ExceptionsAnnotatingAndHandlingInspection */
        $options = $resolver->resolve($options);
        /** @var array $transformers */
        $transformers = $options['transformers'];

        $results = [];
        /** @noinspection ForeachSourceInspection */
        foreach ($values as $key => $item) {
            foreach ($transformers as $transformerCode => $transformerOptions) {
                if (null === $transformerOptions) {
                    $transformerOptions = [];
                }
                $transformer = $this->transformerRegistry->getTransformer($transformerCode);
                $item = $transformer->transform($item, $transformerOptions);
            }
            if (null === $item && $options['skip_null']) {
                continue;
            }
            $results[$key] = $item;
        }

        return $results;
    }
public function transform($values, array $options = [])
    {
        if (!\is_array($values) && !$values instanceof \Traversable) {
            throw new \UnexpectedValueException('Input value must be an array or traversable');
        }

        $resolver = new OptionsResolver();
        $this->configureOptions($resolver);
        /** @noinspection ExceptionsAnnotatingAndHandlingInspection */
        $options = $resolver->resolve($options);
        /** @var array $transformers */
        $transformers = $options['transformers'];

        $results = [];
        /** @noinspection ForeachSourceInspection */
        foreach ($values as $key => $item) {
            foreach ($transformers as $transformerCode => $transformerOptions) {
                if (null === $transformerOptions) {
                    $transformerOptions = [];
                }
                $transformer = $this->transformerRegistry->getTransformer($transformerCode);
                $item = $transformer->transform($item, $transformerOptions);
            }
            if (null === $item && $options['skip_null']) {
                continue;
            }
            $results[$key] = $item;
        }

        return $results;
    }
Must return the transformed $value

@param array $values
@param array $options

@throws \Symfony\Component\OptionsResolver\Exception\ExceptionInterface
@throws \UnexpectedValueException
@throws \CleverAge\ProcessBundle\Exception\MissingTransformerException

@return mixed $value