public interface OMDataSourceExt extends OMDataSource
OMDataSource,
OMSourcedElement| Modifier and Type | Field and Description |
|---|---|
static String |
LOSSY_PREFIX |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the DataSource and free its resources.
|
OMDataSourceExt |
copy()
Create a copy of the OMDataSourceExt
|
Object |
getObject()
Returns the backing Object.
|
Object |
getProperty(String key)
Query a property stored on the OMDataSource
|
javax.xml.stream.XMLStreamReader |
getReader()
Get parser for element data.
|
byte[] |
getXMLBytes(String encoding)
Returns a byte[] representing the xml data
|
InputStream |
getXMLInputStream(String encoding)
Returns a InputStream representing the xml data
|
boolean |
hasProperty(String key)
Returns true if property is set
|
boolean |
isDestructiveRead()
Returns true if reading the backing object is destructive.
|
boolean |
isDestructiveWrite()
Returns true if writing the backing object is destructive.
|
void |
serialize(OutputStream output,
OMOutputFormat format)
Serializes element data directly to stream.
|
void |
serialize(Writer writer,
OMOutputFormat format)
Serializes element data directly to writer.
|
void |
serialize(javax.xml.stream.XMLStreamWriter xmlWriter)
Serializes element data directly to StAX writer.
|
Object |
setProperty(String key,
Object value)
Set a property on the OMDataSource
|
static final String LOSSY_PREFIX
void serialize(OutputStream output, OMOutputFormat format) throws javax.xml.stream.XMLStreamException
serialize in interface OMDataSourceoutput - destination stream for element XML textformat - Output format information. The implementation must use this information
to choose the correct character set encoding when writing to the
output stream. This parameter must not be null.javax.xml.stream.XMLStreamExceptionOMDataSourceExtvoid serialize(Writer writer, OMOutputFormat format) throws javax.xml.stream.XMLStreamException
serialize in interface OMDataSourcewriter - destination writer for element XML textformat - output format information (null if none; may
be ignored if not supported by data binding even if supplied)javax.xml.stream.XMLStreamExceptionOMDataSourceExtvoid serialize(javax.xml.stream.XMLStreamWriter xmlWriter) throws javax.xml.stream.XMLStreamException
serialize in interface OMDataSourcexmlWriter - destination writerjavax.xml.stream.XMLStreamExceptionOMDataSourceExtjavax.xml.stream.XMLStreamReader getReader() throws javax.xml.stream.XMLStreamException
getReader in interface OMDataSourcejavax.xml.stream.XMLStreamExceptionObject getObject()
boolean isDestructiveRead()
boolean isDestructiveWrite()
InputStream getXMLInputStream(String encoding) throws UnsupportedEncodingException
encoding - String encoding of InputStreamUnsupportedEncodingExceptionbyte[] getXMLBytes(String encoding) throws UnsupportedEncodingException
encoding - String encoding of InputStreamUnsupportedEncodingExceptiongetXMLInputStream(String)void close()
OMDataSourceExt copy()
boolean hasProperty(String key)
key - Object getProperty(String key)
key - Copyright © 2004-2013 The Apache Software Foundation. All Rights Reserved.