/** * Get a cached {@link XMLOutputFactory} instance using the specified * configuration and the default cache policy. * * @param configuration * the configuration applied to the requested factory * @return an {@link XMLOutputFactory} instance. */ public static XMLOutputFactory getXMLOutputFactory(StAXWriterConfiguration configuration) { return getXMLOutputFactory(configuration, isFactoryPerClassLoader); }
/** * Get a cached {@link XMLOutputFactory} instance using the default * configuration and cache policy (i.e. one instance per class loader). * * @return an {@link XMLOutputFactory} instance. */ public static XMLOutputFactory getXMLOutputFactory() { return getXMLOutputFactory(null, isFactoryPerClassLoader); }
/** * Get a cached {@link XMLOutputFactory} instance using the default * configuration and the specified cache policy. * * @param factoryPerClassLoaderPolicy * the cache policy; see * {@link #getXMLOutputFactory(StAXWriterConfiguration, boolean)} * for more details * @return an {@link XMLOutputFactory} instance. */ public static XMLOutputFactory getXMLOutputFactory(boolean factoryPerClassLoaderPolicy) { return getXMLOutputFactory(null, factoryPerClassLoaderPolicy); }
private static XMLStreamWriter createXMLStreamWriter(Writer out) throws XMLStreamException { XMLOutputFactory outputFactory = StAXUtils.getXMLOutputFactory(ABDERA_WRITER_CONFIGURATION); XMLStreamWriter writer = outputFactory.createXMLStreamWriter(out); return writer; }
private static XMLStreamWriter createXMLStreamWriter(OutputStream out, String encoding) throws XMLStreamException { XMLOutputFactory outputFactory = StAXUtils.getXMLOutputFactory(ABDERA_WRITER_CONFIGURATION); XMLStreamWriter writer = outputFactory.createXMLStreamWriter(out, encoding); return writer; }
public static XMLStreamWriter createXMLStreamWriter(StAXWriterConfiguration configuration, Writer out) throws XMLStreamException { XMLStreamWriter writer = getXMLOutputFactory(configuration).createXMLStreamWriter(out); if (log.isDebugEnabled()) { log.debug("XMLStreamWriter is " + writer.getClass().getName()); } return writer; }
public static XMLStreamWriter createXMLStreamWriter(StAXWriterConfiguration configuration, OutputStream out) throws XMLStreamException { XMLStreamWriter writer = getXMLOutputFactory(configuration).createXMLStreamWriter(out, OMConstants.DEFAULT_CHAR_SET_ENCODING); if (log.isDebugEnabled()) { log.debug("XMLStreamWriter is " + writer.getClass().getName()); } return writer; }
public static XMLStreamWriter createXMLStreamWriter(StAXWriterConfiguration configuration, OutputStream out, String encoding) throws XMLStreamException { XMLStreamWriter writer = getXMLOutputFactory(configuration).createXMLStreamWriter(out, encoding); if (log.isDebugEnabled()) { log.debug("XMLStreamWriter is " + writer.getClass().getName()); } return writer; }