private void installLexicalHandler ( ) { XMLReader parent = getParent ( ) ; if ( parent == null ) { throw new NullPointerException ( "No parent for filter" ) ; } // try to register for lexical events for ( int i = 0 ; i < LEXICAL_HANDLER_NAMES . length ; i ++ ) { try { parent . setProperty ( LEXICAL_HANDLER_NAMES [ i ] , this ) ; break ; } catch ( SAXNotRecognizedException ex ) { // ignore } catch ( SAXNotSupportedException ex ) { // ignore } } }
Installs lexical handler before a parse .