Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Analyzer

Represents an Analyzer in a Database.

Hierarchy

  • Analyzer

Index

Accessors

isArangoAnalyzer

  • get isArangoAnalyzer(): true
  • internal

    Indicates that this object represents an ArangoDB Analyzer.

    Returns true

name

  • get name(): string

Methods

create

  • Creates a new Analyzer with the given options and the instance's name.

    See also Database.createAnalyzer.

    example
    const db = new Database();
    const analyzer = db.analyzer("potatoes");
    await analyzer.create({ type: "identity" });
    // the identity Analyzer "potatoes" now exists

    Parameters

    Returns Promise<AnalyzerDescription>

drop

  • Deletes the Analyzer from the database.

    example
    const db = new Database();
    const analyzer = db.analyzer("some-analyzer");
    await analyzer.drop();
    // the Analyzer "some-analyzer" no longer exists

    Parameters

    • Default value force: boolean = false

      Whether the Analyzer should still be deleted even if it is currently in use.

    Returns Promise<ArangoResponseMetadata & { name: string }>

exists

  • exists(): Promise<boolean>
  • Checks whether the Analyzer exists.

    example
    const db = new Database();
    const analyzer = db.analyzer("some-analyzer");
    const result = await analyzer.exists();
    // result indicates whether the Analyzer exists

    Returns Promise<boolean>

get

  • Retrieves the Analyzer definition for the Analyzer.

    example
    const db = new Database();
    const analyzer = db.analyzer("some-analyzer");
    const definition = await analyzer.get();
    // definition contains the Analyzer definition

    Returns Promise<ArangoResponseMetadata & AnalyzerDescription>

Generated using TypeDoc