Class: CCEverywhereError<T>
Extends
Error
Type Parameters
Type Parameter
TConstructors
Constructor
new CCEverywhereError<T>(
code,
message?,
subError?,
customData?): CCEverywhereError<T>;
Constructor
Parameters
Parameter
Type
Description
codeTThe error code associated with this error.
message?stringThe message associated with this error.
subError?string | number | ErrorSource error or a number tell more about the error.
customData?unknownAny kind of custom data related to error, which is converted to valid JSON
Returns
CCEverywhereError<T>
Overrides
Error.constructor
Accessors
code
Get Signature
get code(): T;
getter code
Returns
T
Methods
create()
static create<T>(
errorCodeMessage,
subError?,
customData?): CCEverywhereError<T>;
Type Parameters
Type Parameter
TParameters
Parameter
Type
errorCodeMessagesubError?string | number | ErrorcustomData?unknownReturns
CCEverywhereError<T>
createErrorFromData()
static createErrorFromData<T>(data): CCEverywhereError<T>;
Type Parameters
Type Parameter
TParameters
Parameter
Type
dataErrorData<T>Returns
CCEverywhereError<T>
toData()
toData(): ErrorData<T>;
Get a plain-object representation of the error..
Returns
ErrorData<T>
toString()
toString(): string;
Get complete message
Returns
string