public class JSONDocument extends ForestDocument
ForestDocument JSON document node
representation of a document as stored in the expanded tree
cache of a forest on disk.
You cannot use this class to modify a document. However, you
can create a modifiable copy of the underlying document
using DocumentImpl on the
document returned by #getDocument.
| Modifier and Type | Field and Description |
|---|---|
static org.apache.commons.logging.Log |
LOG |
| Constructor and Description |
|---|
JSONDocument() |
JSONDocument(ExpandedTree tree) |
| Modifier and Type | Method and Description |
|---|---|
com.marklogic.xcc.Content |
createContent(String uri,
com.marklogic.xcc.ContentCreateOptions options,
boolean copyCollections,
boolean copyMetadata,
boolean copyQuality) |
byte[] |
getContentAsByteArray()
Return content as byte array.
|
MarkLogicNode |
getContentAsMarkLogicNode()
Return content as MarkLogicNode.
|
String |
getContentAsString()
Return content as String.
|
org.apache.hadoop.io.Text |
getContentAsText()
Return content as Text.
|
ContentType |
getContentType()
Return content type of the document.
|
void |
readFields(DataInput in) |
String |
toString() |
void |
write(DataOutput out) |
createDocument, getCollections, getContentAsByteStream, getContentSize, getFragmentOrdinal, getMetadata, getQuality, isStreamable, setContentOptions, setQualitypublic JSONDocument()
public JSONDocument(ExpandedTree tree)
public void readFields(DataInput in) throws IOException
readFields in interface MarkLogicDocumentreadFields in interface org.apache.hadoop.io.WritablereadFields in class ForestDocumentIOExceptionpublic void write(DataOutput out) throws IOException
write in interface MarkLogicDocumentwrite in interface org.apache.hadoop.io.Writablewrite in class ForestDocumentIOExceptionpublic byte[] getContentAsByteArray()
MarkLogicDocumentpublic org.apache.hadoop.io.Text getContentAsText()
MarkLogicDocumentpublic ContentType getContentType()
MarkLogicDocumentpublic MarkLogicNode getContentAsMarkLogicNode()
MarkLogicDocumentpublic String getContentAsString() throws UnsupportedEncodingException
MarkLogicDocumentUnsupportedEncodingExceptionpublic com.marklogic.xcc.Content createContent(String uri, com.marklogic.xcc.ContentCreateOptions options, boolean copyCollections, boolean copyMetadata, boolean copyQuality) throws IOException
createContent in class ForestDocumentIOExceptionCopyright © 2024 MarkLogic Corporation
Complete online documentation for MarkLogic Server, XQuery and related components may be found at developer.marklogic.com