$emNormalizer =
function DOptions
$options,
$em) { if (null !==
$em) { if ($em instanceof ObjectManager
) { return $em;
} return $this->registry->
getManager($em);
} $em =
$this->registry->
getManagerForClass($options['class'
]);
if (null ===
$em) { throw new RuntimeException(sprintf('Class "%s" seems not to be a managed Doctrine entity. Did you forget to map it?',
$options['class'
]));
} return $em;
};
// Invoke the query builder closure so that we can cache choice lists
// for equal query builders
$queryBuilderNormalizer =
function DOptions
$options,
$queryBuilder) {