Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ArgumentError

Hierarchy

  • TypeError
    • ArgumentError

Index

Constructors

  • Parameters

    • Optional message: string

    Returns ArgumentError

  • Parameters

    • Optional message: string

    Returns ArgumentError

Properties

message: string
name: "ArgumentError" = ArgumentError.NAME
stack?: string
NAME: "ArgumentError" = "ArgumentError"
prepareStackTrace?: ((err: Error, stackTraces: CallSite[]) => any)

Type declaration

stackTraceLimit: number

Methods

  • assert(value: any, name: string, type: "undefined"): asserts value is undefined
  • assert(value: any, name: string, type: "null"): asserts value is null
  • assert(value: any, name: string, type: "boolean"): asserts value is boolean
  • assert(value: any, name: string, type: "number"): asserts value is number
  • assert(value: any, name: string, type: "object"): asserts value is {}
  • assert(value: any, name: string, type: "string"): asserts value is string
  • assert(value: any, name: string, type: "Array"): asserts value is any[]
  • assert(value: any, name: string, type: "ArrayBuffer"): asserts value is ArrayBuffer
  • assert(value: any, name: string, type: "ArrayBufferView"): asserts value is ArrayBufferView
  • assert<T>(value: any, name: string, type: (new (...args: any[]) => T)): asserts value is T
  • assert(value: any, name: string, type: ArgumentType, ...types: ArgumentType[]): void
  • captureStackTrace(targetObject: object, constructorOpt?: Function): void
  • Create .stack property on a target object

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • isType(value: any, type: "undefined"): value is undefined
  • isType(value: any, type: "null"): value is null
  • isType(value: any, type: "boolean"): value is boolean
  • isType(value: any, type: "number"): value is number
  • isType(value: any, type: "object"): value is object
  • isType(value: any, type: "string"): value is string
  • isType(value: any, type: "Array"): value is any[]
  • isType(value: any, type: "ArrayBuffer"): value is ArrayBuffer
  • isType(value: any, type: "ArrayBufferView"): value is ArrayBufferView
  • isType<T>(value: any, type: (new (...args: any[]) => T)): value is T
  • isType(value: any, type: ArgumentType): boolean

Generated using TypeDoc