import { Ord } from 'fp-ts/lib/Ord'; import { Ordering } from 'fp-ts/lib/Ordering'; import * as t from 'io-ts'; export declare class EnumType extends t.Type { readonly _tag: 'EnumType'; enumObject: object; constructor(e: object, name?: string); } export declare const createEnumType: (e: object, name?: string | undefined) => EnumType; /** * Basically adds -infinity and +infinity to a PSN */ declare const PsnOrLimit: t.UnionC<[t.NumberC, t.LiteralC<"min">, t.LiteralC<"max">]>; export declare type PsnOrLimit = t.TypeOf; /** * A psn map with a default value, so it is a tabulated total function from source to PsnOrLimit */ export declare const OffsetMapWithDefault: t.ReadonlyC>; default: t.UnionC<[t.NumberC, t.LiteralC<"min">, t.LiteralC<"max">]>; }>>; export declare type OffsetMapWithDefault = t.TypeOf; declare type Tags = string[]; declare type TagsOnWire = string[] | undefined; declare const Tags: t.Type; export declare const EventIO: t.TypeC<{ psn: t.NumberC; semantics: t.StringC; sourceId: t.StringC; name: t.StringC; timestamp: t.NumberC; lamport: t.NumberC; tags: t.Type; payload: t.UnknownC; }>; /** A single Actyx Event */ export declare type Event = t.TypeOf; export declare const _compareEvents: (a: Event, b: Event) => Ordering; /** Event-related constants */ export declare const Event: { ord: Ord<{ psn: number; semantics: string; sourceId: string; name: string; timestamp: number; lamport: number; tags: Tags; payload: unknown; }>; }; /** * A number of events, not necessarily from the same source. */ export declare const Events: t.ArrayC; payload: t.UnknownC; }>>; /** * A number of events, not necessarily from the same source. */ export declare type Events = t.TypeOf; /** * A number of generated events, that are going to be written to the store. */ export declare const UnstoredEvent: t.ReadonlyC; payload: t.UnknownC; }>>; export declare type UnstoredEvent = t.TypeOf; export declare const UnstoredEvents: t.ReadonlyArrayC; payload: t.UnknownC; }>>>; export declare type UnstoredEvents = t.TypeOf; /** * Sort order for perstisted events */ export declare enum PersistedEventsSortOrders { EventKey = "eventKey", ReverseEventKey = "reverseEventKey", Unsorted = "unsorted" } export declare const PersistedEventsSortOrder: EnumType; export declare type PersistedEventsSortOrder = t.TypeOf; /** * Sort order for events */ export declare enum AllEventsSortOrders { EventKey = "eventKey", Unsorted = "unsorted" } export declare const AllEventsSortOrder: EnumType; export declare type AllEventsSortOrder = t.TypeOf; /** * Connectivity status type. * @public */ export declare enum ConnectivityStatusType { FullyConnected = "FullyConnected", PartiallyConnected = "PartiallyConnected", NotConnected = "NotConnected" } /** * The IO-TS type parser for ConnectivityStatus. * @public */ export declare const ConnectivityStatus: t.UnionC<[t.ReadonlyC; inCurrentStatusForMs: t.NumberC; }>>, t.ReadonlyC; inCurrentStatusForMs: t.NumberC; specialsDisconnected: t.ReadonlyArrayC; swarmConnectivityLevel: t.NumberC; eventsToRead: t.NumberC; eventsToSend: t.NumberC; }>>, t.ReadonlyC; inCurrentStatusForMs: t.NumberC; eventsToRead: t.NumberC; eventsToSend: t.NumberC; }>>]>; /** * Current connectivity of the underlying ActyxOS node. * @public */ export declare type ConnectivityStatus = t.TypeOf; /** Hook to run on store connection being closed. * @public */ export declare type StoreConnectionClosedHook = () => void; /** Configuration for the WebSocket store connection. * @public */ export declare type WsStoreConfig = { /** url of the destination */ url: string; /** protocol of the destination */ protocol?: string; /** Hook, when the connection to the store is closed */ onStoreConnectionClosed?: StoreConnectionClosedHook; /** retry interval to establish the connection */ reconnectTimeout?: number; }; export {};