public static class LinkedAttributePathToken.ObjectAttributeToken extends LinkedAttributePathToken<com.google.gson.JsonObject>
LinkedAttributePathToken.ArrayAttributeToken, LinkedAttributePathToken.ObjectAttributeTokenchildToken, parentJson| Constructor and Description |
|---|
ObjectAttributeToken(String key) |
| Modifier and Type | Method and Description |
|---|---|
protected com.google.gson.JsonElement |
getChildElement() |
com.google.gson.JsonObject |
getJsonType() |
String |
getKey() |
com.google.gson.JsonElement |
getOrCreateChildElement()
This method will return the child element, if the
LinkedAttributePathToken.parentJson
contains a child that
is valid for this token. |
String |
toString() |
protected void |
writeChildElement()
Write the
JsonElement the corresponds to LinkedAttributePathToken.childToken into
LinkedAttributePathToken.parentJson. |
protected void |
writeValue(com.google.gson.Gson gson,
Object value)
Write
value into LinkedAttributePathToken.parentJson. |
hasNext, jsonCompatible, next, setAndCreateParentElement, writeChildclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitforEachRemaining, removepublic ObjectAttributeToken(String key)
public String getKey()
key this token maps it's
getChildElement() to.public com.google.gson.JsonObject getJsonType()
getJsonType in class LinkedAttributePathToken<com.google.gson.JsonObject>Tpublic com.google.gson.JsonElement getOrCreateChildElement()
LinkedAttributePathTokenLinkedAttributePathToken.parentJson
contains a child that
is valid for this token. If the LinkedAttributePathToken.parentJson does not have a
child, this method will
create it. If the LinkedAttributePathToken.parentJson does have a child, but it is not
LinkedAttributePathToken.jsonCompatible(JsonElement)
with our LinkedAttributePathToken.childToken, then this method will also create a new
(compatible) child, and replace
the existing incompatible child.getOrCreateChildElement in class LinkedAttributePathToken<com.google.gson.JsonObject>protected com.google.gson.JsonElement getChildElement()
getChildElement in class LinkedAttributePathToken<com.google.gson.JsonObject>LinkedAttributePathToken.childToken if
present.protected void writeValue(com.google.gson.Gson gson, Object value)
LinkedAttributePathTokenvalue into LinkedAttributePathToken.parentJson.
LinkedAttributePathToken.childToken is null (i.e. this is the
last token in the attribute path).writeValue in class LinkedAttributePathToken<com.google.gson.JsonObject>gson - instance used to serialize valuevalue - to serializeprotected void writeChildElement()
LinkedAttributePathTokenJsonElement the corresponds to LinkedAttributePathToken.childToken into
LinkedAttributePathToken.parentJson.writeChildElement in class LinkedAttributePathToken<com.google.gson.JsonObject>Copyright © 2017–2026 Saalfeld Lab. All rights reserved.