Organize into folders
This commit is contained in:
parent
84b8f1c9d6
commit
2e0d4b45ea
12 changed files with 121 additions and 64 deletions
|
@ -1,32 +0,0 @@
|
|||
export class MuseError extends Error {
|
||||
fmt(): string {
|
||||
return this.message;
|
||||
}
|
||||
}
|
||||
|
||||
export class FileError extends MuseError {
|
||||
filePath: string;
|
||||
details?: string;
|
||||
|
||||
constructor(message: string, filePath: string, details?: string) {
|
||||
super(message);
|
||||
this.filePath = filePath;
|
||||
this.details = details;
|
||||
}
|
||||
|
||||
fmt(): string {
|
||||
return `-- ${this.message} --\nFile Path: ${this.filePath}\nDetails: ${this.details}`;
|
||||
}
|
||||
}
|
||||
|
||||
export class MalformedResourceFileError extends FileError { }
|
||||
|
||||
export class FileNotFoundError extends FileError {
|
||||
constructor(filePath: string) {
|
||||
super("File not found", filePath);
|
||||
this.message = "File not found";
|
||||
this.filePath = filePath;
|
||||
}
|
||||
}
|
||||
|
||||
export class CLIError extends MuseError { }
|
Loading…
Add table
Add a link
Reference in a new issue