gremlin
    Preparing search index...

    A Client contains methods to send messages to a Gremlin Server.

    Index

    Constructors

    Properties

    options: ClientOptions = {}
    url: string

    Accessors

    Methods

    • Adds an event listener to the connection

      Parameters

      • event: string

        The event name that you want to listen to.

      • handler: (...args: any[]) => unknown

        The callback to be called when the event occurs.

      Returns void

    • Removes a previously added event listener to the connection

      Parameters

      • event: string

        The event name that you want to listen to.

      • handler: (...args: any[]) => unknown

        The event handler to be removed.

      Returns void

    • Send a request to the Gremlin Server and stream results incrementally. Returns an AsyncGenerator that yields individual result items as they are deserialized from the response. For bulked responses, yields Traverser objects.

      Parameters

      • message: string

        The script to send

      • Optionalparameters: any

        The query parameters, if any.

      • OptionalrequestOptions: RequestOptions

        Configuration specific to the current request.

      Returns AsyncGenerator<any>

    • Send a request to the Gremlin Server and buffer the entire response.

      Parameters

      • message: string

        The script to send

      • Optionalparameters: any

        The query parameters, if any.

      • OptionalrequestOptions: RequestOptions

        Configuration specific to the current request.

      Returns Promise<any>

    • Creates a new Transaction for executing operations within an explicit transaction. Transactions are short-lived and single-use. After commit or rollback, create a new Transaction for the next unit of work. The traversal source (g alias) is inherited from this Client.

      Returns Transaction