First check-in of the code from the Obsidian Prj project.

This commit is contained in:
2024-08-14 19:40:52 +02:00
parent 1341427590
commit 6c4db19926
14 changed files with 495 additions and 0 deletions

View File

@@ -0,0 +1,30 @@
import { ITSInjex } from './IDIContainer';
/**
* General error class for {@link ITSInjex} interface.
*/
export class TSInjexError extends Error {
/**
* Creates a new instance of {@link TSInjexError}
* @param message **The error message**
*/
constructor(message: string) {
super(message);
this.name = 'TSInjex';
}
}
/**
* Error class for dependency resolution errors in {@link ITSInjex}.
* @see {@link ITSInjex.resolve}
*/
export class DependencyResolutionError extends TSInjexError {
/**
* Creates a new instance of {@link DependencyResolutionError}
* @param identifier **The identifier of the dependency**
*/
constructor(identifier: string) {
super(`Dependency ${identifier} not found.`);
this.name = 'TSInjexResolutionError';
}
}