Class Code

A class representation of the BSON Code type.

Hierarchy (view full)

Constructors

Properties

Accessors

Methods

Constructors

  • Parameters

    • code: string | Function

      a string or function.

    • Optionalscope: null | Document

      an optional scope for the function.

    Returns Code

Properties

code: string
scope: null | Document

Accessors

  • get _bsontype(): "Code"
  • Returns "Code"

Methods

  • Prints a human-readable string of BSON value information If invoked manually without node.js.inspect function, this will default to a modified JSON.stringify

    Parameters

    • Optionaldepth: number
    • Optionaloptions: unknown
    • Optionalinspect: InspectFn

    Returns string

  • Returns {
        code: string;
        scope?: Document;
    }