Class OnmsError

Represents an OpenNMS.js error.

Hierarchy (view full)

Constructors

  • Create a new error.

    Parameters

    • message: string

      The error message.

    • Optional code: number

      An optional error code to associate with the error.

    • Optional options: any
    • Optional data: any

    Returns OnmsError

Properties

data: any

The data (payload) associated with a response.

message: string
name: string
options: any

The options provided as part of the request that resulted in this erro.

stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Accessors

Methods

  • Create .stack property on a target object

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void