if (ContainerBuilder::
willBeAvailable('symfony/form', Form::
class,
['symfony/framework-bundle', 'symfony/translation'
])) { $r =
new \
ReflectionClass(Form::
class);
$dirs[] =
$transPaths[] = \
dirname($r->
getFileName()).'/Resources/translations';
} if (ContainerBuilder::
willBeAvailable('symfony/security-core', AuthenticationException::
class,
['symfony/framework-bundle', 'symfony/translation'
])) { $r =
new \
ReflectionClass(AuthenticationException::
class);
$dirs[] =
$transPaths[] = \
dirname($r->
getFileName(), 2
).'/Resources/translations';
} $defaultDir =
$container->
getParameterBag()->
resolveValue($config['default_path'
]);
foreach ($container->
getParameter('kernel.bundles_metadata'
) as $name =>
$bundle) { if ($container->
fileExists($dir =
$bundle['path'
].'/Resources/translations'
) ||
$container->
fileExists($dir =
$bundle['path'
].'/translations'
)) { $dirs[] =
$dir;
} else { $nonExistingDirs[] =
$dir;
} } foreach ($config['paths'
] as $dir) { if ($container->
fileExists($dir)) { $dirs[] =
$transPaths[] =
$dir;
}