|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.axis2.json.JSONDataSource
public class JSONDataSource
JSONDataSource keeps the JSON String inside and consumes it when needed. This is to be kept in the OMSourcedElementImpl and can be used either to expand the tree or get the JSON String directly without expanding. This uses the "Mapped" JSON convention.
Field Summary | |
---|---|
protected java.lang.String |
localName
|
Constructor Summary | |
---|---|
JSONDataSource(java.io.InputStream jsonInputStream,
java.lang.String localName)
|
Method Summary | |
---|---|
java.lang.String |
getCompleteJOSNString()
|
protected java.lang.String |
getJSONString()
|
javax.xml.stream.XMLStreamReader |
getReader()
Gives the StAX reader using the "Mapped" formatted input JSON String. |
void |
serialize(java.io.OutputStream outputStream,
org.apache.axiom.om.OMOutputFormat omOutputFormat)
Writes JSON into the output stream. |
void |
serialize(java.io.Writer writer,
org.apache.axiom.om.OMOutputFormat omOutputFormat)
Writes JSON through the writer. |
void |
serialize(javax.xml.stream.XMLStreamWriter xmlStreamWriter)
Writes XML through the XMLStreamWriter. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.lang.String localName
Constructor Detail |
---|
public JSONDataSource(java.io.InputStream jsonInputStream, java.lang.String localName)
Method Detail |
---|
public void serialize(java.io.OutputStream outputStream, org.apache.axiom.om.OMOutputFormat omOutputFormat) throws javax.xml.stream.XMLStreamException
serialize
in interface org.apache.axiom.om.OMDataSource
outputStream
- the stream to be written intoomOutputFormat
- format of the message, this is ignored.
javax.xml.stream.XMLStreamException
- if there is an error while writing the message in to the output stream.public void serialize(java.io.Writer writer, org.apache.axiom.om.OMOutputFormat omOutputFormat) throws javax.xml.stream.XMLStreamException
serialize
in interface org.apache.axiom.om.OMDataSource
writer
- Writer to be written intoomOutputFormat
- format of the message, this is ignored.
javax.xml.stream.XMLStreamException
- if there is an error while writing the message through the writer.public void serialize(javax.xml.stream.XMLStreamWriter xmlStreamWriter) throws javax.xml.stream.XMLStreamException
serialize
in interface org.apache.axiom.om.OMDataSource
xmlStreamWriter
- StAX writer to be written into
javax.xml.stream.XMLStreamException
- if there is an error while writing the message through the StAX writer.public javax.xml.stream.XMLStreamReader getReader() throws javax.xml.stream.XMLStreamException
getReader
in interface org.apache.axiom.om.OMDataSource
javax.xml.stream.XMLStreamException
- if there is an error while making the StAX reader.protected java.lang.String getJSONString()
public java.lang.String getCompleteJOSNString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |