UNPKG

@inversifyjs/common

Version:

InversifyJs common utils

18 lines 606 B
const islazyServiceIdentifierSymbol = Symbol.for('@inversifyjs/common/islazyServiceIdentifier'); export class LazyServiceIdentifier { [islazyServiceIdentifierSymbol]; #buildServiceId; constructor(buildServiceId) { this.#buildServiceId = buildServiceId; this[islazyServiceIdentifierSymbol] = true; } static is(value) { return (typeof value === 'object' && value !== null && value[islazyServiceIdentifierSymbol] === true); } unwrap() { return this.#buildServiceId(); } } //# sourceMappingURL=LazyServiceIdentifier.js.map