if (isset($this->loading
[$id])) { throw new ServiceCircularReferenceException($id,
array_keys($this->loading
));
} $definition =
$this->serviceDefinitions
[$id] ?? NULL;
if (!
$definition &&
$invalid_behavior === ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE
) { if (!
$id) { throw new ServiceNotFoundException(''
);
} throw new ServiceNotFoundException($id, NULL, NULL,
$this->
getServiceAlternatives($id));
} // In case something else than ContainerInterface::NULL_ON_INVALID_REFERENCE
// is used, the actual wanted behavior is to re-try getting the service at a
// later point.
if (!
$definition) { return NULL;
} // Definition is a keyed array, so [0] is only defined when it is a
// serialized string.