- java.lang.Object
-
- com.sun.xml.ws.api.server.SDDocumentSource
-
- Direct Known Subclasses:
SDDocumentImpl
public abstract class SDDocumentSource extends Object
SPI that provides the source ofSDDocument
.This abstract class could be implemented by applications, or one of the
create(java.lang.Class, java.lang.String)
methods can be used.- Author:
- Kohsuke Kawaguchi
-
-
Constructor Summary
Constructors Constructor Description SDDocumentSource()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static SDDocumentSource
create(Class implClass, String wsdlLocation)
static SDDocumentSource
create(URL url)
CreatesSDDocumentSource
from an URL.static SDDocumentSource
create(URL systemId, com.sun.xml.stream.buffer.XMLStreamBuffer xsb)
Creates aSDDocumentSource
fromXMLStreamBuffer
.abstract URL
getSystemId()
System ID of this document.abstract XMLStreamReader
read()
Returns theXMLStreamReader
that reads the document.abstract XMLStreamReader
read(XMLInputFactory xif)
Returns theXMLStreamReader
that reads the document.
-
-
-
Method Detail
-
read
public abstract XMLStreamReader read(XMLInputFactory xif) throws IOException, XMLStreamException
Returns theXMLStreamReader
that reads the document.This method maybe invoked multiple times concurrently.
- Parameters:
xif
- The implementation may choose to use this object when it wants to create a new parser (or it can just ignore this parameter completely.)- Returns:
- The caller is responsible for closing the reader to avoid resource leak.
- Throws:
XMLStreamException
- if something goes wrong while creating a parser.IOException
- if something goes wrong trying to read the document.
-
read
public abstract XMLStreamReader read() throws IOException, XMLStreamException
Returns theXMLStreamReader
that reads the document.This method maybe invoked multiple times concurrently.
- Returns:
- The caller is responsible for closing the reader to avoid resource leak.
- Throws:
XMLStreamException
- if something goes wrong while creating a parser.IOException
- if something goes wrong trying to read the document.
-
getSystemId
public abstract URL getSystemId()
System ID of this document.- Returns:
-
create
public static SDDocumentSource create(Class implClass, String wsdlLocation)
-
create
public static SDDocumentSource create(URL url)
CreatesSDDocumentSource
from an URL.- Parameters:
url
-- Returns:
-
create
public static SDDocumentSource create(URL systemId, com.sun.xml.stream.buffer.XMLStreamBuffer xsb)
Creates aSDDocumentSource
fromXMLStreamBuffer
.- Parameters:
systemId
-xsb
-- Returns:
-
-