/** * We're doing the long way around here with assignTag, TagBase & TagBaseTagged, * because there's a typescript compiler issue where it will complain about Equal.symbol, and Hash.symbol not being accessible. * https://github.com/microsoft/TypeScript/issues/52644 */ import { Tag } from "effect/Context"; import { Effect } from "effect/Effect"; import { Layer } from "effect/Layer"; import { Scope } from "effect/Scope"; import type { TagTypeId as TagTypeIdOriginal } from "effect/Context"; export declare const ServiceTag: unique symbol; export type ServiceTag = typeof ServiceTag; export declare abstract class PhantomTypeParameter { protected abstract readonly [ServiceTag]: { readonly [NameP in Identifier]: (_: InstantiatedType) => InstantiatedType; }; } /** * @tsplus type ServiceTagged */ export declare abstract class ServiceTagged extends PhantomTypeParameter { } /** * @tsplus static ServiceTagged make * @tsplus location "@effect-app/prelude/service" */ export declare function makeService>(_: Omit): T; /** * @tsplus fluent effect/data/Context/Tag make * @tsplus location "@effect-app/prelude/service" */ export declare function make, I = T>(_: Tag, t: Omit): T; export declare const TagTypeId: TagTypeIdOriginal; export type TagTypeId = typeof TagTypeId; export declare function assignTag(key?: string): (cls: S) => S & Tag; export declare function TagClass(key?: string): (new (service: ServiceImpl) => Readonly) & import("effect/Context").Tag; export declare const TagClassMake: () => (make: Effect, key?: string) => { new (service: ServiceImpl): Readonly; toLayer: () => Layer; toLayerScoped: () => Layer>; } & import("effect/Context").Tag; export declare function TagClassLegacy(key?: string): (abstract new () => {}) & import("effect/Context").Tag; /** @deprecated use `Id` of TagClass for unique id */ export declare function ServiceTaggedClass(): (_: Key) => ((abstract new () => {}) & { make: (t: Omit) => Service; }) & import("effect/Context").Tag; //# sourceMappingURL=service.d.ts.map