Class Id
java.lang.Object
com.surrealdb.Native
com.surrealdb.Id
The Id class represents a unique identifier that can be either a long value
or a string.
-
Method Summary
Modifier and TypeMethodDescriptionstatic Idfrom(long id) static IdCreates an Id whose key is an array of Java values (composite key).static Idstatic Idstatic IdList-based counterpart tofrom(java.lang.Object...).final ArraygetArray()final longgetLong()final Objectfinal Stringfinal UUIDgetUuid()final booleanisArray()final booleanisLong()final booleanisObject()final booleanisString()final booleanisUuid()
-
Method Details
-
from
-
from
-
from
-
from
Creates an Id whose key is an array of Java values (composite key). SeeArray.of(java.lang.Object...)for the supported element types.To build a single-element
[null]key, cast the argument:Id.from((java.lang.Object) null). A bareId.from(null)is a null varargs array and will throwNullPointerException. -
fromList
List-based counterpart tofrom(java.lang.Object...). Named distinctly fromfrom(...)to avoid a null-call overload ambiguity. -
isLong
public final boolean isLong() -
getLong
public final long getLong() -
isString
public final boolean isString() -
getString
-
isUuid
public final boolean isUuid() -
getUuid
-
isArray
public final boolean isArray() -
getArray
-
isObject
public final boolean isObject() -
getObject
-