Class BSONVersionError

Hierarchy (view full)

Constructors

Properties

cause?: unknown
message: string
stack?: string
prepareStackTrace?: ((err: Error, stackTraces: CallSite[]) => any)

Optional override for formatting stack traces

stackTraceLimit: number

Accessors

  • get name(): "BSONVersionError"
  • Returns "BSONVersionError"

Methods

  • Create .stack property on a target object

    Parameters

    • targetObject: object
    • OptionalconstructorOpt: Function

    Returns void

  • All errors thrown from the BSON library inherit from BSONError. This method can assist with determining if an error originates from the BSON library even if it does not pass an instanceof check against this class' constructor.

    Parameters

    • value: unknown

      any javascript value that needs type checking

    Returns value is BSONError