NebulaGraph Java Client 5.0.0
|
Public Member Functions | |
ValueWrapper (Object value, ColumnType type) | |
ColumnType | getDataType () |
String | getDataTypeString () |
Object | getValue () |
get the Object value | |
boolean | isNull () |
if the value is null | |
boolean | isBoolean () |
check if the Value is Boolean type | |
boolean | isLong () |
check if the Value is Long type | |
boolean | isInt () |
check if the Value is Int type | |
boolean | isFloat () |
check if the Value is Float type | |
boolean | isDouble () |
check if the Value is Double type | |
boolean | isString () |
check if the Value is String type | |
boolean | isList () |
check if the Value is List type | |
boolean | isNode () |
check if the Value is Node type | |
boolean | isEdge () |
check if the Value is Edge type | |
boolean | isLocalTime () |
check if the Value is Local Time type | |
boolean | isZonedTime () |
check if the Value is Zoned Time type | |
boolean | isLocalDateTime () |
check if the Value is Local Datetime type | |
boolean | isZonedDateTime () |
check if the Value is Zoned Datetime type | |
boolean | isDate () |
check if the Value is Date type | |
boolean | isRecord () |
check if the Value is Record type | |
boolean | isDuration () |
check if the Value is Duration type | |
boolean | isPath () |
check if the Value is Path type | |
boolean | isDecimal () |
check if the Value is Decimal type | |
boolean | asBoolean () throws InvalidValueException |
Convert the original Value to boolean. | |
int | asInt () throws InvalidValueException |
Convert the original int8/uint8/int16/uint16/int32/uint32 Value to int. | |
long | asLong () throws InvalidValueException |
Convert the original int64/uint64 Value to long. | |
String | asString () throws InvalidValueException |
Convert the original data type Value to String. | |
float | asFloat () throws InvalidValueException |
Convert the original Value to float. | |
double | asDouble () throws InvalidValueException |
Convert the original Value to double. | |
List< ValueWrapper > | asList () throws InvalidValueException |
Convert the original Value to list. | |
Node | asNode () throws InvalidValueException |
Convert the original Value to Node. | |
Edge | asEdge () throws InvalidValueException |
Convert the original data Value to Edge. | |
LocalTime | asLocalTime () throws InvalidValueException |
Convert the original data Value to LocalTime. | |
OffsetTime | asZonedTime () throws InvalidValueException |
Convert the original data type Value to OffsetTime. | |
LocalDate | asDate () throws InvalidValueException |
Convert the original data type Value to LocalDate. | |
LocalDateTime | asLocalDateTime () throws InvalidValueException |
Convert the original data Value to LocalDateTime. | |
ZonedDateTime | asZonedDateTime () throws InvalidValueException |
Convert the original data Value to ZonedDateTime. | |
NDuration | asDuration () throws InvalidValueException |
Convert the original data type Value to NDuration. | |
NRecord | asRecord () throws InvalidValueException |
Convert the original data type Value to NRecord. | |
Path | asPath () throws InvalidValueException |
Convert the original data type Value to Path. | |
BigDecimal | asDecimal () throws InvalidValueException |
Convert the original data type Value to BigDecimal. | |
EmbeddingVector | asVector () throws InvalidValueException |
Convert the original data type Value to Vector. | |
boolean | equals (Object o) |
int | hashCode () |
String | toString () |
Convert Value to String format. | |
Definition at line 42 of file ValueWrapper.java.
ValueWrapper | ( | Object | value, |
ColumnType | type | ||
) |
Definition at line 54 of file ValueWrapper.java.
boolean asBoolean | ( | ) | throws InvalidValueException |
Convert the original Value to boolean.
InvalidValueException | if the value type is not bool |
Definition at line 311 of file ValueWrapper.java.
LocalDate asDate | ( | ) | throws InvalidValueException |
Convert the original data type Value to LocalDate.
LocalDate
value InvalidValueException | if the value type is not date |
Definition at line 483 of file ValueWrapper.java.
BigDecimal asDecimal | ( | ) | throws InvalidValueException |
Convert the original data type Value to BigDecimal.
BigDecimal
InvalidValueException | if the value type is not decimal |
Definition at line 567 of file ValueWrapper.java.
double asDouble | ( | ) | throws InvalidValueException |
Convert the original Value to double.
InvalidValueException | if the value type is not double |
Definition at line 397 of file ValueWrapper.java.
NDuration asDuration | ( | ) | throws InvalidValueException |
Convert the original data type Value to NDuration.
NDuration
InvalidValueException | if the value type is not duration |
Definition at line 525 of file ValueWrapper.java.
Edge asEdge | ( | ) | throws InvalidValueException |
Convert the original data Value to Edge.
InvalidValueException | if the value type is not edge |
Definition at line 439 of file ValueWrapper.java.
float asFloat | ( | ) | throws InvalidValueException |
Convert the original Value to float.
InvalidValueException | if the value type is not float |
Definition at line 383 of file ValueWrapper.java.
int asInt | ( | ) | throws InvalidValueException |
Convert the original int8/uint8/int16/uint16/int32/uint32 Value to int.
if the value in NebulaGraph is uint32 type and is negative, you can convert it to Long:
Integer.toUnsignedLong((int)value)
InvalidValueException | if the value type is not int |
Definition at line 330 of file ValueWrapper.java.
List< ValueWrapper > asList | ( | ) | throws InvalidValueException |
Convert the original Value to list.
InvalidValueException | if the value type is not list |
Definition at line 411 of file ValueWrapper.java.
LocalDateTime asLocalDateTime | ( | ) | throws InvalidValueException |
Convert the original data Value to LocalDateTime.
LocalDateTime
InvalidValueException | if the value type is not Local Datetime |
Definition at line 497 of file ValueWrapper.java.
LocalTime asLocalTime | ( | ) | throws InvalidValueException |
Convert the original data Value to LocalTime.
LocalTime
value InvalidValueException | if the value type is not localtime |
Definition at line 453 of file ValueWrapper.java.
long asLong | ( | ) | throws InvalidValueException |
Convert the original int64/uint64 Value to long.
if the value in NebulaGraph is uint64 and is negative, you can convert it to BigInteger:
if (value >= 0) { return BigInteger.valueOf(value); } else { return BigInteger.valueOf((long)value & Long.MAX_VALUE).setBit(63); }
InvalidValueException | if the value type is not int64 or uint64 |
Definition at line 354 of file ValueWrapper.java.
Node asNode | ( | ) | throws InvalidValueException |
Convert the original Value to Node.
InvalidValueException | if the value type is not node |
Definition at line 425 of file ValueWrapper.java.
Path asPath | ( | ) | throws InvalidValueException |
Convert the original data type Value to Path.
Path
InvalidValueException | if the value type is not Path |
Definition at line 553 of file ValueWrapper.java.
NRecord asRecord | ( | ) | throws InvalidValueException |
Convert the original data type Value to NRecord.
NRecord
InvalidValueException | if the value type is not Record |
Definition at line 539 of file ValueWrapper.java.
String asString | ( | ) | throws InvalidValueException |
Convert the original data type Value to String.
InvalidValueException | if the value type is not string |
Definition at line 369 of file ValueWrapper.java.
EmbeddingVector asVector | ( | ) | throws InvalidValueException |
Convert the original data type Value to Vector.
Vector
InvalidValueException | if the value type is not Vector |
Definition at line 581 of file ValueWrapper.java.
ZonedDateTime asZonedDateTime | ( | ) | throws InvalidValueException |
Convert the original data Value to ZonedDateTime.
ZonedDateTime
InvalidValueException | if the value type is not Zoned Datetime |
Definition at line 511 of file ValueWrapper.java.
OffsetTime asZonedTime | ( | ) | throws InvalidValueException |
Convert the original data type Value to OffsetTime.
OffsetTime
time with zone information InvalidValueException | if the value type is not Zoned time |
Definition at line 468 of file ValueWrapper.java.
boolean equals | ( | Object | o | ) |
Definition at line 590 of file ValueWrapper.java.
ColumnType getDataType | ( | ) |
Definition at line 59 of file ValueWrapper.java.
String getDataTypeString | ( | ) |
Definition at line 63 of file ValueWrapper.java.
Object getValue | ( | ) |
int hashCode | ( | ) |
Definition at line 602 of file ValueWrapper.java.
boolean isBoolean | ( | ) |
check if the Value is Boolean type
Definition at line 144 of file ValueWrapper.java.
boolean isDate | ( | ) |
check if the Value is Date type
Definition at line 265 of file ValueWrapper.java.
boolean isDecimal | ( | ) |
check if the Value is Decimal type
Definition at line 301 of file ValueWrapper.java.
boolean isDouble | ( | ) |
check if the Value is Double type
Definition at line 184 of file ValueWrapper.java.
boolean isDuration | ( | ) |
check if the Value is Duration type
Definition at line 283 of file ValueWrapper.java.
boolean isEdge | ( | ) |
check if the Value is Edge type
Definition at line 220 of file ValueWrapper.java.
boolean isFloat | ( | ) |
check if the Value is Float type
Definition at line 174 of file ValueWrapper.java.
boolean isInt | ( | ) |
check if the Value is Int type
Definition at line 163 of file ValueWrapper.java.
boolean isList | ( | ) |
check if the Value is List type
Definition at line 202 of file ValueWrapper.java.
boolean isLocalDateTime | ( | ) |
check if the Value is Local Datetime type
Definition at line 247 of file ValueWrapper.java.
boolean isLocalTime | ( | ) |
check if the Value is Local Time type
Definition at line 229 of file ValueWrapper.java.
boolean isLong | ( | ) |
check if the Value is Long type
Definition at line 153 of file ValueWrapper.java.
boolean isNode | ( | ) |
check if the Value is Node type
Definition at line 211 of file ValueWrapper.java.
boolean isNull | ( | ) |
if the value is null
Definition at line 135 of file ValueWrapper.java.
boolean isPath | ( | ) |
check if the Value is Path type
Definition at line 292 of file ValueWrapper.java.
boolean isRecord | ( | ) |
check if the Value is Record type
Definition at line 274 of file ValueWrapper.java.
boolean isString | ( | ) |
check if the Value is String type
Definition at line 193 of file ValueWrapper.java.
boolean isZonedDateTime | ( | ) |
check if the Value is Zoned Datetime type
Definition at line 256 of file ValueWrapper.java.
boolean isZonedTime | ( | ) |
check if the Value is Zoned Time type
Definition at line 238 of file ValueWrapper.java.
String toString | ( | ) |
Convert Value to String format.
Definition at line 612 of file ValueWrapper.java.