Interface PqMap.Entry
- Enclosing interface:
PqMap
public static interface PqMap.Entry
A single key-value entry in a map.
-
Method Summary
Modifier and TypeMethodDescriptionbyte[]Get the key as a BINARY.byte[]Get the value as a BINARY.booleanGet the value as a BOOLEAN.Get the key as a DATE.Get the value as a DATE.Get the value as a DECIMAL.doubleGet the value as a DOUBLE.floatGet the value as a FLOAT.intGet the key as an INT32.intGet the value as an INT32.getKey()Get the key without type conversion.Get the value as a LIST.longGet the key as an INT64.longGet the value as an INT64.Get the value as a MAP.Get the key as a STRING.Get the value as a STRING.Get the value as a nested struct.Get the key as a TIMESTAMP.Get the value as a TIMESTAMP.Get the value as a TIME.Get the key as a UUID.Get the value as a UUID.getValue()Get the value without type conversion.booleanCheck if the value is null.
-
Method Details
-
getIntKey
int getIntKey()Get the key as an INT32.- Returns:
- the int key value
- Throws:
IllegalArgumentException- if the key type is not INT32
-
getLongKey
long getLongKey()Get the key as an INT64.- Returns:
- the long key value
- Throws:
IllegalArgumentException- if the key type is not INT64
-
getStringKey
String getStringKey()Get the key as a STRING.- Returns:
- the string key value
- Throws:
IllegalArgumentException- if the key type is not STRING
-
getBinaryKey
byte[] getBinaryKey()Get the key as a BINARY.- Returns:
- the byte array key value
- Throws:
IllegalArgumentException- if the key type is not BINARY
-
getDateKey
LocalDate getDateKey()Get the key as a DATE.- Returns:
- the date key value
- Throws:
IllegalArgumentException- if the key type is not DATE
-
getTimestampKey
Instant getTimestampKey()Get the key as a TIMESTAMP.- Returns:
- the instant key value
- Throws:
IllegalArgumentException- if the key type is not TIMESTAMP
-
getUuidKey
UUID getUuidKey()Get the key as a UUID.- Returns:
- the UUID key value
- Throws:
IllegalArgumentException- if the key type is not UUID
-
getKey
-
getIntValue
int getIntValue()Get the value as an INT32.- Returns:
- the int value
- Throws:
NullPointerException- if the value is nullIllegalArgumentException- if the value type is not INT32
-
getLongValue
long getLongValue()Get the value as an INT64.- Returns:
- the long value
- Throws:
NullPointerException- if the value is nullIllegalArgumentException- if the value type is not INT64
-
getFloatValue
float getFloatValue()Get the value as a FLOAT.- Returns:
- the float value
- Throws:
NullPointerException- if the value is nullIllegalArgumentException- if the value type is not FLOAT
-
getDoubleValue
double getDoubleValue()Get the value as a DOUBLE.- Returns:
- the double value
- Throws:
NullPointerException- if the value is nullIllegalArgumentException- if the value type is not DOUBLE
-
getBooleanValue
boolean getBooleanValue()Get the value as a BOOLEAN.- Returns:
- the boolean value
- Throws:
NullPointerException- if the value is nullIllegalArgumentException- if the value type is not BOOLEAN
-
getStringValue
String getStringValue()Get the value as a STRING.- Returns:
- the string value, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not STRING
-
getBinaryValue
byte[] getBinaryValue()Get the value as a BINARY.- Returns:
- the byte array value, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not BINARY
-
getDateValue
LocalDate getDateValue()Get the value as a DATE.- Returns:
- the date value, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not DATE
-
getTimeValue
LocalTime getTimeValue()Get the value as a TIME.- Returns:
- the time value, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not TIME
-
getTimestampValue
Instant getTimestampValue()Get the value as a TIMESTAMP.- Returns:
- the instant value, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not TIMESTAMP
-
getDecimalValue
BigDecimal getDecimalValue()Get the value as a DECIMAL.- Returns:
- the decimal value, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not DECIMAL
-
getUuidValue
UUID getUuidValue()Get the value as a UUID.- Returns:
- the UUID value, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not UUID
-
getStructValue
PqStruct getStructValue()Get the value as a nested struct.- Returns:
- the nested struct, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not a struct
-
getListValue
PqList getListValue()Get the value as a LIST.- Returns:
- the list value, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not a list
-
getMapValue
PqMap getMapValue()Get the value as a MAP.- Returns:
- the nested map, or null if the value is null
- Throws:
IllegalArgumentException- if the value type is not a map
-
getValue
Object getValue()Get the value without type conversion.- Returns:
- the raw value, or null if the value is null
-
isValueNull
boolean isValueNull()Check if the value is null.- Returns:
- true if the value is null
-