oldGrammars = new ArrayList();
// Remove the inline schema namespace if it is listed directly
// in the pool. If it is indirectly listed as an import of a grammar listed
// directly in the pool hide the grammar to continue to get caching benefits
// from the cached grammar.
Grammar[] grammars = pool.retrieveInitialGrammarSet(XMLGrammarDescription.XML_SCHEMA);
int numGrammars = grammars.length;
for(int i = 0; i < numGrammars; i++)
{
XMLGrammarDescription desc = grammars[i].getGrammarDescription();
if(targetNamespace.equals(desc.getNamespace()))