MCPcopy Create free account
hub / github.com/Marus/cortex-debug / MIError

Class MIError

src/backend/backend.ts:178–198  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

176}
177
178export const MIError: MIErrorConstructor = class MIError {
179 public readonly name: string;
180 public readonly message: string;
181 public readonly source: string;
182 public constructor(message: string, source: string) {
183 Object.defineProperty(this, 'name', {
184 get: () => (this.constructor as any).name
185 });
186 Object.defineProperty(this, 'message', {
187 get: () => message
188 });
189 Object.defineProperty(this, 'source', {
190 get: () => source
191 });
192 Error.captureStackTrace(this, this.constructor);
193 }
194
195 public toString() {
196 return `${this.message} (from ${this.source})`;
197 }
198} as any;
199Object.setPrototypeOf(MIError as any, Object.create(Error.prototype));
200MIError.prototype.constructor = MIError;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected