public abstract class JsonObjectArrayBase extends Object
| Modifier and Type | Field and Description |
|---|---|
protected org.slf4j.Logger |
logger |
| Constructor and Description |
|---|
JsonObjectArrayBase(IJsonManager jsonManager,
ISpincastUtils spincastUtils)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
BigDecimal |
getBigDecimal(String key) |
BigDecimal |
getBigDecimal(String key,
BigDecimal defaultValue) |
protected BigDecimal |
getBigDecimalValue(String key,
boolean hasDefaultValue,
BigDecimal defaultValue) |
Boolean |
getBoolean(String key) |
Boolean |
getBoolean(String key,
Boolean defaultValue) |
protected Boolean |
getBooleanValue(String key,
boolean hasDefaultValue,
Boolean defaultValue) |
byte[] |
getBytesFromBase64String(String key) |
byte[] |
getBytesFromBase64String(String key,
byte[] defaultValue) |
protected byte[] |
getBytesFromBase64StringValue(String key,
boolean hasDefaultValue,
byte[] defaultValue) |
Date |
getDate(String key) |
Date |
getDate(String key,
Date defaultValue) |
protected Date |
getDateValue(String key,
boolean hasDefaultValue,
Date defaultValue) |
Double |
getDouble(String key) |
Double |
getDouble(String key,
Double defaultValue) |
protected Double |
getDoubleValue(String key,
boolean hasDefaultValue,
Double defaultValue) |
protected abstract Object |
getElement(String keyPosition,
boolean hasDefaultValue,
Object defaultValue)
Gets the element at this key/position.
|
Float |
getFloat(String key) |
Float |
getFloat(String key,
Float defaultValue) |
protected Float |
getFloatValue(String key,
boolean hasDefaultValue,
Float defaultValue) |
Integer |
getInteger(String key) |
Integer |
getInteger(String key,
Integer defaultValue) |
protected Integer |
getIntegerValue(String key,
boolean hasDefaultValue,
Integer defaultValue) |
IJsonArray |
getJsonArray(String key) |
IJsonArray |
getJsonArray(String key,
IJsonArray defaultValue) |
IJsonArray |
getJsonArrayOrEmpty(String key) |
protected IJsonArray |
getJsonArrayValue(String key,
boolean hasDefaultValue,
IJsonArray defaultValue) |
protected IJsonManager |
getJsonManager() |
IJsonObject |
getJsonObject(String key) |
IJsonObject |
getJsonObject(String key,
IJsonObject defaultValue) |
IJsonObject |
getJsonObjectOrEmpty(String key) |
protected IJsonObject |
getJSONObjectValue(String key,
boolean hasDefaultValue,
IJsonObject defaultValue) |
Long |
getLong(String key) |
Long |
getLong(String key,
Long defaultValue) |
protected Long |
getLongValue(String key,
boolean hasDefaultValue,
Long defaultValue) |
protected ISpincastUtils |
getSpincastUtils() |
String |
getString(String key) |
String |
getString(String key,
String defaultValue) |
protected String |
getStringValue(String key,
boolean hasDefaultValue,
String defaultValue) |
protected Date |
parseDate(String str) |
String |
toJsonString() |
String |
toJsonString(boolean pretty) |
String |
toString() |
public JsonObjectArrayBase(IJsonManager jsonManager, ISpincastUtils spincastUtils)
protected IJsonManager getJsonManager()
protected ISpincastUtils getSpincastUtils()
public IJsonObject getJsonObject(String key) throws CantConvertException
CantConvertExceptionpublic IJsonObject getJsonObjectOrEmpty(String key)
public IJsonObject getJsonObject(String key, IJsonObject defaultValue)
protected IJsonObject getJSONObjectValue(String key, boolean hasDefaultValue, IJsonObject defaultValue)
public IJsonArray getJsonArray(String key) throws CantConvertException
CantConvertExceptionpublic IJsonArray getJsonArrayOrEmpty(String key)
public IJsonArray getJsonArray(String key, IJsonArray defaultValue)
protected IJsonArray getJsonArrayValue(String key, boolean hasDefaultValue, IJsonArray defaultValue)
public String getString(String key) throws CantConvertException
CantConvertExceptionprotected String getStringValue(String key, boolean hasDefaultValue, String defaultValue)
public Integer getInteger(String key) throws CantConvertException
CantConvertExceptionprotected Integer getIntegerValue(String key, boolean hasDefaultValue, Integer defaultValue)
public Long getLong(String key) throws CantConvertException
CantConvertExceptionpublic Float getFloat(String key) throws CantConvertException
CantConvertExceptionprotected Float getFloatValue(String key, boolean hasDefaultValue, Float defaultValue)
public Double getDouble(String key) throws CantConvertException
CantConvertExceptionprotected Double getDoubleValue(String key, boolean hasDefaultValue, Double defaultValue)
public Boolean getBoolean(String key) throws CantConvertException
CantConvertExceptionprotected Boolean getBooleanValue(String key, boolean hasDefaultValue, Boolean defaultValue)
public BigDecimal getBigDecimal(String key) throws CantConvertException
CantConvertExceptionpublic BigDecimal getBigDecimal(String key, BigDecimal defaultValue)
protected BigDecimal getBigDecimalValue(String key, boolean hasDefaultValue, BigDecimal defaultValue)
public byte[] getBytesFromBase64String(String key) throws CantConvertException
CantConvertExceptionpublic byte[] getBytesFromBase64String(String key, byte[] defaultValue)
protected byte[] getBytesFromBase64StringValue(String key, boolean hasDefaultValue, byte[] defaultValue)
public Date getDate(String key) throws CantConvertException
CantConvertExceptionpublic String toJsonString()
public String toJsonString(boolean pretty)
Copyright © 2016. All rights reserved.