protected function XmlFileLoader::parseFile in Plug 7
Loads the XML class descriptions from the given file.
Parameters
string $path The path of the XML file:
Return value
\SimpleXMLElement The class descriptions
Throws
MappingException If the file could not be loaded
1 call to XmlFileLoader::parseFile()
- XmlFileLoader::loadClassMetadata in lib/
Symfony/ validator/ Symfony/ Component/ Validator/ Mapping/ Loader/ XmlFileLoader.php - Loads validation metadata into a {@link ClassMetadata} instance.
File
- lib/
Symfony/ validator/ Symfony/ Component/ Validator/ Mapping/ Loader/ XmlFileLoader.php, line 174
Class
- XmlFileLoader
- Loads validation metadata from an XML file.
Namespace
Symfony\Component\Validator\Mapping\LoaderCode
protected function parseFile($path) {
try {
$dom = XmlUtils::loadFile($path, __DIR__ . '/schema/dic/constraint-mapping/constraint-mapping-1.0.xsd');
} catch (\Exception $e) {
throw new MappingException($e
->getMessage(), $e
->getCode(), $e);
}
return simplexml_import_dom($dom);
}