Home » Xerces-J-src.2.9.1 » org.apache.xerces » parsers » [javadoc | source]
org.apache.xerces.parsers
public class: XMLGrammarPreparser [javadoc | source]
java.lang.Object
   org.apache.xerces.parsers.XMLGrammarPreparser

This class provides an easy way for a user to preparse grammars of various types. By default, it knows how to preparse external DTD's and schemas; it provides an easy way for user applications to register classes that know how to parse additional grammar types. By default, it does no grammar caching; but it provides ways for user applications to do so.

Nested Class Summary:
static class  XMLGrammarPreparser.XMLGrammarLoaderContainer  Container for an XMLGrammarLoader. Also holds the modCount that the XMLGrammarPreparser had the last time it was used. 
Field Summary
protected static final  String SYMBOL_TABLE    Property identifier: symbol table. 
protected static final  String ERROR_REPORTER    Property identifier: error reporter. 
protected static final  String ERROR_HANDLER    Property identifier: error handler. 
protected static final  String ENTITY_RESOLVER    Property identifier: entity resolver. 
protected static final  String GRAMMAR_POOL    Property identifier: grammar pool . 
protected  SymbolTable fSymbolTable     
protected  XMLErrorReporter fErrorReporter     
protected  XMLEntityResolver fEntityResolver     
protected  XMLGrammarPool fGrammarPool     
protected  Locale fLocale     
Constructor:
 public XMLGrammarPreparser() 
 public XMLGrammarPreparser(SymbolTable symbolTable) 
    Constructs a preparser using the specified symbol table.
    Parameters:
    symbolTable - The symbol table to use.
Method from org.apache.xerces.parsers.XMLGrammarPreparser Summary:
getEntityResolver,   getErrorHandler,   getFeature,   getGrammarPool,   getLoader,   getLocale,   getProperty,   preparseGrammar,   registerPreparser,   setEntityResolver,   setErrorHandler,   setFeature,   setGrammarPool,   setLocale,   setProperty
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.xerces.parsers.XMLGrammarPreparser Detail:
 public XMLEntityResolver getEntityResolver() 
    Returns the registered entity resolver.
 public XMLErrorHandler getErrorHandler() 
    Returns the registered error handler.
 public boolean getFeature(String type,
    String featureId) 
 public XMLGrammarPool getGrammarPool() 
    Returns the registered grammar pool.
 public XMLGrammarLoader getLoader(String type) 
 public Locale getLocale() 
    Return the Locale the XMLGrammarLoader is using.
 public Object getProperty(String type,
    String propertyId) 
 public Grammar preparseGrammar(String type,
    XMLInputSource is) throws IOException, XNIException 
    Parse a grammar from a location identified by an XMLInputSource. This method also adds this grammar to the XMLGrammarPool
 public boolean registerPreparser(String grammarType,
    XMLGrammarLoader loader) 
 public  void setEntityResolver(XMLEntityResolver entityResolver) 
    Sets the entity resolver.
 public  void setErrorHandler(XMLErrorHandler errorHandler) 
    Sets the error handler.
 public  void setFeature(String featureId,
    boolean value) 
 public  void setGrammarPool(XMLGrammarPool grammarPool) 
    Sets the grammar pool.
 public  void setLocale(Locale locale) 
    Set the locale to use for messages.
 public  void setProperty(String propId,
    Object value)