ItemUtils
instead.@Deprecated public enum InternalUtils extends Enum<InternalUtils>
Modifier and Type | Method and Description |
---|---|
static <X extends AmazonWebServiceRequest> |
applyUserAgent(X request)
Deprecated.
Append the custom user-agent string.
|
static void |
checkInvalidAttribute(String attrName,
Object val)
Deprecated.
|
static void |
checkInvalidAttrName(String attrName)
Deprecated.
|
static Map<String,AttributeValue> |
fromSimpleMap(Map<String,Object> map)
Deprecated.
Converts a map of string to simple objects into the low-level
representation; or null if the input is null.
|
static Integer |
minimum(Integer one,
Integer two)
Deprecated.
Returns the minimum of the two input integers taking null into account.
|
static void |
rejectEmptyInput(Object[] input)
Deprecated.
|
static void |
rejectNullInput(Object input)
Deprecated.
|
static void |
rejectNullOrEmptyInput(Object[] input)
Deprecated.
|
static void |
rejectNullValue(Object val)
Deprecated.
|
static Map<String,Condition> |
toAttributeConditionMap(Collection<? extends Filter<?>> filters)
Deprecated.
Returns the low level representation of a collection of
Filter . |
static AttributeValue |
toAttributeValue(Object value)
Deprecated.
Converts a simple value into the low-level
|
static Map<String,AttributeValue> |
toAttributeValueMap(Collection<KeyAttribute> primaryKey)
Deprecated.
Converts the specified primary key into the low-level representation.
|
static Map<String,AttributeValue> |
toAttributeValueMap(KeyAttribute... primaryKey)
Deprecated.
Converts the specified primary key into the low-level representation.
|
static Map<String,AttributeValue> |
toAttributeValueMap(PrimaryKey primaryKey)
Deprecated.
Converts the specified primary key into the low-level representation.
|
static Map<String,AttributeValue> |
toAttributeValues(Item item)
Deprecated.
Converts an
Item into the low-level representation;
or null if the input is null. |
static AttributeValue[] |
toAttributeValues(Object[] values)
Deprecated.
Converts the input array of values into an array of low level
representation of those values.
|
static Map<String,AttributeValueUpdate> |
toAttributeValueUpdate(List<AttributeUpdate> attributesToUpdate)
Deprecated.
Converts a list of
AttributeUpdate into the low-level
representation; or null if the input is null. |
static BigDecimal |
toBigDecimal(Number n)
Deprecated.
Converts a number into BigDecimal representation.
|
static Set<BigDecimal> |
toBigDecimalSet(Number... val)
Deprecated.
|
static Set<BigDecimal> |
toBigDecimalSet(Set<Number> vals)
Deprecated.
|
static Map<String,ExpectedAttributeValue> |
toExpectedAttributeValueMap(Collection<Expected> expectedSet)
Deprecated.
Returns the low level representation of a collection of
Expected . |
static List<Item> |
toItemList(List<Map<String,AttributeValue>> items)
Deprecated.
Returns a non-null list of
Item 's given the low level
list of item information. |
static List<Object> |
toSimpleList(List<AttributeValue> attrValues)
Deprecated.
Converts a list of low-level
AttributeValue into a list of
simple values. |
static <T> List<T> |
toSimpleListValue(List<AttributeValue> values)
Deprecated.
Convenient method to convert a list of low-level
AttributeValue into a list of values of the same type T. |
static <T> Map<String,T> |
toSimpleMapValue(Map<String,AttributeValue> values)
Deprecated.
|
static String |
valToString(Object val)
Deprecated.
Returns the string representation of the given value; or null if the
value is null.
|
static InternalUtils |
valueOf(String name)
Deprecated.
Returns the enum constant of this type with the specified name.
|
static InternalUtils[] |
values()
Deprecated.
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static InternalUtils[] values()
for (InternalUtils c : InternalUtils.values()) System.out.println(c);
public static InternalUtils valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static List<Item> toItemList(List<Map<String,AttributeValue>> items)
Item
's given the low level
list of item information.public static Map<String,AttributeValue> toAttributeValues(Item item)
Item
into the low-level representation;
or null if the input is null.public static Map<String,AttributeValue> fromSimpleMap(Map<String,Object> map)
public static Map<String,AttributeValueUpdate> toAttributeValueUpdate(List<AttributeUpdate> attributesToUpdate)
AttributeUpdate
into the low-level
representation; or null if the input is null.public static AttributeValue toAttributeValue(Object value)
representation.
- Parameters:
value
- the given value which can be one of the followings:
- String
- Set<String>
- Number (including any subtypes and primitive types)
- Set<Number>
- byte[]
- Set<byte[]>
- ByteBuffer
- Set<ByteBuffer>
- Boolean or boolean
- null
- Map<String,T>, where T can be any type on this list but must not
induce any circular reference
- List<T>, where T can be any type on this list but must not induce
any circular reference
- Returns:
- a non-null low level representation of the input object value
- Throws:
UnsupportedOperationException
- if the input object type is not supported
-
toSimpleList
public static List<Object> toSimpleList(List<AttributeValue> attrValues)
Deprecated.
Converts a list of low-level AttributeValue
into a list of
simple values. Each value in the returned list can be one of the
followings:
- String
- Set<String>
- Number (including any subtypes and primitive types)
- Set<Number>
- byte[]
- Set<byte[]>
- ByteBuffer
- Set<ByteBuffer>
- Boolean or boolean
- null
- Map<String,T>, where T can be any type on this list but must not
induce any circular reference
- List<T>, where T can be any type on this list but must not induce
any circular reference
-
toSimpleListValue
public static <T> List<T> toSimpleListValue(List<AttributeValue> values)
Deprecated.
Convenient method to convert a list of low-level
AttributeValue
into a list of values of the same type T.
Each value in the returned list can be one of the followings:
- String
- Set<String>
- Number (including any subtypes and primitive types)
- Set<Number>
- byte[]
- Set<byte[]>
- ByteBuffer
- Set<ByteBuffer>
- Boolean or boolean
- null
- Map<String,T>, where T can be any type on this list but must not
induce any circular reference
- List<T>, where T can be any type on this list but must not induce
any circular reference
-
toSimpleMapValue
public static <T> Map<String,T> toSimpleMapValue(Map<String,AttributeValue> values)
Deprecated.
-
valToString
public static String valToString(Object val)
Deprecated.
Returns the string representation of the given value; or null if the
value is null. For BigDecimal
it will be the string
representation without an exponent field.
-
minimum
public static Integer minimum(Integer one,
Integer two)
Deprecated.
Returns the minimum of the two input integers taking null into account.
Returns null if both integers are null. Otherwise, a null Integer is
treated as infinity.
-
toExpectedAttributeValueMap
public static Map<String,ExpectedAttributeValue> toExpectedAttributeValueMap(Collection<Expected> expectedSet)
Deprecated.
Returns the low level representation of a collection of Expected
.
-
toAttributeConditionMap
public static Map<String,Condition> toAttributeConditionMap(Collection<? extends Filter<?>> filters)
Deprecated.
Returns the low level representation of a collection of Filter
.
-
toAttributeValues
public static AttributeValue[] toAttributeValues(Object[] values)
Deprecated.
Converts the input array of values into an array of low level
representation of those values.
A value in the input array can be one of the followings:
- String
- Set<String>
- Number (including any subtypes and primitive types)
- Set<Number>
- byte[]
- Set<byte[]>
- ByteBuffer
- Set<ByteBuffer>
- Boolean or boolean
- null
- Map<String,T>, where T can be any type on this list but must not
induce any circular reference
- List<T>, where T can be any type on this list but must not induce
any circular reference
-
toAttributeValueMap
public static Map<String,AttributeValue> toAttributeValueMap(Collection<KeyAttribute> primaryKey)
Deprecated.
Converts the specified primary key into the low-level representation.
-
toAttributeValueMap
public static Map<String,AttributeValue> toAttributeValueMap(PrimaryKey primaryKey)
Deprecated.
Converts the specified primary key into the low-level representation.
-
toAttributeValueMap
public static Map<String,AttributeValue> toAttributeValueMap(KeyAttribute... primaryKey)
Deprecated.
Converts the specified primary key into the low-level representation.
-
toBigDecimal
public static BigDecimal toBigDecimal(Number n)
Deprecated.
Converts a number into BigDecimal representation.
-
toBigDecimalSet
public static Set<BigDecimal> toBigDecimalSet(Number... val)
Deprecated.
-
toBigDecimalSet
public static Set<BigDecimal> toBigDecimalSet(Set<Number> vals)
Deprecated.
-
applyUserAgent
public static <X extends AmazonWebServiceRequest> X applyUserAgent(X request)
Deprecated.
Append the custom user-agent string.
Note to maintainers, this is technically not deprecated and not present in ItemUtils
. It is truly meant for
internal use only.
-
rejectNullValue
public static void rejectNullValue(Object val)
Deprecated.
-
rejectNullInput
public static void rejectNullInput(Object input)
Deprecated.
-
rejectEmptyInput
public static void rejectEmptyInput(Object[] input)
Deprecated.
-
rejectNullOrEmptyInput
public static void rejectNullOrEmptyInput(Object[] input)
Deprecated.
-
checkInvalidAttrName
public static void checkInvalidAttrName(String attrName)
Deprecated.
Copyright © 2023. All rights reserved.