@SerializeWith(value=SchematicEntryLiteral.Externalizer.class) public class SchematicEntryLiteral extends Object implements SchematicEntry
SchematicEntry
.Modifier and Type | Class and Description |
---|---|
static class |
SchematicEntryLiteral.Externalizer
The
Externalizer for SchematicEntryLiteral instances. |
protected static class |
SchematicEntryLiteral.FieldPath |
SchematicEntry.FieldName
Modifier | Constructor and Description |
---|---|
|
SchematicEntryLiteral() |
protected |
SchematicEntryLiteral(Document metadata,
Document content) |
protected |
SchematicEntryLiteral(MutableDocument document) |
|
SchematicEntryLiteral(String key) |
|
SchematicEntryLiteral(String key,
Document content) |
Modifier and Type | Method and Description |
---|---|
Document |
asDocument()
|
SchematicEntryLiteral |
clone() |
protected MutableDocument |
data() |
protected EditableDocument |
edit(String key,
AdvancedCache<String,SchematicEntry> cache,
AdvancedCache<String,SchematicEntry> lockingCache) |
Document |
getContent()
Return this value's content.
|
protected String |
getKey() |
Document |
getMetadata()
Get the metadata associated with this value.
|
protected String |
key() |
void |
markRemoved(boolean b) |
static SchematicEntry |
newInstance(Cache<String,SchematicEntry> cache,
String key)
Construction only allowed through this factory method.
|
void |
setContent(Document content)
Set the content for this value to be the supplied Document and set the content type to be "
application/json ". |
protected void |
setDocument(Document document) |
protected void |
setMetadata(Document metadata) |
String |
toString() |
protected MutableDocument |
unwrap(Document doc) |
public SchematicEntryLiteral()
public SchematicEntryLiteral(String key)
protected SchematicEntryLiteral(MutableDocument document)
public static SchematicEntry newInstance(Cache<String,SchematicEntry> cache, String key)
cache
- underlying cachekey
- key under which the schematic value existsprotected MutableDocument unwrap(Document doc)
protected final String key()
protected final MutableDocument data()
protected void setDocument(Document document)
public void markRemoved(boolean b)
public Document getMetadata()
SchematicEntry
getMetadata
in interface SchematicEntry
protected String getKey()
public Document getContent()
SchematicEntry
Document
.getContent
in interface SchematicEntry
protected void setMetadata(Document metadata)
public void setContent(Document content)
SchematicEntry
application/json
".setContent
in interface SchematicEntry
content
- the Document representing the JSON content; may not be nullpublic Document asDocument()
SchematicEntry
metadata
and
content
as nested documents.asDocument
in interface SchematicEntry
protected EditableDocument edit(String key, AdvancedCache<String,SchematicEntry> cache, AdvancedCache<String,SchematicEntry> lockingCache)
public SchematicEntryLiteral clone()
Copyright © 2008-2014 JBoss, a division of Red Hat. All Rights Reserved.