xmlif.setXMLReporter( (new XMLReporter() {
@Override public void setXMLReporter(XMLReporter arg0) { inputFactory.setXMLReporter(arg0); }
public void setXMLReporter(XMLReporter reporter) { parent.setXMLReporter(reporter); }
public void setXMLReporter(XMLReporter arg0) { wrappedFactory.setXMLReporter(arg0); }
@Override public void setXMLReporter(XMLReporter arg0) { inputFactory.setXMLReporter(arg0); }
public void setXMLReporter(final XMLReporter reporter) { actual.setXMLReporter(reporter); }
/** * Returns the factory for StAX readers. The same instance is returned for all {@code StaxDataStore} lifetime. * Warnings emitted by readers created by this factory will be forwarded to the {@link #listeners}. * * <p>This method is indirectly invoked by {@link #createReader(StaxStreamReader)}, * through a call to {@link InputType#create(StaxDataStore, Object)}.</p> */ final XMLInputFactory inputFactory() { assert Thread.holdsLock(this); if (inputFactory == null) { inputFactory = XMLInputFactory.newInstance(); inputFactory.setXMLReporter(configuration); } return inputFactory; }
/** * Creates a new DcsPullDriver. Uses the JVM-provided {@link XMLOutputFactory} and {@link XMLInputFactory} for * creating XML stream readers and writers. Specifically, the properties that are available and their defaults are * dependent on the JVM. * * @param replacer the XmlFriendlyReplacer to use * @param qnames the QName map */ public DcsPullDriver(XmlFriendlyReplacer replacer, QNameMap qnames) { super(replacer); outFactory = XMLOutputFactory.newInstance(); inFactory = XMLInputFactory.newInstance(); inFactory.setXMLReporter(new XMLReporter() { @Override public void report(String s, String s1, Object o, Location location) throws XMLStreamException { log.warn("{} {} {} {}", new Object[] {s, s1, o, location}); } }); this.replacer = replacer; this.qnames = qnames; }
public TMXReader2() { factory = XMLInputFactory.newInstance(); factory.setProperty(XMLInputFactory.IS_NAMESPACE_AWARE, false); factory.setXMLReporter(new XMLReporter() { public void report(String message, String errorType, Object info, Location location) throws XMLStreamException { Log.logWarningRB("TMXR_WARNING_WHILE_PARSING", location.getLineNumber(), location.getColumnNumber()); Log.log(message + ": " + info); warningsCount++; } }); factory.setXMLResolver(TMX_DTD_RESOLVER_2); dateFormat1 = new SimpleDateFormat("yyyyMMdd'T'HHmmss'Z'", Locale.ENGLISH); dateFormat1.setTimeZone(TimeZone.getTimeZone("UTC")); dateFormat2 = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss'Z'", Locale.ENGLISH); dateFormat2.setTimeZone(TimeZone.getTimeZone("UTC")); dateFormatOut = new SimpleDateFormat("yyyyMMdd'T'HHmmss'Z'", Locale.ENGLISH); dateFormatOut.setTimeZone(TimeZone.getTimeZone("UTC")); }
/** * Creates a new DcsPullDriver. Uses the JVM-provided {@link XMLOutputFactory} and {@link XMLInputFactory} for * creating XML stream readers and writers. Specifically, the properties that are available and their defaults are * dependent on the JVM. * * @param qnames the QName map */ public DcsPullDriver(QNameMap qnames) { outFactory = XMLOutputFactory.newInstance(); inFactory = XMLInputFactory.newInstance(); inFactory.setXMLReporter(new XMLReporter() { @Override public void report(String s, String s1, Object o, Location location) throws XMLStreamException { log.warn("{} {} {} {}", new Object[] {s, s1, o, location}); } }); this.replacer = new XmlFriendlyReplacer(); this.qnames = qnames; }
/** * Supply an input stream containing XML to be parsed. A StAX parser is created using * the JAXP XMLInputFactory. * @param systemId The Base URI of the input document * @param inputStream the stream containing the XML to be parsed * @throws XPathException if an error occurs creating the StAX parser */ public void setInputStream(String systemId, InputStream inputStream) throws XPathException { try { XMLInputFactory factory = XMLInputFactory.newInstance(); //XMLInputFactory factory = new WstxInputFactory(); factory.setXMLReporter(new StaxErrorReporter()); reader = factory.createXMLStreamReader(systemId, inputStream); } catch (XMLStreamException e) { throw new XPathException(e); } }
/** * Supply an input stream containing XML to be parsed. A StAX parser is created using * the JAXP XMLInputFactory. * @param systemId The Base URI of the input document * @param inputStream the stream containing the XML to be parsed * @throws XPathException if an error occurs creating the StAX parser */ public void setInputStream(String systemId, InputStream inputStream) throws XPathException { try { XMLInputFactory factory = XMLInputFactory.newInstance(); //XMLInputFactory factory = new WstxInputFactory(); factory.setXMLReporter(new StaxErrorReporter()); reader = factory.createXMLStreamReader(systemId, inputStream); } catch (XMLStreamException e) { throw new XPathException(e); } }
/** * Supply an input stream containing XML to be parsed. A StAX parser is created using * the JAXP XMLInputFactory. * @param systemId The Base URI of the input document * @param inputStream the stream containing the XML to be parsed * @throws net.sf.saxon.trans.XPathException if an error occurs creating the StAX parser */ public void setInputStream(String systemId, InputStream inputStream) throws XPathException { try { XMLInputFactory factory = XMLInputFactory.newInstance(); //XMLInputFactory factory = new WstxInputFactory(); factory.setXMLReporter(new StaxErrorReporter()); reader = factory.createXMLStreamReader(systemId, inputStream); } catch (XMLStreamException e) { throw new XPathException(e); } }
/** * Supply an input stream containing XML to be parsed. A StAX parser is created using * the JAXP XMLInputFactory. * @param systemId The Base URI of the input document * @param inputStream the stream containing the XML to be parsed * @throws net.sf.saxon.trans.XPathException if an error occurs creating the StAX parser */ public void setInputStream(String systemId, InputStream inputStream) throws XPathException { try { XMLInputFactory factory = XMLInputFactory.newInstance(); //XMLInputFactory factory = new WstxInputFactory(); factory.setXMLReporter(new StaxErrorReporter()); reader = factory.createXMLStreamReader(systemId, inputStream); } catch (XMLStreamException e) { throw new XPathException(e); } }
/** * Supply an input stream containing XML to be parsed. A StAX parser is created using * the JAXP XMLInputFactory. * * @param systemId The Base URI of the input document * @param inputStream the stream containing the XML to be parsed * @throws XPathException if an error occurs creating the StAX parser */ public void setInputStream(String systemId, InputStream inputStream) throws XPathException { try { XMLInputFactory factory = XMLInputFactory.newInstance(); //XMLInputFactory factory = new WstxInputFactory(); factory.setXMLReporter(new StaxErrorReporter()); reader = factory.createXMLStreamReader(systemId, inputStream); } catch (XMLStreamException e) { throw new XPathException(e); } }
/** * Supply an input stream containing XML to be parsed. A StAX parser is created using * the JAXP XMLInputFactory. * * @param systemId The Base URI of the input document * @param inputStream the stream containing the XML to be parsed * @throws XPathException if an error occurs creating the StAX parser */ public void setInputStream(String systemId, InputStream inputStream) throws XPathException { try { XMLInputFactory factory = XMLInputFactory.newInstance(); //XMLInputFactory factory = new WstxInputFactory(); factory.setXMLReporter(new StaxErrorReporter()); reader = factory.createXMLStreamReader(systemId, inputStream); } catch (XMLStreamException e) { throw new XPathException(e); } }
inputFactory.setProperty("javax.xml.stream.isValidating", Boolean.FALSE); inputFactory.setXMLReporter(new XMLReporter() { @Override public void report(String message, String errorType, Object relatedInformation, Location location) throws XMLStreamException {
factory.setXMLReporter(configuration.reporter); factory.setXMLResolver(configuration.resolver);
inputFactory.setProperty("javax.xml.stream.isValidating", Boolean.FALSE); inputFactory.setXMLReporter(new XMLReporter() { @Override public void report(String message, String errorType, Object relatedInformation, Location location) throws XMLStreamException {
try { XMLInputFactory xif = XMLInputFactory.newInstance(); xif.setXMLReporter(new XMLReporter() { @Override public void report(String message, String errorType, Object relatedInformation, Location location) throws XMLStreamException {