Skip to main content

Class: InvalidShardIdError

The error class for invalid shard ID. This error is thrown when the provided shard ID is invalid.

Extends​

  • BaseError

Constructors​

new InvalidShardIdError()​

new InvalidShardIdError(param0): InvalidShardIdError

Creates an instance of InvalidShardIdError.

Parameters​

ParameterTypeDescription

param0

InvalidShardIdErrorParameters

The error params.

Returns​

InvalidShardIdError

Overrides​

BaseError.constructor

Defined in​

nil/nil.js/src/errors/shardId.ts:23

Properties​

cause?​

optional cause: BaseError | Error;

The error cause.

Inherited from​

BaseError.cause

Defined in​

nil/nil.js/src/errors/BaseError.ts:40


docsPath?​

optional docsPath: string;

The path to the documentation of this error.

Inherited from​

BaseError.docsPath

Defined in​

nil/nil.js/src/errors/BaseError.ts:47


isOperational​

isOperational: boolean;

The flag that indicates if this error is operational. This is useful to differentiate operational errors from programming errors. It is recommended to always set this property to true when creating a custom error class.

Inherited from​

BaseError.isOperational

Defined in​

nil/nil.js/src/errors/BaseError.ts:33


message​

message: string;

Inherited from​

BaseError.message

Defined in​

node_modules/typescript/lib/lib.es5.d.ts:1077


name​

name: string;

Inherited from​

BaseError.name

Defined in​

node_modules/typescript/lib/lib.es5.d.ts:1076


stack?​

optional stack: string;

Inherited from​

BaseError.stack

Defined in​

node_modules/typescript/lib/lib.es5.d.ts:1078


prepareStackTrace()?​

static optional prepareStackTrace: (err, stackTraces) => any;

Optional override for formatting stack traces

See​

https://v8.dev/docs/stack-trace-api#customizing-stack-traces

Parameters​

ParameterType

err

Error

stackTraces

CallSite[]

Returns​

any

Inherited from​

BaseError.prepareStackTrace

Defined in​

node_modules/@types/node/globals.d.ts:28


stackTraceLimit​

static stackTraceLimit: number;

Inherited from​

BaseError.stackTraceLimit

Defined in​

node_modules/@types/node/globals.d.ts:30

Methods​

captureStackTrace()​

static captureStackTrace(targetObject, constructorOpt?): void

Create .stack property on a target object

Parameters​

ParameterType

targetObject

object

constructorOpt?

Function

Returns​

void

Inherited from​

BaseError.captureStackTrace

Defined in​

node_modules/@types/node/globals.d.ts:21