You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicemix.apache.org by gn...@apache.org on 2012/01/03 16:30:39 UTC
svn commit: r1226822 - in /servicemix/smx4/specs/trunk: ./ activator/
activator/src/ activator/src/main/ activator/src/main/java/
activator/src/main/java/org/ activator/src/main/java/org/apache/
activator/src/main/java/org/apache/servicemix/ activator/...
Author: gnodet
Date: Tue Jan 3 15:30:38 2012
New Revision: 1226822
URL: http://svn.apache.org/viewvc?rev=1226822&view=rev
Log:
Experiment with the new specs using endorsed jars
Added:
servicemix/smx4/specs/trunk/activator/
servicemix/smx4/specs/trunk/activator/pom.xml
servicemix/smx4/specs/trunk/activator/src/
servicemix/smx4/specs/trunk/activator/src/main/
servicemix/smx4/specs/trunk/activator/src/main/java/
servicemix/smx4/specs/trunk/activator/src/main/java/org/
servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/
servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/servicemix/
servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/servicemix/specs/
servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/servicemix/specs/activator/
servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/servicemix/specs/activator/Activator.java
- copied, changed from r1190350, servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java
servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLEventFactory.java
servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLInputFactory.java
servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLOutputFactory.java
Modified:
servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java
servicemix/smx4/specs/trunk/pom.xml
servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/FactoryLocator.java
Added: servicemix/smx4/specs/trunk/activator/pom.xml
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/activator/pom.xml?rev=1226822&view=auto
==============================================================================
--- servicemix/smx4/specs/trunk/activator/pom.xml (added)
+++ servicemix/smx4/specs/trunk/activator/pom.xml Tue Jan 3 15:30:38 2012
@@ -0,0 +1,110 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+ <!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.servicemix.specs</groupId>
+ <artifactId>specs</artifactId>
+ <version>2.0-SNAPSHOT</version>
+ </parent>
+
+ <groupId>org.apache.servicemix.specs</groupId>
+ <artifactId>org.apache.servicemix.specs.activator</artifactId>
+ <packaging>jar</packaging>
+ <version>2.0-SNAPSHOT</version>
+ <name>Apache ServiceMix :: Specs :: Activator</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.servicemix.specs</groupId>
+ <artifactId>org.apache.servicemix.specs.locator</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.8</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-jar-plugin</artifactId>
+ <configuration>
+ <archive>
+ <manifestEntries>
+ <Karaf-Activator>org.apache.servicemix.specs.activator.Activator</Karaf-Activator>
+ </manifestEntries>
+ </archive>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>deploy</id>
+ <properties>
+ <createSourcesJar>true</createSourcesJar>
+ </properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-source-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>attach-sources</id>
+ <phase>package</phase>
+ <goals>
+ <goal>jar</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>package</id>
+ <phase>package</phase>
+ <goals>
+ <goal>jar</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <minmemory>128m</minmemory>
+ <maxmemory>512m</maxmemory>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+
+</project>
Copied: servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/servicemix/specs/activator/Activator.java (from r1190350, servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java)
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/servicemix/specs/activator/Activator.java?p2=servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/servicemix/specs/activator/Activator.java&p1=servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java&r1=1190350&r2=1226822&rev=1226822&view=diff
==============================================================================
--- servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java (original)
+++ servicemix/smx4/specs/trunk/activator/src/main/java/org/apache/servicemix/specs/activator/Activator.java Tue Jan 3 15:30:38 2012
@@ -14,7 +14,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.apache.servicemix.specs.locator;
+package org.apache.servicemix.specs.activator;
import java.io.BufferedReader;
import java.io.InputStreamReader;
@@ -26,6 +26,7 @@ import java.util.concurrent.Callable;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
+import org.apache.servicemix.specs.locator.OsgiLocator;
import org.osgi.framework.Bundle;
import org.osgi.framework.BundleActivator;
import org.osgi.framework.BundleContext;
@@ -112,7 +113,7 @@ public class Activator implements Bundle
}
if (map != null) {
for (Map.Entry<String, Callable<Class>> entry : map.entrySet()) {
- debugPrintln("registering service for key " + entry.getKey() + "with value " + entry.getValue());
+ debugPrintln("registering service for key " + entry.getKey() + " with value " + entry.getValue());
OsgiLocator.register(entry.getKey(), entry.getValue());
}
}
@@ -122,7 +123,7 @@ public class Activator implements Bundle
Map<String, Callable<Class>> map = factories.remove(bundleId);
if (map != null) {
for (Map.Entry<String, Callable<Class>> entry : map.entrySet()) {
- debugPrintln("unregistering service for key " + entry.getKey() + "with value " + entry.getValue());
+ debugPrintln("unregistering service for key " + entry.getKey() + " with value " + entry.getValue());
OsgiLocator.unregister(entry.getKey(), entry.getValue());
}
}
Modified: servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java?rev=1226822&r1=1226821&r2=1226822&view=diff
==============================================================================
--- servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java (original)
+++ servicemix/smx4/specs/trunk/locator/src/main/java/org/apache/servicemix/specs/locator/Activator.java Tue Jan 3 15:30:38 2012
@@ -112,7 +112,7 @@ public class Activator implements Bundle
}
if (map != null) {
for (Map.Entry<String, Callable<Class>> entry : map.entrySet()) {
- debugPrintln("registering service for key " + entry.getKey() + "with value " + entry.getValue());
+ debugPrintln("registering service for key " + entry.getKey() + " with value " + entry.getValue());
OsgiLocator.register(entry.getKey(), entry.getValue());
}
}
@@ -122,7 +122,7 @@ public class Activator implements Bundle
Map<String, Callable<Class>> map = factories.remove(bundleId);
if (map != null) {
for (Map.Entry<String, Callable<Class>> entry : map.entrySet()) {
- debugPrintln("unregistering service for key " + entry.getKey() + "with value " + entry.getValue());
+ debugPrintln("unregistering service for key " + entry.getKey() + " with value " + entry.getValue());
OsgiLocator.unregister(entry.getKey(), entry.getValue());
}
}
Modified: servicemix/smx4/specs/trunk/pom.xml
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/pom.xml?rev=1226822&r1=1226821&r2=1226822&view=diff
==============================================================================
--- servicemix/smx4/specs/trunk/pom.xml (original)
+++ servicemix/smx4/specs/trunk/pom.xml Tue Jan 3 15:30:38 2012
@@ -37,6 +37,7 @@
<modules>
<module>locator</module>
+ <module>activator</module>
<module>saaj-api-1.3</module>
<module>stax-api-1.0</module>
<module>jain-sip-api-1.2</module>
Modified: servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/FactoryLocator.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/FactoryLocator.java?rev=1226822&r1=1226821&r2=1226822&view=diff
==============================================================================
--- servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/FactoryLocator.java (original)
+++ servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/FactoryLocator.java Tue Jan 3 15:30:38 2012
@@ -56,7 +56,11 @@ class FactoryLocator {
ClassLoader classLoader) throws FactoryConfigurationError {
try {
// If we are deployed into an OSGi environment, leverage it
- Class factoryClass = FactoryLocator.class.getClassLoader().loadClass(factoryId);
+ ClassLoader cl = FactoryLocator.class.getClassLoader();
+ if (cl == null) {
+ cl = ClassLoader.getSystemClassLoader();
+ }
+ Class factoryClass = cl.loadClass(factoryId);
Class spiClass = org.apache.servicemix.specs.locator.OsgiLocator.locate(factoryClass, factoryId);
if (spiClass != null) {
return spiClass.newInstance();
Added: servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLEventFactory.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLEventFactory.java?rev=1226822&view=auto
==============================================================================
--- servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLEventFactory.java (added)
+++ servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLEventFactory.java Tue Jan 3 15:30:38 2012
@@ -0,0 +1,118 @@
+/*
+ **
+ ** Licensed to the Apache Software Foundation (ASF) under one
+ ** or more contributor license agreements. See the NOTICE file
+ ** distributed with this work for additional information
+ ** regarding copyright ownership. The ASF licenses this file
+ ** to you under the Apache License, Version 2.0 (the
+ ** "License"); you may not use this file except in compliance
+ ** with the License. You may obtain a copy of the License at
+ **
+ ** http://www.apache.org/licenses/LICENSE-2.0
+ **
+ ** Unless required by applicable law or agreed to in writing,
+ ** software distributed under the License is distributed on an
+ ** "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ** KIND, either express or implied. See the License for the
+ ** specific language governing permissions and limitations
+ ** under the License.
+ */
+package javax.xml.stream;
+
+import java.util.Iterator;
+
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.stream.events.ProcessingInstruction;
+import javax.xml.namespace.QName;
+import javax.xml.stream.events.Characters;
+import javax.xml.stream.events.Comment;
+import javax.xml.stream.events.DTD;
+import javax.xml.stream.events.EndElement;
+import javax.xml.stream.events.EntityDeclaration;
+import javax.xml.stream.events.Namespace;
+import javax.xml.stream.events.Attribute;
+import javax.xml.stream.events.EndDocument;
+import javax.xml.stream.events.EntityReference;
+import javax.xml.stream.events.StartDocument;
+import javax.xml.stream.events.StartElement;
+
+public abstract class XMLEventFactory {
+
+ protected XMLEventFactory() {
+ }
+
+ public static XMLEventFactory newInstance()
+ throws FactoryConfigurationError {
+ return (XMLEventFactory)FactoryLocator.locate("javax.xml.stream.XMLEventFactory", "com.sun.xml.internal.stream.events.XMLEventFactoryImpl");
+ }
+
+ public static XMLEventFactory newInstance(String factoryId,
+ ClassLoader classLoader) throws FactoryConfigurationError {
+ return (XMLEventFactory)FactoryLocator.locate(factoryId, "com.sun.xml.internal.stream.events.XMLEventFactoryImpl", classLoader);
+ }
+
+ public abstract void setLocation(Location location);
+
+ public abstract Attribute createAttribute(QName name, String value);
+
+ public abstract Attribute createAttribute(String localName, String value);
+
+ public abstract Attribute createAttribute(String prefix,
+ String namespaceURI, String localName, String value);
+
+ public abstract Namespace createNamespace(String namespaceUri);
+
+ public abstract Namespace createNamespace(String prefix, String namespaceUri);
+
+ public abstract StartElement createStartElement(QName name,
+ Iterator attributes, Iterator namespaces);
+
+ public abstract StartElement createStartElement(String prefix,
+ String namespaceUri, String localName);
+
+ public abstract StartElement createStartElement(String prefix,
+ String namespaceUri, String localName, Iterator attributes,
+ Iterator namespaces);
+
+ public abstract StartElement createStartElement(String prefix,
+ String namespaceUri, String localName, Iterator attributes,
+ Iterator namespaces, NamespaceContext context);
+
+ public abstract EndElement createEndElement(QName name, Iterator namespaces);
+
+ public abstract EndElement createEndElement(String prefix,
+ String namespaceUri, String localName);
+
+ public abstract EndElement createEndElement(String prefix,
+ String namespaceUri, String localName, Iterator namespaces);
+
+ public abstract Characters createCharacters(String content);
+
+ public abstract Characters createCData(String content);
+
+ public abstract Characters createSpace(String content);
+
+ public abstract Characters createIgnorableSpace(String content);
+
+ public abstract StartDocument createStartDocument();
+
+ public abstract StartDocument createStartDocument(String encoding);
+
+ public abstract StartDocument createStartDocument(String encoding,
+ String version);
+
+ public abstract StartDocument createStartDocument(String encoding,
+ String version, boolean standalone);
+
+ public abstract EndDocument createEndDocument();
+
+ public abstract EntityReference createEntityReference(String name,
+ EntityDeclaration declaration);
+
+ public abstract Comment createComment(String text);
+
+ public abstract ProcessingInstruction createProcessingInstruction(
+ String target, String data);
+
+ public abstract DTD createDTD(String dtd);
+}
Added: servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLInputFactory.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLInputFactory.java?rev=1226822&view=auto
==============================================================================
--- servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLInputFactory.java (added)
+++ servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLInputFactory.java Tue Jan 3 15:30:38 2012
@@ -0,0 +1,121 @@
+/*
+ **
+ ** Licensed to the Apache Software Foundation (ASF) under one
+ ** or more contributor license agreements. See the NOTICE file
+ ** distributed with this work for additional information
+ ** regarding copyright ownership. The ASF licenses this file
+ ** to you under the Apache License, Version 2.0 (the
+ ** "License"); you may not use this file except in compliance
+ ** with the License. You may obtain a copy of the License at
+ **
+ ** http://www.apache.org/licenses/LICENSE-2.0
+ **
+ ** Unless required by applicable law or agreed to in writing,
+ ** software distributed under the License is distributed on an
+ ** "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ** KIND, either express or implied. See the License for the
+ ** specific language governing permissions and limitations
+ ** under the License.
+ */
+package javax.xml.stream;
+
+import javax.xml.stream.util.XMLEventAllocator;
+
+public abstract class XMLInputFactory {
+ public static final java.lang.String ALLOCATOR = "javax.xml.stream.allocator";
+ public static final java.lang.String IS_COALESCING = "javax.xml.stream.isCoalescing";
+ public static final java.lang.String IS_NAMESPACE_AWARE = "javax.xml.stream.isNamespaceAware";
+ public static final java.lang.String IS_REPLACING_ENTITY_REFERENCES = "javax.xml.stream.isReplacingEntityReferences";
+ public static final java.lang.String IS_SUPPORTING_EXTERNAL_ENTITIES = "javax.xml.stream.isSupportingExternalEntities";
+ public static final java.lang.String IS_VALIDATING = "javax.xml.stream.isValidating";
+ public static final java.lang.String REPORTER = "javax.xml.stream.reporter";
+ public static final java.lang.String RESOLVER = "javax.xml.stream.resolver";
+ public static final java.lang.String SUPPORT_DTD = "javax.xml.stream.supportDTD";
+
+ protected XMLInputFactory() {
+ }
+
+ public static XMLInputFactory newInstance()
+ throws FactoryConfigurationError {
+ // We'll assume the XMLInputFactory from the RI as a backup.
+ return (XMLInputFactory)FactoryLocator.locate("javax.xml.stream.XMLInputFactory", "com.sun.xml.internal.stream.XMLInputFactoryImpl");
+ }
+
+ public static XMLInputFactory newInstance(java.lang.String factoryId,
+ java.lang.ClassLoader classLoader) throws FactoryConfigurationError {
+ // We'll assume the XMLInputFactory from the RI as a backup.
+ return (XMLInputFactory)FactoryLocator.locate(factoryId, "com.sun.xml.internal.stream.XMLInputFactoryImpl", classLoader);
+ }
+
+ public abstract XMLStreamReader createXMLStreamReader(java.io.Reader reader)
+ throws XMLStreamException;
+
+ public abstract XMLStreamReader createXMLStreamReader(
+ javax.xml.transform.Source source) throws XMLStreamException;
+
+ public abstract XMLStreamReader createXMLStreamReader(
+ java.io.InputStream stream) throws XMLStreamException;
+
+ public abstract XMLStreamReader createXMLStreamReader(
+ java.io.InputStream stream, java.lang.String encoding)
+ throws XMLStreamException;
+
+ public abstract XMLStreamReader createXMLStreamReader(
+ java.lang.String systemId, java.io.InputStream stream)
+ throws XMLStreamException;
+
+ public abstract XMLStreamReader createXMLStreamReader(
+ java.lang.String systemId, java.io.Reader reader)
+ throws XMLStreamException;
+
+ public abstract XMLEventReader createXMLEventReader(java.io.Reader reader)
+ throws XMLStreamException;
+
+ public abstract XMLEventReader createXMLEventReader(
+ java.lang.String systemId, java.io.Reader reader)
+ throws XMLStreamException;
+
+ public abstract XMLEventReader createXMLEventReader(XMLStreamReader reader)
+ throws XMLStreamException;
+
+ public abstract XMLEventReader createXMLEventReader(
+ javax.xml.transform.Source source) throws XMLStreamException;
+
+ public abstract XMLEventReader createXMLEventReader(
+ java.io.InputStream stream) throws XMLStreamException;
+
+ public abstract XMLEventReader createXMLEventReader(
+ java.io.InputStream stream, java.lang.String encoding)
+ throws XMLStreamException;
+
+ public abstract XMLEventReader createXMLEventReader(
+ java.lang.String systemId, java.io.InputStream stream)
+ throws XMLStreamException;
+
+ public abstract XMLStreamReader createFilteredReader(
+ XMLStreamReader reader, StreamFilter filter)
+ throws XMLStreamException;
+
+ public abstract XMLEventReader createFilteredReader(XMLEventReader reader,
+ EventFilter filter) throws XMLStreamException;
+
+ public abstract XMLResolver getXMLResolver();
+
+ public abstract void setXMLResolver(XMLResolver resolver);
+
+ public abstract XMLReporter getXMLReporter();
+
+ public abstract void setXMLReporter(XMLReporter reporter);
+
+ public abstract void setProperty(java.lang.String name,
+ java.lang.Object value) throws java.lang.IllegalArgumentException;
+
+ public abstract java.lang.Object getProperty(java.lang.String name)
+ throws java.lang.IllegalArgumentException;
+
+ public abstract boolean isPropertySupported(java.lang.String name);
+
+ public abstract void setEventAllocator(XMLEventAllocator allocator);
+
+ public abstract XMLEventAllocator getEventAllocator();
+}
Added: servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLOutputFactory.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLOutputFactory.java?rev=1226822&view=auto
==============================================================================
--- servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLOutputFactory.java (added)
+++ servicemix/smx4/specs/trunk/stax-api-1.0/src/main/java/javax/xml/stream/XMLOutputFactory.java Tue Jan 3 15:30:38 2012
@@ -0,0 +1,70 @@
+/*
+ **
+ ** Licensed to the Apache Software Foundation (ASF) under one
+ ** or more contributor license agreements. See the NOTICE file
+ ** distributed with this work for additional information
+ ** regarding copyright ownership. The ASF licenses this file
+ ** to you under the Apache License, Version 2.0 (the
+ ** "License"); you may not use this file except in compliance
+ ** with the License. You may obtain a copy of the License at
+ **
+ ** http://www.apache.org/licenses/LICENSE-2.0
+ **
+ ** Unless required by applicable law or agreed to in writing,
+ ** software distributed under the License is distributed on an
+ ** "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ** KIND, either express or implied. See the License for the
+ ** specific language governing permissions and limitations
+ ** under the License.
+ */
+package javax.xml.stream;
+
+public abstract class XMLOutputFactory {
+ public static final String IS_REPAIRING_NAMESPACES = "javax.xml.stream.isRepairingNamespaces";
+
+ protected XMLOutputFactory() { }
+
+ public static XMLOutputFactory newInstance()
+ throws FactoryConfigurationError {
+ return (XMLOutputFactory) FactoryLocator.locate("javax.xml.stream.XMLOutputFactory", "com.sun.xml.internal.stream.XMLOutputFactoryImpl");
+ }
+
+ public static XMLInputFactory newInstance(String factoryId,
+ java.lang.ClassLoader classLoader) throws FactoryConfigurationError {
+ return (XMLInputFactory) FactoryLocator.locate(factoryId, "com.sun.xml.internal.stream.XMLOutputFactoryImpl", classLoader);
+ }
+
+ public abstract XMLStreamWriter createXMLStreamWriter(java.io.Writer stream)
+ throws XMLStreamException;
+
+ public abstract XMLStreamWriter createXMLStreamWriter(
+ java.io.OutputStream stream) throws XMLStreamException;
+
+ public abstract XMLStreamWriter createXMLStreamWriter(
+ java.io.OutputStream stream, String encoding)
+ throws XMLStreamException;
+
+ public abstract XMLStreamWriter createXMLStreamWriter(
+ javax.xml.transform.Result result) throws XMLStreamException;
+
+ public abstract XMLEventWriter createXMLEventWriter(
+ javax.xml.transform.Result result) throws XMLStreamException;
+
+ public abstract XMLEventWriter createXMLEventWriter(
+ java.io.OutputStream stream) throws XMLStreamException;
+
+ public abstract XMLEventWriter createXMLEventWriter(
+ java.io.OutputStream stream, String encoding)
+ throws XMLStreamException;
+
+ public abstract XMLEventWriter createXMLEventWriter(java.io.Writer stream)
+ throws XMLStreamException;
+
+ public abstract void setProperty(String name, Object value)
+ throws IllegalArgumentException;
+
+ public abstract Object getProperty(String name)
+ throws IllegalArgumentException;
+
+ public abstract boolean isPropertySupported(String name);
+}