コード例 #1
0
ファイル: XMLServiceImpl.java プロジェクト: objectledge/ledge
 public com.sun.msv.grammar.Grammar getGrammar(String grammarID) throws Exception {
   return xmlGrammarCache.getGrammar(grammarID);
 }
コード例 #2
0
ファイル: XMLServiceImpl.java プロジェクト: objectledge/ledge
 public com.sun.msv.verifier.VerifierFilter getVerifierFilter(
     String grammarID, ErrorHandler errorHandler) throws Exception {
   return xmlGrammarCache.getVerifierFilter(grammarID, errorHandler);
 }
コード例 #3
0
ファイル: XMLValidator.java プロジェクト: objectledge/ledge
 /**
  * Returns a thread-exclusive verifier instance.
  *
  * @param schemaUrl the URL of the schema to be used.
  * @return a thread-exclusive verifier instance.
  * @throws ParserConfigurationException if parser is badly configured.
  * @throws IOException if the schema does not exist.
  * @throws SAXException if the schema is malformed.
  */
 public Verifier getVerifier(URL schemaUrl)
     throws SAXException, ParserConfigurationException, IOException {
   Grammar grammar = grammarCache.getGrammar(schemaUrl);
   DocumentDeclaration documentDeclaration = new REDocumentDeclaration(grammar);
   return new Verifier(documentDeclaration, errorHandler);
 }