gremlin
    Preparing search index...

    Represents a traversal as a result of a RemoteConnection submission.

    Hierarchy (View Summary)

    Indexable

    Index

    Constructors

    Properties

    _resultsStream: AsyncGenerator<any, any, any> | null = null

    Async results stream set by RemoteStrategy

    graph: Graph | null
    gremlinLang: default = ...
    sideEffects?: any = null
    traversalStrategies: TraversalStrategies | null

    Methods

    • Gets the trailing response status from the server. Available after the traversal has been fully iterated (via toList(), iterate(), or manual iteration). Returns null if the traversal has not completed.

      Returns { code: number; exception: string | null; message: string | null } | null

    • Returns the next result from the traversal.

      When called without an argument, returns a Promise that resolves to an iterator item ({value, done}), following the async iterator protocol.

      When called with an amount, returns a Promise that resolves to an Array containing up to {@code amount} result values. The Array form is always used when an amount is supplied, including {@code next(1)}, which resolves to an Array of one value rather than a bare value, matching the behavior of next(n) in the other Gremlin language variants. If fewer results remain, the Array contains only those that remain, and an amount of zero or less yields an empty Array.

      Type Parameters

      • T

      Returns Promise<IteratorResult<T, null>>

    • Returns the next result from the traversal.

      When called without an argument, returns a Promise that resolves to an iterator item ({value, done}), following the async iterator protocol.

      When called with an amount, returns a Promise that resolves to an Array containing up to {@code amount} result values. The Array form is always used when an amount is supplied, including {@code next(1)}, which resolves to an Array of one value rather than a bare value, matching the behavior of next(n) in the other Gremlin language variants. If fewer results remain, the Array contains only those that remain, and an amount of zero or less yields an empty Array.

      Type Parameters

      • T

      Parameters

      • amount: number

        The number of results to retrieve.

      Returns Promise<T[]>