/** * Validate the document against the given list of XML Schema documents. * * @param AgaviXmlConfigDomDocument The document to act upon. * @param array An array of schema documents to validate against. * * @author David Zülke <*****@*****.**> * @author Noah Fontes <*****@*****.**> * @since 1.0.0 */ public static function validateXmlschemaSource(AgaviXmlConfigDomDocument $document, array $validationSources = array()) { foreach ($validationSources as $validationSource) { try { $document->schemaValidateSource($validationSource); } catch (DOMException $dome) { throw new AgaviParseException(sprintf('XML Schema validation of configuration file "%s" failed:' . "\n\n%s", $document->documentURI, $dome->getMessage())); } } }