question: public Grammar parseGrammar ( String type , XMLInputSource is ) throws XNIException , IOException { if ( type . equals ( XMLGrammarDescription . XML_SCHEMA ) ) { return parseXMLSchema ( is ) ; } else if ( type . equals ( XMLGrammarDescription . XML_DTD ) ) { return parseDTD ( is ) ; } return null ; }
target:  Parse a grammar from a location identified by an XMLInputSource. This method also adds this grammar to the XMLGrammarPool