UNPKG

@dolittle/sdk.projections

Version:

Dolittle is a decentralized, distributed, event-driven microservice platform built to harness the power of events.

21 lines 1.26 kB
"use strict"; // Copyright (c) Dolittle. All rights reserved. // Licensed under the MIT license. See LICENSE file in the project root for full license information. Object.defineProperty(exports, "__esModule", { value: true }); exports.IProjectionOf = void 0; /** * Defines a system that knows about a projection. * @template TReadModel The type of the projection read model. */ class IProjectionOf { /** * Gets a {@link ServiceIdentifier} for a Projection read model type to inject an {@link IProjectionOf} from the service provider. * @param {Constructor} type - The type of the projection read model. * @returns {Abstract} The service identifier to use for injection. */ static for(type) { return `IProjectionOf<${type.name}>`; } } exports.IProjectionOf = IProjectionOf; //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiSVByb2plY3Rpb25PZi5qcyIsInNvdXJjZVJvb3QiOiIuLi8iLCJzb3VyY2VzIjpbIlN0b3JlL0lQcm9qZWN0aW9uT2YudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLCtDQUErQztBQUMvQyxxR0FBcUc7OztBQVlyRzs7O0dBR0c7QUFDSCxNQUFzQixhQUFhO0lBa0MvQjs7OztPQUlHO0lBQ0gsTUFBTSxDQUFDLEdBQUcsQ0FBYSxJQUE2QjtRQUNoRCxPQUFPLGlCQUFpQixJQUFJLENBQUMsSUFBSSxHQUFVLENBQUM7SUFDaEQsQ0FBQztDQUNKO0FBMUNELHNDQTBDQyJ9