public class GsonResultElementFactory extends Object implements ResultElementFactory<com.google.gson.JsonElement>
ResultElement
, based on a given JsonElement
.Modifier and Type | Field and Description |
---|---|
protected com.google.gson.GsonBuilder |
gsonBuilder |
Constructor and Description |
---|
GsonResultElementFactory(com.google.gson.GsonBuilder gsonBuilder) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
canEqual(Object other) |
ResultElement |
create(com.google.gson.JsonElement resultElement)
Creates a
ResultElement based on the given object. |
boolean |
equals(Object o) |
com.google.gson.GsonBuilder |
getGsonBuilder() |
int |
hashCode() |
protected ResultCollection |
newCollection(com.google.gson.JsonElement resultElement) |
protected ResultObject |
newObject(com.google.gson.JsonElement resultElement) |
protected ResultPrimitive |
newPrimitive(com.google.gson.JsonElement resultElement) |
String |
toString() |
public GsonResultElementFactory(com.google.gson.GsonBuilder gsonBuilder)
protected ResultPrimitive newPrimitive(com.google.gson.JsonElement resultElement)
protected ResultObject newObject(com.google.gson.JsonElement resultElement)
protected ResultCollection newCollection(com.google.gson.JsonElement resultElement)
@Nullable public ResultElement create(@Nullable com.google.gson.JsonElement resultElement) throws IllegalArgumentException
ResultElement
based on the given object.create
in interface ResultElementFactory<com.google.gson.JsonElement>
resultElement
- The object to build the ResultElement
from.ResultElement
created from the given object.IllegalArgumentException
- If the given object could not be used to build a ResultElement
.public com.google.gson.GsonBuilder getGsonBuilder()
protected boolean canEqual(Object other)
Copyright © 2020 SAP SE. All rights reserved.