private JenaHandler initHandler(Model m) { if (m==null) return null; JenaHandler rslt = new JenaHandler(m, errorHandler); rslt.useWith(getHandlers()); return rslt; } private boolean closed = false;
public JenaHandler( Graph g, Model m, RDFErrorHandler e ) { this( g, modelToPrefixMapping( m ), e ); }
/** * Change the error handler. * <p> * Note that errors of class {@link ParseException}can be promoted using * the {@link ParseException#promote}method. See ARP documentation for * {@link org.xml.sax.ErrorHandler}for the details of error promotion. * * @param errHandler * The new error handler. * @return The old error handler. */ public RDFErrorHandler setErrorHandler(RDFErrorHandler errHandler) { RDFErrorHandler old = this.errorHandler; this.errorHandler = errHandler; if (handler != null) { handler.setErrorHandler(errHandler); } return old; }
private JenaHandler initHandler(Model m) { if (m==null) return null; JenaHandler rslt = new JenaHandler(m, errorHandler); rslt.useWith(getHandlers()); return rslt; } private boolean closed = false;
/** * Change the error handler. * <p> * Note that errors of class {@link ParseException}can be promoted using * the {@link ParseException#promote}method. See ARP documentation for * {@link org.xml.sax.ErrorHandler}for the details of error promotion. * * @param errHandler * The new error handler. * @return The old error handler. */ public RDFErrorHandler setErrorHandler(RDFErrorHandler errHandler) { RDFErrorHandler old = this.errorHandler; this.errorHandler = errHandler; if (handler != null) { handler.setErrorHandler(errHandler); } return old; }
public JenaHandler( Graph g, Model m, RDFErrorHandler e ) { this( g, modelToPrefixMapping( m ), e ); }
synchronized private void read(final Graph g, InputSource inputS, String xmlBase, Model m) { try { g.getEventManager().notifyEvent(g, GraphEvents.startRead); inputS.setSystemId(xmlBase); handler = new JenaHandler(g, m, errorHandler); handler.useWith(arpf.getHandlers()); arpf.parse(inputS, xmlBase); } catch (IOException e) { throw new WrappedIOException(e); } catch (SAXException e) { throw new JenaException(e); } finally { g.getEventManager().notifyEvent(g, GraphEvents.finishRead); handler = null; } }
/** * Change the error handler. * <p> * Note that errors of class {@link ParseException}can be promoted using * the {@link ParseException#promote}method. See ARP documentation for * {@link org.xml.sax.ErrorHandler}for the details of error promotion. * * @param errHandler * The new error handler. * @return The old error handler. */ @Override public RDFErrorHandler setErrorHandler(RDFErrorHandler errHandler) { RDFErrorHandler old = this.errorHandler; this.errorHandler = errHandler; JenaHandler h = handler; if (h != null) { h.setErrorHandler(errHandler); } return old; }
synchronized private void read(final Graph g, InputSource inputS, String xmlBase, Model m) { try { g.getEventManager().notifyEvent(g, GraphEvents.startRead); inputS.setSystemId(xmlBase); handler = new JenaHandler(g, m, errorHandler); handler.useWith(arpf.getHandlers()); arpf.parse(inputS, xmlBase); } catch (IOException e) { throw new WrappedIOException(e); } catch (SAXException e) { throw new JenaException(e); } finally { g.getEventManager().notifyEvent(g, GraphEvents.finishRead); handler = null; } }
/** * Change the error handler. * <p> * Note that errors of class {@link ParseException}can be promoted using * the {@link ParseException#promote}method. See ARP documentation for * {@link org.xml.sax.ErrorHandler}for the details of error promotion. * * @param errHandler * The new error handler. * @return The old error handler. */ @Override public RDFErrorHandler setErrorHandler(RDFErrorHandler errHandler) { RDFErrorHandler old = this.errorHandler; this.errorHandler = errHandler; JenaHandler h = handler; if (h != null) { h.setErrorHandler(errHandler); } return old; }