GlobalID

GlobalIDs are objects in Viaduct that contain 'type' and 'internalID' properties. They are used to uniquely identify node objects in the graph.

Framework-created GlobalID values compare structurally by type and internal ID. Type identity includes the GraphQL name and Java Class, so a serialized ID round trip requires the same GRT class.

A GlobalID will be generated for fields with the @idOf(type:"T") directive.

Instances of GlobalID can be created using execution-context objects, e.g., ExecutionContext.nodeIDFor(User.class, "123").

Parameters

<T>

The type of NodeCompositeOutput this GlobalID refers to

Functions

Link copied to clipboard
abstract fun getInternalID(): String
Returns the internal ID of the node object, e.g.
Link copied to clipboard
abstract fun getType(): Type<T>
Returns the type of the node object, e.g.