effect 4.0.0-beta.71 → 4.0.0-beta.73
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Array.d.ts +65 -111
- package/dist/Array.d.ts.map +1 -1
- package/dist/Array.js +28 -44
- package/dist/Array.js.map +1 -1
- package/dist/BigDecimal.d.ts +66 -58
- package/dist/BigDecimal.d.ts.map +1 -1
- package/dist/BigDecimal.js +30 -26
- package/dist/BigDecimal.js.map +1 -1
- package/dist/BigInt.d.ts +21 -19
- package/dist/BigInt.d.ts.map +1 -1
- package/dist/BigInt.js +17 -15
- package/dist/BigInt.js.map +1 -1
- package/dist/Boolean.d.ts +15 -17
- package/dist/Boolean.d.ts.map +1 -1
- package/dist/Boolean.js +13 -13
- package/dist/Boolean.js.map +1 -1
- package/dist/Brand.d.ts +2 -3
- package/dist/Brand.d.ts.map +1 -1
- package/dist/Brand.js +2 -3
- package/dist/Brand.js.map +1 -1
- package/dist/Cache.d.ts +9 -9
- package/dist/Cache.js +3 -3
- package/dist/Cause.d.ts +35 -39
- package/dist/Cause.d.ts.map +1 -1
- package/dist/Cause.js +31 -33
- package/dist/Cause.js.map +1 -1
- package/dist/Channel.d.ts +141 -99
- package/dist/Channel.d.ts.map +1 -1
- package/dist/Channel.js +56 -42
- package/dist/Channel.js.map +1 -1
- package/dist/ChannelSchema.d.ts +3 -3
- package/dist/ChannelSchema.js +1 -1
- package/dist/Chunk.d.ts +67 -54
- package/dist/Chunk.d.ts.map +1 -1
- package/dist/Chunk.js +33 -22
- package/dist/Chunk.js.map +1 -1
- package/dist/Clock.d.ts +3 -3
- package/dist/Clock.js +1 -1
- package/dist/Combiner.d.ts +6 -10
- package/dist/Combiner.d.ts.map +1 -1
- package/dist/Combiner.js +6 -10
- package/dist/Combiner.js.map +1 -1
- package/dist/Config.d.ts +9 -10
- package/dist/Config.d.ts.map +1 -1
- package/dist/Config.js +7 -8
- package/dist/Config.js.map +1 -1
- package/dist/ConfigProvider.d.ts +4 -4
- package/dist/ConfigProvider.js +4 -4
- package/dist/Console.d.ts +11 -7
- package/dist/Console.d.ts.map +1 -1
- package/dist/Console.js +11 -7
- package/dist/Console.js.map +1 -1
- package/dist/Context.d.ts +35 -35
- package/dist/Context.js +13 -13
- package/dist/Cron.d.ts +7 -6
- package/dist/Cron.d.ts.map +1 -1
- package/dist/Cron.js +7 -6
- package/dist/Cron.js.map +1 -1
- package/dist/Crypto.d.ts +1 -1
- package/dist/Crypto.js +1 -1
- package/dist/Data.d.ts +26 -32
- package/dist/Data.d.ts.map +1 -1
- package/dist/Data.js +9 -8
- package/dist/Data.js.map +1 -1
- package/dist/DateTime.d.ts +164 -122
- package/dist/DateTime.d.ts.map +1 -1
- package/dist/DateTime.js +86 -66
- package/dist/DateTime.js.map +1 -1
- package/dist/Deferred.d.ts +6 -6
- package/dist/Deferred.js +4 -4
- package/dist/Duration.d.ts +39 -39
- package/dist/Duration.js +21 -21
- package/dist/Effect.d.ts +220 -309
- package/dist/Effect.d.ts.map +1 -1
- package/dist/Effect.js +115 -140
- package/dist/Effect.js.map +1 -1
- package/dist/Effectable.d.ts +2 -2
- package/dist/Effectable.js +2 -2
- package/dist/Encoding.d.ts +13 -10
- package/dist/Encoding.d.ts.map +1 -1
- package/dist/Encoding.js +12 -9
- package/dist/Encoding.js.map +1 -1
- package/dist/Equal.d.ts +3 -4
- package/dist/Equal.d.ts.map +1 -1
- package/dist/Equal.js +2 -3
- package/dist/Equal.js.map +1 -1
- package/dist/Equivalence.d.ts +5 -19
- package/dist/Equivalence.d.ts.map +1 -1
- package/dist/Equivalence.js +5 -14
- package/dist/Equivalence.js.map +1 -1
- package/dist/ErrorReporter.d.ts +14 -13
- package/dist/ErrorReporter.d.ts.map +1 -1
- package/dist/ErrorReporter.js +10 -9
- package/dist/ErrorReporter.js.map +1 -1
- package/dist/ExecutionPlan.d.ts +7 -2
- package/dist/ExecutionPlan.d.ts.map +1 -1
- package/dist/ExecutionPlan.js +7 -2
- package/dist/ExecutionPlan.js.map +1 -1
- package/dist/Exit.d.ts +25 -23
- package/dist/Exit.d.ts.map +1 -1
- package/dist/Exit.js +13 -13
- package/dist/Exit.js.map +1 -1
- package/dist/Fiber.d.ts +4 -4
- package/dist/Fiber.js +2 -2
- package/dist/FiberHandle.d.ts +6 -6
- package/dist/FiberHandle.js +4 -4
- package/dist/FiberMap.d.ts +18 -18
- package/dist/FiberMap.js +8 -8
- package/dist/FiberSet.d.ts +21 -13
- package/dist/FiberSet.d.ts.map +1 -1
- package/dist/FiberSet.js +17 -9
- package/dist/FiberSet.js.map +1 -1
- package/dist/FileSystem.d.ts +13 -9
- package/dist/FileSystem.d.ts.map +1 -1
- package/dist/FileSystem.js +11 -7
- package/dist/FileSystem.js.map +1 -1
- package/dist/Filter.d.ts +2 -2
- package/dist/Filter.js +2 -2
- package/dist/Formatter.d.ts +1 -3
- package/dist/Formatter.d.ts.map +1 -1
- package/dist/Formatter.js +1 -3
- package/dist/Formatter.js.map +1 -1
- package/dist/Function.d.ts +12 -12
- package/dist/Function.js +12 -12
- package/dist/Graph.d.ts +22 -22
- package/dist/Graph.js +12 -12
- package/dist/HKT.d.ts +5 -4
- package/dist/HKT.d.ts.map +1 -1
- package/dist/Hash.d.ts +3 -3
- package/dist/Hash.js +3 -3
- package/dist/HashMap.d.ts +33 -35
- package/dist/HashMap.d.ts.map +1 -1
- package/dist/HashMap.js +11 -13
- package/dist/HashMap.js.map +1 -1
- package/dist/HashRing.d.ts +7 -9
- package/dist/HashRing.d.ts.map +1 -1
- package/dist/HashRing.js +3 -5
- package/dist/HashRing.js.map +1 -1
- package/dist/HashSet.d.ts +16 -16
- package/dist/HashSet.js +6 -6
- package/dist/Inspectable.d.ts +4 -4
- package/dist/Inspectable.js +4 -4
- package/dist/Iterable.d.ts +82 -56
- package/dist/Iterable.d.ts.map +1 -1
- package/dist/Iterable.js +28 -20
- package/dist/Iterable.js.map +1 -1
- package/dist/JsonPatch.d.ts +1 -1
- package/dist/JsonPatch.js +1 -1
- package/dist/JsonPointer.d.ts +3 -3
- package/dist/JsonPointer.js +3 -3
- package/dist/JsonSchema.d.ts +13 -23
- package/dist/JsonSchema.d.ts.map +1 -1
- package/dist/JsonSchema.js +13 -23
- package/dist/JsonSchema.js.map +1 -1
- package/dist/Latch.d.ts +2 -2
- package/dist/Latch.js +2 -2
- package/dist/Layer.d.ts +47 -27
- package/dist/Layer.d.ts.map +1 -1
- package/dist/Layer.js +23 -15
- package/dist/Layer.js.map +1 -1
- package/dist/LayerMap.d.ts +1 -2
- package/dist/LayerMap.d.ts.map +1 -1
- package/dist/LayerMap.js +1 -2
- package/dist/LayerMap.js.map +1 -1
- package/dist/LogLevel.d.ts +3 -3
- package/dist/LogLevel.js +3 -3
- package/dist/Logger.d.ts +2 -2
- package/dist/Logger.js +2 -2
- package/dist/ManagedRuntime.d.ts +1 -1
- package/dist/ManagedRuntime.js +1 -1
- package/dist/Match.d.ts +32 -37
- package/dist/Match.d.ts.map +1 -1
- package/dist/Match.js +32 -37
- package/dist/Match.js.map +1 -1
- package/dist/Metric.d.ts +35 -21
- package/dist/Metric.d.ts.map +1 -1
- package/dist/Metric.js +34 -20
- package/dist/Metric.js.map +1 -1
- package/dist/MutableHashMap.d.ts +13 -19
- package/dist/MutableHashMap.d.ts.map +1 -1
- package/dist/MutableHashMap.js +5 -7
- package/dist/MutableHashMap.js.map +1 -1
- package/dist/MutableHashSet.d.ts +4 -4
- package/dist/MutableHashSet.js +2 -2
- package/dist/MutableList.d.ts +16 -6
- package/dist/MutableList.d.ts.map +1 -1
- package/dist/MutableList.js +15 -5
- package/dist/MutableList.js.map +1 -1
- package/dist/MutableRef.d.ts +5 -4
- package/dist/MutableRef.d.ts.map +1 -1
- package/dist/MutableRef.js +3 -2
- package/dist/MutableRef.js.map +1 -1
- package/dist/NonEmptyIterable.d.ts +3 -3
- package/dist/NonEmptyIterable.js +1 -1
- package/dist/Number.d.ts +20 -18
- package/dist/Number.d.ts.map +1 -1
- package/dist/Number.js +16 -14
- package/dist/Number.js.map +1 -1
- package/dist/Optic.d.ts +11 -18
- package/dist/Optic.d.ts.map +1 -1
- package/dist/Optic.js +7 -14
- package/dist/Optic.js.map +1 -1
- package/dist/Option.d.ts +21 -24
- package/dist/Option.d.ts.map +1 -1
- package/dist/Option.js +9 -10
- package/dist/Option.js.map +1 -1
- package/dist/Order.d.ts +11 -38
- package/dist/Order.d.ts.map +1 -1
- package/dist/Order.js +11 -33
- package/dist/Order.js.map +1 -1
- package/dist/Ordering.d.ts +5 -5
- package/dist/Ordering.js +3 -3
- package/dist/PartitionedSemaphore.d.ts +4 -8
- package/dist/PartitionedSemaphore.d.ts.map +1 -1
- package/dist/PartitionedSemaphore.js +3 -7
- package/dist/PartitionedSemaphore.js.map +1 -1
- package/dist/Path.d.ts +4 -7
- package/dist/Path.d.ts.map +1 -1
- package/dist/Path.js +3 -6
- package/dist/Path.js.map +1 -1
- package/dist/Pipeable.d.ts +2 -2
- package/dist/Pipeable.js +2 -2
- package/dist/PlatformError.d.ts +1 -1
- package/dist/PlatformError.js +1 -1
- package/dist/Predicate.d.ts +2 -81
- package/dist/Predicate.d.ts.map +1 -1
- package/dist/Predicate.js +2 -47
- package/dist/Predicate.js.map +1 -1
- package/dist/PrimaryKey.d.ts +3 -3
- package/dist/PrimaryKey.js +1 -1
- package/dist/PubSub.d.ts +147 -46
- package/dist/PubSub.d.ts.map +1 -1
- package/dist/PubSub.js +93 -32
- package/dist/PubSub.js.map +1 -1
- package/dist/Pull.d.ts +1 -1
- package/dist/Pull.js +1 -1
- package/dist/Queue.d.ts +40 -24
- package/dist/Queue.d.ts.map +1 -1
- package/dist/Queue.js +36 -20
- package/dist/Queue.js.map +1 -1
- package/dist/RcMap.d.ts +3 -3
- package/dist/RcMap.js +1 -1
- package/dist/Record.d.ts +79 -52
- package/dist/Record.d.ts.map +1 -1
- package/dist/Record.js +33 -22
- package/dist/Record.js.map +1 -1
- package/dist/Redactable.d.ts +7 -7
- package/dist/Redactable.js +7 -7
- package/dist/Reducer.d.ts +0 -2
- package/dist/Reducer.d.ts.map +1 -1
- package/dist/Reducer.js +0 -2
- package/dist/Reducer.js.map +1 -1
- package/dist/Ref.d.ts +12 -12
- package/dist/Ref.js +10 -10
- package/dist/References.d.ts +20 -20
- package/dist/References.js +20 -20
- package/dist/RegExp.d.ts +2 -2
- package/dist/RegExp.js +2 -2
- package/dist/Request.d.ts +3 -3
- package/dist/Request.js +3 -3
- package/dist/RequestResolver.d.ts +11 -14
- package/dist/RequestResolver.d.ts.map +1 -1
- package/dist/RequestResolver.js +5 -6
- package/dist/RequestResolver.js.map +1 -1
- package/dist/Result.d.ts +52 -34
- package/dist/Result.d.ts.map +1 -1
- package/dist/Result.js +44 -20
- package/dist/Result.js.map +1 -1
- package/dist/Runtime.d.ts +1 -1
- package/dist/Runtime.js +1 -1
- package/dist/Schedule.d.ts +20 -24
- package/dist/Schedule.d.ts.map +1 -1
- package/dist/Schedule.js +12 -12
- package/dist/Schedule.js.map +1 -1
- package/dist/Scheduler.d.ts +3 -3
- package/dist/Scheduler.js +3 -3
- package/dist/Schema.d.ts +480 -210
- package/dist/Schema.d.ts.map +1 -1
- package/dist/Schema.js +410 -172
- package/dist/Schema.js.map +1 -1
- package/dist/SchemaAST.d.ts +40 -32
- package/dist/SchemaAST.d.ts.map +1 -1
- package/dist/SchemaAST.js +40 -32
- package/dist/SchemaAST.js.map +1 -1
- package/dist/SchemaGetter.d.ts +4 -6
- package/dist/SchemaGetter.d.ts.map +1 -1
- package/dist/SchemaGetter.js +4 -6
- package/dist/SchemaGetter.js.map +1 -1
- package/dist/SchemaIssue.d.ts +35 -47
- package/dist/SchemaIssue.d.ts.map +1 -1
- package/dist/SchemaIssue.js +31 -42
- package/dist/SchemaIssue.js.map +1 -1
- package/dist/SchemaParser.d.ts +16 -12
- package/dist/SchemaParser.d.ts.map +1 -1
- package/dist/SchemaParser.js +16 -12
- package/dist/SchemaParser.js.map +1 -1
- package/dist/SchemaRepresentation.d.ts +47 -62
- package/dist/SchemaRepresentation.d.ts.map +1 -1
- package/dist/SchemaRepresentation.js +44 -58
- package/dist/SchemaRepresentation.js.map +1 -1
- package/dist/SchemaTransformation.d.ts +16 -18
- package/dist/SchemaTransformation.d.ts.map +1 -1
- package/dist/SchemaTransformation.js +13 -15
- package/dist/SchemaTransformation.js.map +1 -1
- package/dist/Scope.d.ts +51 -14
- package/dist/Scope.d.ts.map +1 -1
- package/dist/Scope.js +29 -8
- package/dist/Scope.js.map +1 -1
- package/dist/ScopedCache.d.ts +12 -12
- package/dist/ScopedCache.js +4 -4
- package/dist/ScopedRef.d.ts +2 -2
- package/dist/ScopedRef.js +2 -2
- package/dist/Semaphore.d.ts +1 -1
- package/dist/Semaphore.js +1 -1
- package/dist/Sink.d.ts +36 -41
- package/dist/Sink.d.ts.map +1 -1
- package/dist/Sink.js +21 -24
- package/dist/Sink.js.map +1 -1
- package/dist/Stdio.d.ts +5 -4
- package/dist/Stdio.d.ts.map +1 -1
- package/dist/Stdio.js +4 -3
- package/dist/Stdio.js.map +1 -1
- package/dist/Stream.d.ts +264 -165
- package/dist/Stream.d.ts.map +1 -1
- package/dist/Stream.js +103 -62
- package/dist/Stream.js.map +1 -1
- package/dist/String.d.ts +48 -47
- package/dist/String.d.ts.map +1 -1
- package/dist/String.js +32 -29
- package/dist/String.js.map +1 -1
- package/dist/Struct.d.ts +35 -100
- package/dist/Struct.d.ts.map +1 -1
- package/dist/Struct.js +13 -38
- package/dist/Struct.js.map +1 -1
- package/dist/SubscriptionRef.d.ts +268 -91
- package/dist/SubscriptionRef.d.ts.map +1 -1
- package/dist/SubscriptionRef.js +90 -31
- package/dist/SubscriptionRef.js.map +1 -1
- package/dist/Symbol.d.ts +1 -1
- package/dist/Symbol.js +1 -1
- package/dist/SynchronizedRef.d.ts +27 -27
- package/dist/SynchronizedRef.js +9 -9
- package/dist/Terminal.d.ts +8 -3
- package/dist/Terminal.d.ts.map +1 -1
- package/dist/Terminal.js +8 -3
- package/dist/Terminal.js.map +1 -1
- package/dist/Tracer.d.ts +25 -7
- package/dist/Tracer.d.ts.map +1 -1
- package/dist/Tracer.js +25 -7
- package/dist/Tracer.js.map +1 -1
- package/dist/Trie.d.ts +21 -23
- package/dist/Trie.d.ts.map +1 -1
- package/dist/Trie.js +7 -7
- package/dist/Trie.js.map +1 -1
- package/dist/Tuple.d.ts +26 -73
- package/dist/Tuple.d.ts.map +1 -1
- package/dist/Tuple.js +10 -31
- package/dist/Tuple.js.map +1 -1
- package/dist/TxChunk.d.ts +2 -2
- package/dist/TxChunk.js +2 -2
- package/dist/TxHashMap.d.ts +20 -20
- package/dist/TxHashMap.js +8 -8
- package/dist/TxHashSet.d.ts +14 -14
- package/dist/TxHashSet.js +6 -6
- package/dist/TxPriorityQueue.d.ts +14 -6
- package/dist/TxPriorityQueue.d.ts.map +1 -1
- package/dist/TxPriorityQueue.js +12 -4
- package/dist/TxPriorityQueue.js.map +1 -1
- package/dist/TxPubSub.d.ts +4 -4
- package/dist/TxPubSub.js +4 -4
- package/dist/TxQueue.d.ts +10 -10
- package/dist/TxQueue.js +10 -10
- package/dist/TxReentrantLock.d.ts +48 -12
- package/dist/TxReentrantLock.d.ts.map +1 -1
- package/dist/TxReentrantLock.js +38 -10
- package/dist/TxReentrantLock.js.map +1 -1
- package/dist/TxRef.d.ts +1 -1
- package/dist/TxRef.js +1 -1
- package/dist/TxSubscriptionRef.d.ts +1 -1
- package/dist/TxSubscriptionRef.js +1 -1
- package/dist/Types.d.ts +8 -7
- package/dist/Types.d.ts.map +1 -1
- package/dist/Unify.d.ts +19 -19
- package/dist/Utils.d.ts +1 -2
- package/dist/Utils.d.ts.map +1 -1
- package/dist/Utils.js +1 -2
- package/dist/Utils.js.map +1 -1
- package/dist/testing/TestSchema.d.ts +3 -11
- package/dist/testing/TestSchema.d.ts.map +1 -1
- package/dist/testing/TestSchema.js +3 -11
- package/dist/testing/TestSchema.js.map +1 -1
- package/dist/unstable/ai/AiError.d.ts +10 -5
- package/dist/unstable/ai/AiError.d.ts.map +1 -1
- package/dist/unstable/ai/AiError.js +10 -5
- package/dist/unstable/ai/AiError.js.map +1 -1
- package/dist/unstable/ai/Chat.d.ts +20 -5
- package/dist/unstable/ai/Chat.d.ts.map +1 -1
- package/dist/unstable/ai/Chat.js +20 -5
- package/dist/unstable/ai/Chat.js.map +1 -1
- package/dist/unstable/ai/EmbeddingModel.d.ts +5 -4
- package/dist/unstable/ai/EmbeddingModel.d.ts.map +1 -1
- package/dist/unstable/ai/EmbeddingModel.js +4 -3
- package/dist/unstable/ai/EmbeddingModel.js.map +1 -1
- package/dist/unstable/ai/IdGenerator.d.ts +7 -2
- package/dist/unstable/ai/IdGenerator.d.ts.map +1 -1
- package/dist/unstable/ai/IdGenerator.js +7 -2
- package/dist/unstable/ai/IdGenerator.js.map +1 -1
- package/dist/unstable/ai/LanguageModel.d.ts +10 -5
- package/dist/unstable/ai/LanguageModel.d.ts.map +1 -1
- package/dist/unstable/ai/LanguageModel.js +10 -5
- package/dist/unstable/ai/LanguageModel.js.map +1 -1
- package/dist/unstable/ai/McpSchema.d.ts +291 -169
- package/dist/unstable/ai/McpSchema.d.ts.map +1 -1
- package/dist/unstable/ai/McpSchema.js +270 -147
- package/dist/unstable/ai/McpSchema.js.map +1 -1
- package/dist/unstable/ai/McpServer.d.ts +49 -13
- package/dist/unstable/ai/McpServer.d.ts.map +1 -1
- package/dist/unstable/ai/McpServer.js +21 -9
- package/dist/unstable/ai/McpServer.js.map +1 -1
- package/dist/unstable/ai/Prompt.d.ts +1 -1
- package/dist/unstable/ai/Prompt.js +1 -1
- package/dist/unstable/ai/Response.d.ts +1 -1
- package/dist/unstable/ai/Response.js +1 -1
- package/dist/unstable/ai/Tokenizer.d.ts +7 -2
- package/dist/unstable/ai/Tokenizer.d.ts.map +1 -1
- package/dist/unstable/ai/Tokenizer.js +7 -2
- package/dist/unstable/ai/Tokenizer.js.map +1 -1
- package/dist/unstable/ai/Tool.d.ts +3 -3
- package/dist/unstable/ai/Tool.js +3 -3
- package/dist/unstable/cli/CliError.d.ts +3 -3
- package/dist/unstable/cli/CliError.js +3 -3
- package/dist/unstable/cli/CliOutput.d.ts +1 -1
- package/dist/unstable/cli/Command.d.ts +3 -3
- package/dist/unstable/cli/Command.js +1 -1
- package/dist/unstable/cli/Flag.d.ts +9 -9
- package/dist/unstable/cli/Flag.js +3 -3
- package/dist/unstable/cli/GlobalFlag.d.ts +13 -6
- package/dist/unstable/cli/GlobalFlag.d.ts.map +1 -1
- package/dist/unstable/cli/GlobalFlag.js +13 -6
- package/dist/unstable/cli/GlobalFlag.js.map +1 -1
- package/dist/unstable/cli/Param.d.ts +2 -2
- package/dist/unstable/cli/Param.js +2 -2
- package/dist/unstable/cli/Primitive.d.ts +1 -1
- package/dist/unstable/cli/Primitive.js +1 -1
- package/dist/unstable/cli/Prompt.d.ts +11 -6
- package/dist/unstable/cli/Prompt.d.ts.map +1 -1
- package/dist/unstable/cli/Prompt.js +26 -9
- package/dist/unstable/cli/Prompt.js.map +1 -1
- package/dist/unstable/cli/internal/parser.js +1 -1
- package/dist/unstable/cluster/ClusterMetrics.d.ts +5 -5
- package/dist/unstable/cluster/ClusterMetrics.js +5 -5
- package/dist/unstable/cluster/ClusterSchema.d.ts +11 -2
- package/dist/unstable/cluster/ClusterSchema.d.ts.map +1 -1
- package/dist/unstable/cluster/ClusterSchema.js +11 -2
- package/dist/unstable/cluster/ClusterSchema.js.map +1 -1
- package/dist/unstable/cluster/ClusterWorkflowEngine.d.ts.map +1 -1
- package/dist/unstable/cluster/ClusterWorkflowEngine.js +49 -10
- package/dist/unstable/cluster/ClusterWorkflowEngine.js.map +1 -1
- package/dist/unstable/cluster/DeliverAt.d.ts +6 -1
- package/dist/unstable/cluster/DeliverAt.d.ts.map +1 -1
- package/dist/unstable/cluster/DeliverAt.js +6 -1
- package/dist/unstable/cluster/DeliverAt.js.map +1 -1
- package/dist/unstable/cluster/Entity.d.ts +15 -5
- package/dist/unstable/cluster/Entity.d.ts.map +1 -1
- package/dist/unstable/cluster/Entity.js +15 -5
- package/dist/unstable/cluster/Entity.js.map +1 -1
- package/dist/unstable/cluster/EntityResource.d.ts +6 -6
- package/dist/unstable/cluster/EntityResource.d.ts.map +1 -1
- package/dist/unstable/cluster/EntityResource.js +9 -8
- package/dist/unstable/cluster/EntityResource.js.map +1 -1
- package/dist/unstable/cluster/Envelope.d.ts +11 -11
- package/dist/unstable/cluster/Envelope.d.ts.map +1 -1
- package/dist/unstable/cluster/Envelope.js +11 -11
- package/dist/unstable/cluster/Envelope.js.map +1 -1
- package/dist/unstable/cluster/HttpRunner.d.ts +16 -8
- package/dist/unstable/cluster/HttpRunner.d.ts.map +1 -1
- package/dist/unstable/cluster/HttpRunner.js +16 -8
- package/dist/unstable/cluster/HttpRunner.js.map +1 -1
- package/dist/unstable/cluster/Message.d.ts +10 -10
- package/dist/unstable/cluster/Message.js +10 -10
- package/dist/unstable/cluster/MessageStorage.d.ts +7 -7
- package/dist/unstable/cluster/MessageStorage.js +6 -6
- package/dist/unstable/cluster/Reply.d.ts +18 -8
- package/dist/unstable/cluster/Reply.d.ts.map +1 -1
- package/dist/unstable/cluster/Reply.js +18 -8
- package/dist/unstable/cluster/Reply.js.map +1 -1
- package/dist/unstable/cluster/Runner.d.ts +1 -1
- package/dist/unstable/cluster/Runner.js +1 -1
- package/dist/unstable/cluster/RunnerAddress.d.ts +7 -1
- package/dist/unstable/cluster/RunnerAddress.d.ts.map +1 -1
- package/dist/unstable/cluster/RunnerAddress.js +7 -1
- package/dist/unstable/cluster/RunnerAddress.js.map +1 -1
- package/dist/unstable/cluster/RunnerHealth.d.ts +4 -4
- package/dist/unstable/cluster/RunnerHealth.js +4 -4
- package/dist/unstable/cluster/RunnerServer.d.ts +4 -3
- package/dist/unstable/cluster/RunnerServer.d.ts.map +1 -1
- package/dist/unstable/cluster/RunnerServer.js +4 -3
- package/dist/unstable/cluster/RunnerServer.js.map +1 -1
- package/dist/unstable/cluster/Runners.d.ts +1 -1
- package/dist/unstable/cluster/ShardId.d.ts +2 -2
- package/dist/unstable/cluster/ShardId.js +2 -2
- package/dist/unstable/cluster/Sharding.d.ts +8 -3
- package/dist/unstable/cluster/Sharding.d.ts.map +1 -1
- package/dist/unstable/cluster/Sharding.js +8 -3
- package/dist/unstable/cluster/Sharding.js.map +1 -1
- package/dist/unstable/cluster/ShardingConfig.d.ts +3 -3
- package/dist/unstable/cluster/ShardingConfig.js +3 -3
- package/dist/unstable/cluster/ShardingRegistrationEvent.d.ts +1 -2
- package/dist/unstable/cluster/ShardingRegistrationEvent.d.ts.map +1 -1
- package/dist/unstable/cluster/ShardingRegistrationEvent.js +1 -2
- package/dist/unstable/cluster/ShardingRegistrationEvent.js.map +1 -1
- package/dist/unstable/cluster/SingleRunner.d.ts +1 -1
- package/dist/unstable/cluster/SingleRunner.js +1 -1
- package/dist/unstable/cluster/Snowflake.d.ts +6 -5
- package/dist/unstable/cluster/Snowflake.d.ts.map +1 -1
- package/dist/unstable/cluster/Snowflake.js +6 -5
- package/dist/unstable/cluster/Snowflake.js.map +1 -1
- package/dist/unstable/cluster/SocketRunner.d.ts +6 -1
- package/dist/unstable/cluster/SocketRunner.d.ts.map +1 -1
- package/dist/unstable/cluster/SocketRunner.js +6 -1
- package/dist/unstable/cluster/SocketRunner.js.map +1 -1
- package/dist/unstable/cluster/TestRunner.d.ts +1 -1
- package/dist/unstable/cluster/TestRunner.js +1 -1
- package/dist/unstable/encoding/Msgpack.d.ts +2 -1
- package/dist/unstable/encoding/Msgpack.d.ts.map +1 -1
- package/dist/unstable/encoding/Msgpack.js +2 -1
- package/dist/unstable/encoding/Msgpack.js.map +1 -1
- package/dist/unstable/encoding/Sse.d.ts +3 -3
- package/dist/unstable/encoding/Sse.js +3 -3
- package/dist/unstable/eventlog/EventGroup.d.ts +1 -1
- package/dist/unstable/eventlog/EventGroup.js +1 -1
- package/dist/unstable/eventlog/EventJournal.d.ts +7 -7
- package/dist/unstable/eventlog/EventJournal.js +5 -5
- package/dist/unstable/eventlog/EventLog.d.ts +11 -10
- package/dist/unstable/eventlog/EventLog.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLog.js +9 -8
- package/dist/unstable/eventlog/EventLog.js.map +1 -1
- package/dist/unstable/eventlog/EventLogEncryption.d.ts +8 -3
- package/dist/unstable/eventlog/EventLogEncryption.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogEncryption.js +8 -3
- package/dist/unstable/eventlog/EventLogEncryption.js.map +1 -1
- package/dist/unstable/eventlog/EventLogMessage.d.ts +28 -28
- package/dist/unstable/eventlog/EventLogMessage.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogMessage.js +27 -27
- package/dist/unstable/eventlog/EventLogMessage.js.map +1 -1
- package/dist/unstable/eventlog/EventLogRemote.d.ts +14 -4
- package/dist/unstable/eventlog/EventLogRemote.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogRemote.js +14 -4
- package/dist/unstable/eventlog/EventLogRemote.js.map +1 -1
- package/dist/unstable/eventlog/EventLogServer.d.ts +7 -2
- package/dist/unstable/eventlog/EventLogServer.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogServer.js +7 -2
- package/dist/unstable/eventlog/EventLogServer.js.map +1 -1
- package/dist/unstable/eventlog/EventLogServerEncrypted.d.ts +7 -2
- package/dist/unstable/eventlog/EventLogServerEncrypted.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogServerEncrypted.js +7 -2
- package/dist/unstable/eventlog/EventLogServerEncrypted.js.map +1 -1
- package/dist/unstable/eventlog/EventLogServerUnencrypted.d.ts +37 -7
- package/dist/unstable/eventlog/EventLogServerUnencrypted.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogServerUnencrypted.js +37 -7
- package/dist/unstable/eventlog/EventLogServerUnencrypted.js.map +1 -1
- package/dist/unstable/eventlog/EventLogSessionAuth.d.ts +33 -7
- package/dist/unstable/eventlog/EventLogSessionAuth.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogSessionAuth.js +33 -7
- package/dist/unstable/eventlog/EventLogSessionAuth.js.map +1 -1
- package/dist/unstable/http/Cookies.d.ts +40 -39
- package/dist/unstable/http/Cookies.d.ts.map +1 -1
- package/dist/unstable/http/Cookies.js +18 -17
- package/dist/unstable/http/Cookies.js.map +1 -1
- package/dist/unstable/http/FetchHttpClient.d.ts +6 -1
- package/dist/unstable/http/FetchHttpClient.d.ts.map +1 -1
- package/dist/unstable/http/FetchHttpClient.js +6 -1
- package/dist/unstable/http/FetchHttpClient.js.map +1 -1
- package/dist/unstable/http/Headers.d.ts +8 -7
- package/dist/unstable/http/Headers.d.ts.map +1 -1
- package/dist/unstable/http/Headers.js +6 -5
- package/dist/unstable/http/Headers.js.map +1 -1
- package/dist/unstable/http/HttpBody.d.ts +6 -2
- package/dist/unstable/http/HttpBody.d.ts.map +1 -1
- package/dist/unstable/http/HttpBody.js +6 -2
- package/dist/unstable/http/HttpBody.js.map +1 -1
- package/dist/unstable/http/HttpClient.d.ts +29 -9
- package/dist/unstable/http/HttpClient.d.ts.map +1 -1
- package/dist/unstable/http/HttpClient.js +15 -5
- package/dist/unstable/http/HttpClient.js.map +1 -1
- package/dist/unstable/http/HttpClientError.d.ts +15 -14
- package/dist/unstable/http/HttpClientError.d.ts.map +1 -1
- package/dist/unstable/http/HttpClientError.js +12 -11
- package/dist/unstable/http/HttpClientError.js.map +1 -1
- package/dist/unstable/http/HttpClientRequest.d.ts +1 -1
- package/dist/unstable/http/HttpClientRequest.js +1 -1
- package/dist/unstable/http/HttpEffect.d.ts +3 -3
- package/dist/unstable/http/HttpEffect.js +3 -3
- package/dist/unstable/http/HttpMethod.d.ts +16 -5
- package/dist/unstable/http/HttpMethod.d.ts.map +1 -1
- package/dist/unstable/http/HttpMethod.js +16 -5
- package/dist/unstable/http/HttpMethod.js.map +1 -1
- package/dist/unstable/http/HttpRouter.d.ts +18 -13
- package/dist/unstable/http/HttpRouter.d.ts.map +1 -1
- package/dist/unstable/http/HttpRouter.js +14 -9
- package/dist/unstable/http/HttpRouter.js.map +1 -1
- package/dist/unstable/http/HttpServer.d.ts +4 -4
- package/dist/unstable/http/HttpServer.js +4 -4
- package/dist/unstable/http/HttpServerError.d.ts +9 -9
- package/dist/unstable/http/HttpServerError.js +7 -7
- package/dist/unstable/http/HttpServerRequest.d.ts +20 -5
- package/dist/unstable/http/HttpServerRequest.d.ts.map +1 -1
- package/dist/unstable/http/HttpServerRequest.js +20 -5
- package/dist/unstable/http/HttpServerRequest.js.map +1 -1
- package/dist/unstable/http/HttpServerResponse.d.ts +24 -24
- package/dist/unstable/http/HttpServerResponse.js +8 -8
- package/dist/unstable/http/HttpTraceContext.d.ts +4 -4
- package/dist/unstable/http/HttpTraceContext.js +4 -4
- package/dist/unstable/http/Multipart.d.ts +2 -2
- package/dist/unstable/http/Multipart.js +2 -2
- package/dist/unstable/http/Url.d.ts +14 -17
- package/dist/unstable/http/Url.d.ts.map +1 -1
- package/dist/unstable/http/Url.js +5 -6
- package/dist/unstable/http/Url.js.map +1 -1
- package/dist/unstable/http/UrlParams.d.ts +10 -10
- package/dist/unstable/http/UrlParams.js +6 -6
- package/dist/unstable/httpapi/HttpApi.d.ts +2 -2
- package/dist/unstable/httpapi/HttpApi.js +2 -2
- package/dist/unstable/httpapi/HttpApiBuilder.d.ts +3 -3
- package/dist/unstable/httpapi/HttpApiBuilder.js +4 -5
- package/dist/unstable/httpapi/HttpApiBuilder.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiError.d.ts +2 -2
- package/dist/unstable/httpapi/HttpApiError.js +1 -1
- package/dist/unstable/httpapi/HttpApiSchema.d.ts +4 -7
- package/dist/unstable/httpapi/HttpApiSchema.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiSchema.js +3 -6
- package/dist/unstable/httpapi/HttpApiSchema.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiSecurity.d.ts +27 -5
- package/dist/unstable/httpapi/HttpApiSecurity.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiSecurity.js +26 -3
- package/dist/unstable/httpapi/HttpApiSecurity.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiTest.d.ts +1 -1
- package/dist/unstable/httpapi/HttpApiTest.js +1 -1
- package/dist/unstable/httpapi/OpenApi.d.ts +7 -1
- package/dist/unstable/httpapi/OpenApi.d.ts.map +1 -1
- package/dist/unstable/httpapi/OpenApi.js +9 -3
- package/dist/unstable/httpapi/OpenApi.js.map +1 -1
- package/dist/unstable/observability/OtlpLogger.d.ts +1 -1
- package/dist/unstable/observability/OtlpLogger.js +1 -1
- package/dist/unstable/observability/PrometheusMetrics.d.ts +2 -2
- package/dist/unstable/observability/PrometheusMetrics.js +2 -2
- package/dist/unstable/persistence/KeyValueStore.d.ts +8 -3
- package/dist/unstable/persistence/KeyValueStore.d.ts.map +1 -1
- package/dist/unstable/persistence/KeyValueStore.js +6 -1
- package/dist/unstable/persistence/KeyValueStore.js.map +1 -1
- package/dist/unstable/persistence/Persistable.d.ts +8 -3
- package/dist/unstable/persistence/Persistable.d.ts.map +1 -1
- package/dist/unstable/persistence/Persistable.js +8 -3
- package/dist/unstable/persistence/Persistable.js.map +1 -1
- package/dist/unstable/persistence/PersistedQueue.d.ts +10 -5
- package/dist/unstable/persistence/PersistedQueue.d.ts.map +1 -1
- package/dist/unstable/persistence/PersistedQueue.js +9 -4
- package/dist/unstable/persistence/PersistedQueue.js.map +1 -1
- package/dist/unstable/persistence/RateLimiter.d.ts +20 -10
- package/dist/unstable/persistence/RateLimiter.d.ts.map +1 -1
- package/dist/unstable/persistence/RateLimiter.js +19 -9
- package/dist/unstable/persistence/RateLimiter.js.map +1 -1
- package/dist/unstable/process/ChildProcess.d.ts +14 -14
- package/dist/unstable/process/ChildProcess.js +7 -7
- package/dist/unstable/process/ChildProcessSpawner.d.ts +2 -2
- package/dist/unstable/process/ChildProcessSpawner.js +2 -2
- package/dist/unstable/reactivity/AsyncResult.d.ts +36 -5
- package/dist/unstable/reactivity/AsyncResult.d.ts.map +1 -1
- package/dist/unstable/reactivity/AsyncResult.js +14 -3
- package/dist/unstable/reactivity/AsyncResult.js.map +1 -1
- package/dist/unstable/reactivity/Atom.d.ts +45 -13
- package/dist/unstable/reactivity/Atom.d.ts.map +1 -1
- package/dist/unstable/reactivity/Atom.js +34 -10
- package/dist/unstable/reactivity/Atom.js.map +1 -1
- package/dist/unstable/reactivity/AtomRegistry.d.ts +7 -2
- package/dist/unstable/reactivity/AtomRegistry.d.ts.map +1 -1
- package/dist/unstable/reactivity/AtomRegistry.js +7 -2
- package/dist/unstable/reactivity/AtomRegistry.js.map +1 -1
- package/dist/unstable/reactivity/Hydration.d.ts +6 -1
- package/dist/unstable/reactivity/Hydration.d.ts.map +1 -1
- package/dist/unstable/reactivity/Hydration.js +6 -1
- package/dist/unstable/reactivity/Hydration.js.map +1 -1
- package/dist/unstable/reactivity/Reactivity.d.ts +6 -1
- package/dist/unstable/reactivity/Reactivity.d.ts.map +1 -1
- package/dist/unstable/reactivity/Reactivity.js +6 -1
- package/dist/unstable/reactivity/Reactivity.js.map +1 -1
- package/dist/unstable/rpc/Rpc.d.ts +18 -14
- package/dist/unstable/rpc/Rpc.d.ts.map +1 -1
- package/dist/unstable/rpc/Rpc.js +15 -11
- package/dist/unstable/rpc/Rpc.js.map +1 -1
- package/dist/unstable/rpc/RpcClient.d.ts +27 -12
- package/dist/unstable/rpc/RpcClient.d.ts.map +1 -1
- package/dist/unstable/rpc/RpcClient.js +27 -12
- package/dist/unstable/rpc/RpcClient.js.map +1 -1
- package/dist/unstable/rpc/RpcClientError.d.ts +2 -2
- package/dist/unstable/rpc/RpcClientError.js +2 -2
- package/dist/unstable/rpc/RpcMessage.d.ts +5 -5
- package/dist/unstable/rpc/RpcMessage.js +4 -4
- package/dist/unstable/rpc/RpcSchema.d.ts +1 -1
- package/dist/unstable/rpc/RpcSchema.js +1 -1
- package/dist/unstable/rpc/RpcSerialization.d.ts +19 -12
- package/dist/unstable/rpc/RpcSerialization.d.ts.map +1 -1
- package/dist/unstable/rpc/RpcSerialization.js +19 -12
- package/dist/unstable/rpc/RpcSerialization.js.map +1 -1
- package/dist/unstable/rpc/RpcServer.d.ts +22 -17
- package/dist/unstable/rpc/RpcServer.d.ts.map +1 -1
- package/dist/unstable/rpc/RpcServer.js +22 -17
- package/dist/unstable/rpc/RpcServer.js.map +1 -1
- package/dist/unstable/schema/Model.d.ts +32 -33
- package/dist/unstable/schema/Model.d.ts.map +1 -1
- package/dist/unstable/schema/Model.js +25 -26
- package/dist/unstable/schema/Model.js.map +1 -1
- package/dist/unstable/schema/VariantSchema.d.ts +1 -1
- package/dist/unstable/schema/VariantSchema.js +1 -1
- package/dist/unstable/socket/Socket.d.ts +8 -2
- package/dist/unstable/socket/Socket.d.ts.map +1 -1
- package/dist/unstable/socket/Socket.js +8 -2
- package/dist/unstable/socket/Socket.js.map +1 -1
- package/dist/unstable/socket/SocketServer.d.ts +2 -2
- package/dist/unstable/socket/SocketServer.js +1 -1
- package/dist/unstable/sql/SqlClient.d.ts +7 -2
- package/dist/unstable/sql/SqlClient.d.ts.map +1 -1
- package/dist/unstable/sql/SqlClient.js +7 -2
- package/dist/unstable/sql/SqlClient.js.map +1 -1
- package/dist/unstable/sql/SqlConnection.d.ts +1 -1
- package/dist/unstable/sql/SqlConnection.js +1 -1
- package/dist/unstable/sql/SqlError.d.ts +2 -2
- package/dist/unstable/sql/SqlError.js +2 -2
- package/dist/unstable/sql/SqlResolver.d.ts +3 -3
- package/dist/unstable/sql/SqlResolver.js +1 -1
- package/dist/unstable/sql/SqlSchema.d.ts +19 -4
- package/dist/unstable/sql/SqlSchema.d.ts.map +1 -1
- package/dist/unstable/sql/SqlSchema.js +19 -4
- package/dist/unstable/sql/SqlSchema.js.map +1 -1
- package/dist/unstable/workers/Transferable.d.ts +3 -6
- package/dist/unstable/workers/Transferable.d.ts.map +1 -1
- package/dist/unstable/workers/Transferable.js +3 -6
- package/dist/unstable/workers/Transferable.js.map +1 -1
- package/dist/unstable/workers/Worker.d.ts +1 -1
- package/dist/unstable/workers/Worker.js +1 -1
- package/dist/unstable/workers/WorkerError.d.ts +1 -1
- package/dist/unstable/workflow/DurableClock.d.ts +2 -2
- package/dist/unstable/workflow/DurableClock.js +2 -2
- package/dist/unstable/workflow/DurableDeferred.d.ts +12 -12
- package/dist/unstable/workflow/DurableDeferred.js +7 -7
- package/dist/unstable/workflow/DurableQueue.d.ts +3 -3
- package/dist/unstable/workflow/DurableQueue.js +3 -3
- package/dist/unstable/workflow/Workflow.d.ts +22 -23
- package/dist/unstable/workflow/Workflow.d.ts.map +1 -1
- package/dist/unstable/workflow/Workflow.js +17 -18
- package/dist/unstable/workflow/Workflow.js.map +1 -1
- package/dist/unstable/workflow/WorkflowEngine.d.ts +26 -8
- package/dist/unstable/workflow/WorkflowEngine.d.ts.map +1 -1
- package/dist/unstable/workflow/WorkflowEngine.js +25 -7
- package/dist/unstable/workflow/WorkflowEngine.js.map +1 -1
- package/package.json +1 -1
- package/src/Array.ts +65 -113
- package/src/BigDecimal.ts +66 -58
- package/src/BigInt.ts +21 -19
- package/src/Boolean.ts +15 -17
- package/src/Brand.ts +2 -3
- package/src/Cache.ts +9 -9
- package/src/Cause.ts +35 -39
- package/src/Channel.ts +149 -107
- package/src/ChannelSchema.ts +3 -3
- package/src/Chunk.ts +67 -54
- package/src/Clock.ts +3 -3
- package/src/Combiner.ts +6 -10
- package/src/Config.ts +9 -10
- package/src/ConfigProvider.ts +4 -4
- package/src/Console.ts +11 -7
- package/src/Context.ts +36 -36
- package/src/Cron.ts +7 -6
- package/src/Crypto.ts +1 -1
- package/src/Data.ts +26 -32
- package/src/DateTime.ts +164 -122
- package/src/Deferred.ts +6 -6
- package/src/Duration.ts +39 -39
- package/src/Effect.ts +220 -309
- package/src/Effectable.ts +2 -2
- package/src/Encoding.ts +13 -10
- package/src/Equal.ts +3 -4
- package/src/Equivalence.ts +5 -19
- package/src/ErrorReporter.ts +14 -13
- package/src/ExecutionPlan.ts +7 -2
- package/src/Exit.ts +25 -23
- package/src/Fiber.ts +4 -4
- package/src/FiberHandle.ts +6 -6
- package/src/FiberMap.ts +20 -20
- package/src/FiberSet.ts +21 -13
- package/src/FileSystem.ts +13 -9
- package/src/Filter.ts +2 -2
- package/src/Formatter.ts +1 -3
- package/src/Function.ts +12 -12
- package/src/Graph.ts +22 -22
- package/src/HKT.ts +5 -4
- package/src/Hash.ts +3 -3
- package/src/HashMap.ts +33 -35
- package/src/HashRing.ts +7 -9
- package/src/HashSet.ts +16 -16
- package/src/Inspectable.ts +4 -4
- package/src/Iterable.ts +82 -56
- package/src/JsonPatch.ts +1 -1
- package/src/JsonPointer.ts +3 -3
- package/src/JsonSchema.ts +13 -23
- package/src/Latch.ts +2 -2
- package/src/Layer.ts +47 -27
- package/src/LayerMap.ts +1 -2
- package/src/LogLevel.ts +3 -3
- package/src/Logger.ts +6 -6
- package/src/ManagedRuntime.ts +1 -1
- package/src/Match.ts +32 -37
- package/src/Metric.ts +35 -21
- package/src/MutableHashMap.ts +21 -31
- package/src/MutableHashSet.ts +4 -4
- package/src/MutableList.ts +16 -6
- package/src/MutableRef.ts +5 -4
- package/src/NonEmptyIterable.ts +3 -3
- package/src/Number.ts +20 -18
- package/src/Optic.ts +11 -18
- package/src/Option.ts +21 -24
- package/src/Order.ts +11 -38
- package/src/Ordering.ts +5 -5
- package/src/PartitionedSemaphore.ts +4 -8
- package/src/Path.ts +4 -7
- package/src/Pipeable.ts +2 -2
- package/src/PlatformError.ts +1 -1
- package/src/Predicate.ts +2 -81
- package/src/PrimaryKey.ts +3 -3
- package/src/PubSub.ts +147 -46
- package/src/Pull.ts +1 -1
- package/src/Queue.ts +40 -24
- package/src/RcMap.ts +3 -3
- package/src/Record.ts +79 -52
- package/src/Redactable.ts +7 -7
- package/src/Reducer.ts +0 -2
- package/src/Ref.ts +32 -32
- package/src/References.ts +20 -20
- package/src/RegExp.ts +2 -2
- package/src/Request.ts +3 -3
- package/src/RequestResolver.ts +11 -14
- package/src/Result.ts +52 -34
- package/src/Runtime.ts +1 -1
- package/src/Schedule.ts +28 -36
- package/src/Scheduler.ts +3 -3
- package/src/Schema.ts +480 -210
- package/src/SchemaAST.ts +40 -32
- package/src/SchemaGetter.ts +4 -6
- package/src/SchemaIssue.ts +35 -47
- package/src/SchemaParser.ts +16 -12
- package/src/SchemaRepresentation.ts +47 -62
- package/src/SchemaTransformation.ts +16 -18
- package/src/Scope.ts +51 -14
- package/src/ScopedCache.ts +14 -14
- package/src/ScopedRef.ts +2 -2
- package/src/Semaphore.ts +1 -1
- package/src/Sink.ts +36 -41
- package/src/Stdio.ts +5 -4
- package/src/Stream.ts +275 -176
- package/src/String.ts +50 -49
- package/src/Struct.ts +35 -100
- package/src/SubscriptionRef.ts +268 -91
- package/src/Symbol.ts +1 -1
- package/src/SynchronizedRef.ts +27 -27
- package/src/Terminal.ts +8 -3
- package/src/Tracer.ts +25 -7
- package/src/Trie.ts +21 -23
- package/src/Tuple.ts +26 -73
- package/src/TxChunk.ts +2 -2
- package/src/TxHashMap.ts +22 -22
- package/src/TxHashSet.ts +22 -22
- package/src/TxPriorityQueue.ts +14 -6
- package/src/TxPubSub.ts +4 -4
- package/src/TxQueue.ts +10 -10
- package/src/TxReentrantLock.ts +48 -12
- package/src/TxRef.ts +1 -1
- package/src/TxSubscriptionRef.ts +1 -1
- package/src/Types.ts +8 -7
- package/src/Unify.ts +19 -19
- package/src/Utils.ts +1 -2
- package/src/testing/TestSchema.ts +3 -11
- package/src/unstable/ai/AiError.ts +10 -5
- package/src/unstable/ai/Chat.ts +20 -5
- package/src/unstable/ai/EmbeddingModel.ts +5 -4
- package/src/unstable/ai/IdGenerator.ts +7 -2
- package/src/unstable/ai/LanguageModel.ts +10 -5
- package/src/unstable/ai/McpSchema.ts +291 -169
- package/src/unstable/ai/McpServer.ts +49 -13
- package/src/unstable/ai/Prompt.ts +1 -1
- package/src/unstable/ai/Response.ts +1 -1
- package/src/unstable/ai/Tokenizer.ts +7 -2
- package/src/unstable/ai/Tool.ts +3 -3
- package/src/unstable/cli/CliError.ts +3 -3
- package/src/unstable/cli/CliOutput.ts +1 -1
- package/src/unstable/cli/Command.ts +3 -3
- package/src/unstable/cli/Flag.ts +9 -9
- package/src/unstable/cli/GlobalFlag.ts +13 -6
- package/src/unstable/cli/Param.ts +2 -2
- package/src/unstable/cli/Primitive.ts +1 -1
- package/src/unstable/cli/Prompt.ts +37 -13
- package/src/unstable/cli/internal/parser.ts +1 -1
- package/src/unstable/cluster/ClusterMetrics.ts +5 -5
- package/src/unstable/cluster/ClusterSchema.ts +11 -2
- package/src/unstable/cluster/ClusterWorkflowEngine.ts +63 -11
- package/src/unstable/cluster/DeliverAt.ts +6 -1
- package/src/unstable/cluster/Entity.ts +15 -5
- package/src/unstable/cluster/EntityResource.ts +13 -10
- package/src/unstable/cluster/Envelope.ts +11 -11
- package/src/unstable/cluster/HttpRunner.ts +16 -8
- package/src/unstable/cluster/Message.ts +10 -10
- package/src/unstable/cluster/MessageStorage.ts +7 -7
- package/src/unstable/cluster/Reply.ts +18 -8
- package/src/unstable/cluster/Runner.ts +1 -1
- package/src/unstable/cluster/RunnerAddress.ts +7 -1
- package/src/unstable/cluster/RunnerHealth.ts +4 -4
- package/src/unstable/cluster/RunnerServer.ts +4 -3
- package/src/unstable/cluster/Runners.ts +1 -1
- package/src/unstable/cluster/ShardId.ts +2 -2
- package/src/unstable/cluster/Sharding.ts +8 -3
- package/src/unstable/cluster/ShardingConfig.ts +3 -3
- package/src/unstable/cluster/ShardingRegistrationEvent.ts +1 -2
- package/src/unstable/cluster/SingleRunner.ts +1 -1
- package/src/unstable/cluster/Snowflake.ts +6 -5
- package/src/unstable/cluster/SocketRunner.ts +6 -1
- package/src/unstable/cluster/TestRunner.ts +1 -1
- package/src/unstable/encoding/Msgpack.ts +2 -1
- package/src/unstable/encoding/Sse.ts +3 -3
- package/src/unstable/eventlog/EventGroup.ts +1 -1
- package/src/unstable/eventlog/EventJournal.ts +7 -7
- package/src/unstable/eventlog/EventLog.ts +11 -10
- package/src/unstable/eventlog/EventLogEncryption.ts +8 -3
- package/src/unstable/eventlog/EventLogMessage.ts +28 -28
- package/src/unstable/eventlog/EventLogRemote.ts +14 -4
- package/src/unstable/eventlog/EventLogServer.ts +7 -2
- package/src/unstable/eventlog/EventLogServerEncrypted.ts +7 -2
- package/src/unstable/eventlog/EventLogServerUnencrypted.ts +37 -7
- package/src/unstable/eventlog/EventLogSessionAuth.ts +33 -7
- package/src/unstable/http/Cookies.ts +40 -39
- package/src/unstable/http/FetchHttpClient.ts +6 -1
- package/src/unstable/http/Headers.ts +10 -9
- package/src/unstable/http/HttpBody.ts +6 -2
- package/src/unstable/http/HttpClient.ts +29 -9
- package/src/unstable/http/HttpClientError.ts +15 -14
- package/src/unstable/http/HttpClientRequest.ts +1 -1
- package/src/unstable/http/HttpEffect.ts +3 -3
- package/src/unstable/http/HttpMethod.ts +16 -5
- package/src/unstable/http/HttpRouter.ts +18 -13
- package/src/unstable/http/HttpServer.ts +4 -4
- package/src/unstable/http/HttpServerError.ts +9 -9
- package/src/unstable/http/HttpServerRequest.ts +20 -5
- package/src/unstable/http/HttpServerResponse.ts +24 -24
- package/src/unstable/http/HttpTraceContext.ts +4 -4
- package/src/unstable/http/Multipart.ts +2 -2
- package/src/unstable/http/Url.ts +14 -17
- package/src/unstable/http/UrlParams.ts +10 -10
- package/src/unstable/httpapi/HttpApi.ts +2 -2
- package/src/unstable/httpapi/HttpApiBuilder.ts +5 -6
- package/src/unstable/httpapi/HttpApiError.ts +2 -2
- package/src/unstable/httpapi/HttpApiSchema.ts +4 -7
- package/src/unstable/httpapi/HttpApiSecurity.ts +36 -8
- package/src/unstable/httpapi/HttpApiTest.ts +1 -1
- package/src/unstable/httpapi/OpenApi.ts +9 -3
- package/src/unstable/observability/OtlpLogger.ts +1 -1
- package/src/unstable/observability/PrometheusMetrics.ts +2 -2
- package/src/unstable/persistence/KeyValueStore.ts +8 -3
- package/src/unstable/persistence/Persistable.ts +8 -3
- package/src/unstable/persistence/PersistedQueue.ts +10 -5
- package/src/unstable/persistence/RateLimiter.ts +20 -10
- package/src/unstable/process/ChildProcess.ts +14 -14
- package/src/unstable/process/ChildProcessSpawner.ts +2 -2
- package/src/unstable/reactivity/AsyncResult.ts +58 -7
- package/src/unstable/reactivity/Atom.ts +53 -13
- package/src/unstable/reactivity/AtomRegistry.ts +7 -2
- package/src/unstable/reactivity/Hydration.ts +6 -1
- package/src/unstable/reactivity/Reactivity.ts +6 -1
- package/src/unstable/rpc/Rpc.ts +18 -14
- package/src/unstable/rpc/RpcClient.ts +27 -12
- package/src/unstable/rpc/RpcClientError.ts +2 -2
- package/src/unstable/rpc/RpcMessage.ts +5 -5
- package/src/unstable/rpc/RpcSchema.ts +1 -1
- package/src/unstable/rpc/RpcSerialization.ts +19 -12
- package/src/unstable/rpc/RpcServer.ts +22 -17
- package/src/unstable/schema/Model.ts +32 -33
- package/src/unstable/schema/VariantSchema.ts +1 -1
- package/src/unstable/socket/Socket.ts +8 -2
- package/src/unstable/socket/SocketServer.ts +2 -2
- package/src/unstable/sql/SqlClient.ts +7 -2
- package/src/unstable/sql/SqlConnection.ts +1 -1
- package/src/unstable/sql/SqlError.ts +2 -2
- package/src/unstable/sql/SqlResolver.ts +3 -3
- package/src/unstable/sql/SqlSchema.ts +19 -4
- package/src/unstable/workers/Transferable.ts +3 -6
- package/src/unstable/workers/Worker.ts +1 -1
- package/src/unstable/workers/WorkerError.ts +1 -1
- package/src/unstable/workflow/DurableClock.ts +2 -2
- package/src/unstable/workflow/DurableDeferred.ts +12 -12
- package/src/unstable/workflow/DurableQueue.ts +3 -3
- package/src/unstable/workflow/Workflow.ts +22 -23
- package/src/unstable/workflow/WorkflowEngine.ts +26 -8
package/dist/Effect.d.ts
CHANGED
|
@@ -232,7 +232,7 @@ export type Error<T> = T extends Effect<infer _A, infer _E, infer _R> ? _E : nev
|
|
|
232
232
|
*/
|
|
233
233
|
export type Services<T> = T extends Effect<infer _A, infer _E, infer _R> ? _R : never;
|
|
234
234
|
/**
|
|
235
|
-
*
|
|
235
|
+
* Checks whether a value is an `Effect`.
|
|
236
236
|
*
|
|
237
237
|
* **Example** (Checking whether a value is an Effect)
|
|
238
238
|
*
|
|
@@ -1228,11 +1228,9 @@ export declare const promise: <A>(evaluate: (signal: AbortSignal) => PromiseLike
|
|
|
1228
1228
|
*
|
|
1229
1229
|
* **When to use**
|
|
1230
1230
|
*
|
|
1231
|
-
* Use when
|
|
1232
|
-
*
|
|
1233
|
-
*
|
|
1234
|
-
* throw exceptions by capturing those exceptions and transforming them into
|
|
1235
|
-
* manageable errors.
|
|
1231
|
+
* Use when you need to perform asynchronous operations that might fail, such
|
|
1232
|
+
* as fetching data from an API, and want thrown exceptions or rejected promises
|
|
1233
|
+
* captured as Effect errors.
|
|
1236
1234
|
*
|
|
1237
1235
|
* **Details**
|
|
1238
1236
|
*
|
|
@@ -1355,7 +1353,7 @@ export declare const succeedNone: Effect<Option<never>>;
|
|
|
1355
1353
|
*/
|
|
1356
1354
|
export declare const succeedSome: <A>(value: A) => Effect<Option<A>>;
|
|
1357
1355
|
/**
|
|
1358
|
-
*
|
|
1356
|
+
* Creates an `Effect` lazily, delaying construction until it is needed.
|
|
1359
1357
|
*
|
|
1360
1358
|
* **When to use**
|
|
1361
1359
|
*
|
|
@@ -1555,8 +1553,8 @@ export declare const callback: <A, E = never, R = never>(register: (this: Schedu
|
|
|
1555
1553
|
*/
|
|
1556
1554
|
export declare const never: Effect<never>;
|
|
1557
1555
|
/**
|
|
1558
|
-
*
|
|
1559
|
-
* do notation chains.
|
|
1556
|
+
* Effect that succeeds with an empty record `{}`, used as the starting point
|
|
1557
|
+
* for do notation chains.
|
|
1560
1558
|
*
|
|
1561
1559
|
* **Example** (Starting do notation)
|
|
1562
1560
|
*
|
|
@@ -1953,10 +1951,13 @@ export declare const fail: <E>(error: E) => Effect<never, E>;
|
|
|
1953
1951
|
/**
|
|
1954
1952
|
* Creates an `Effect` that represents a recoverable error using a lazy evaluation.
|
|
1955
1953
|
*
|
|
1954
|
+
* **When to use**
|
|
1955
|
+
*
|
|
1956
|
+
* Use to defer computing a recoverable error value until the effect is run.
|
|
1957
|
+
*
|
|
1956
1958
|
* **Details**
|
|
1957
1959
|
*
|
|
1958
|
-
*
|
|
1959
|
-
* defer the computation of the error value until the effect is actually run.
|
|
1960
|
+
* The error-producing function is evaluated each time the effect is executed.
|
|
1960
1961
|
*
|
|
1961
1962
|
* **Example** (Lazily creating failures)
|
|
1962
1963
|
*
|
|
@@ -2003,10 +2004,13 @@ export declare const failCause: <E>(cause: Cause.Cause<E>) => Effect<never, E>;
|
|
|
2003
2004
|
/**
|
|
2004
2005
|
* Creates an `Effect` that represents a failure with a `Cause` computed lazily.
|
|
2005
2006
|
*
|
|
2007
|
+
* **When to use**
|
|
2008
|
+
*
|
|
2009
|
+
* Use to defer computing a full `Cause` until the effect is run.
|
|
2010
|
+
*
|
|
2006
2011
|
* **Details**
|
|
2007
2012
|
*
|
|
2008
|
-
*
|
|
2009
|
-
* complex cause but want to defer the computation until the effect is run.
|
|
2013
|
+
* The cause-producing function is evaluated each time the effect is executed.
|
|
2010
2014
|
*
|
|
2011
2015
|
* **Example** (Lazily creating a Cause)
|
|
2012
2016
|
*
|
|
@@ -3151,7 +3155,7 @@ export declare const tap: {
|
|
|
3151
3155
|
<A, E, R, B, E2, R2>(self: Effect<A, E, R>, f: Effect<B, E2, R2>): Effect<A, E | E2, R | R2>;
|
|
3152
3156
|
};
|
|
3153
3157
|
/**
|
|
3154
|
-
*
|
|
3158
|
+
* Converts both success and failure of an `Effect` into a `Result` type.
|
|
3155
3159
|
*
|
|
3156
3160
|
* **When to use**
|
|
3157
3161
|
*
|
|
@@ -3206,7 +3210,7 @@ export declare const tap: {
|
|
|
3206
3210
|
*/
|
|
3207
3211
|
export declare const result: <A, E, R>(self: Effect<A, E, R>) => Effect<Result.Result<A, E>, never, R>;
|
|
3208
3212
|
/**
|
|
3209
|
-
*
|
|
3213
|
+
* Converts success to `Option.some` and failure to `Option.none`.
|
|
3210
3214
|
*
|
|
3211
3215
|
* **When to use**
|
|
3212
3216
|
*
|
|
@@ -3564,9 +3568,7 @@ export declare const as: {
|
|
|
3564
3568
|
<A, E, R, B>(self: Effect<A, E, R>, value: B): Effect<B, E, R>;
|
|
3565
3569
|
};
|
|
3566
3570
|
/**
|
|
3567
|
-
*
|
|
3568
|
-
* in an `Option` value. If the original `Effect` value fails, the returned
|
|
3569
|
-
* `Effect` value will also fail.
|
|
3571
|
+
* Maps the success value of an `Effect` to `Some`, preserving failures.
|
|
3570
3572
|
*
|
|
3571
3573
|
* **Example** (Wrapping success in Option.some)
|
|
3572
3574
|
*
|
|
@@ -3584,10 +3586,7 @@ export declare const as: {
|
|
|
3584
3586
|
*/
|
|
3585
3587
|
export declare const asSome: <A, E, R>(self: Effect<A, E, R>) => Effect<Option<A>, E, R>;
|
|
3586
3588
|
/**
|
|
3587
|
-
*
|
|
3588
|
-
* original `Effect` value succeeds, the returned `Effect` value will also
|
|
3589
|
-
* succeed. If the original `Effect` value fails, the returned `Effect` value
|
|
3590
|
-
* will fail with the same error.
|
|
3589
|
+
* Maps the success value of an `Effect` to `void`, preserving failures.
|
|
3591
3590
|
*
|
|
3592
3591
|
* **Example** (Discarding success values)
|
|
3593
3592
|
*
|
|
@@ -3605,15 +3604,16 @@ export declare const asSome: <A, E, R>(self: Effect<A, E, R>) => Effect<Option<A
|
|
|
3605
3604
|
*/
|
|
3606
3605
|
export declare const asVoid: <A, E, R>(self: Effect<A, E, R>) => Effect<void, E, R>;
|
|
3607
3606
|
/**
|
|
3608
|
-
*
|
|
3609
|
-
*
|
|
3607
|
+
* Swaps an effect's success and failure channels.
|
|
3608
|
+
*
|
|
3609
|
+
* **When to use**
|
|
3610
|
+
*
|
|
3611
|
+
* Use to handle the failure value as a success, or to move the success value
|
|
3612
|
+
* into the failure channel.
|
|
3610
3613
|
*
|
|
3611
3614
|
* **Details**
|
|
3612
3615
|
*
|
|
3613
|
-
*
|
|
3614
|
-
* treating the previously successful values as errors and vice versa. This can
|
|
3615
|
-
* be helpful in scenarios where you want to handle a success as a failure or
|
|
3616
|
-
* treat an error as a valid result.
|
|
3616
|
+
* For an `Effect<A, E, R>`, the returned effect has type `Effect<E, A, R>`.
|
|
3617
3617
|
*
|
|
3618
3618
|
* **Example** (Swapping success and failure channels)
|
|
3619
3619
|
*
|
|
@@ -3869,9 +3869,8 @@ export declare const zip: {
|
|
|
3869
3869
|
*
|
|
3870
3870
|
* **When to use**
|
|
3871
3871
|
*
|
|
3872
|
-
* Use when
|
|
3873
|
-
*
|
|
3874
|
-
* effects, combining them into a single value.
|
|
3872
|
+
* Use when you need to run two effects sequentially and combine their results
|
|
3873
|
+
* with a function instead of keeping the results as a tuple.
|
|
3875
3874
|
*
|
|
3876
3875
|
* **Details**
|
|
3877
3876
|
*
|
|
@@ -3918,9 +3917,8 @@ export declare const zipWith: {
|
|
|
3918
3917
|
*
|
|
3919
3918
|
* **When to use**
|
|
3920
3919
|
*
|
|
3921
|
-
* Use when
|
|
3922
|
-
*
|
|
3923
|
-
* effects, combining them into a single value.
|
|
3920
|
+
* Use when you need to run two effects sequentially and combine their results
|
|
3921
|
+
* with a function instead of keeping the results as a tuple.
|
|
3924
3922
|
*
|
|
3925
3923
|
* **Details**
|
|
3926
3924
|
*
|
|
@@ -3969,9 +3967,8 @@ export declare const zipWith: {
|
|
|
3969
3967
|
*
|
|
3970
3968
|
* **When to use**
|
|
3971
3969
|
*
|
|
3972
|
-
* Use when
|
|
3973
|
-
*
|
|
3974
|
-
* effects, combining them into a single value.
|
|
3970
|
+
* Use when you need to run two effects sequentially and combine their results
|
|
3971
|
+
* with a function instead of keeping the results as a tuple.
|
|
3975
3972
|
*
|
|
3976
3973
|
* **Details**
|
|
3977
3974
|
*
|
|
@@ -4180,12 +4177,9 @@ export declare const catchTag: {
|
|
|
4180
4177
|
*
|
|
4181
4178
|
* **When to use**
|
|
4182
4179
|
*
|
|
4183
|
-
* Use when
|
|
4184
|
-
*
|
|
4185
|
-
*
|
|
4186
|
-
* for that specific error. This allows you to catch and recover from multiple
|
|
4187
|
-
* error types in a single call. You can also provide a fallback handler for
|
|
4188
|
-
* unhandled errors.
|
|
4180
|
+
* Use when one recovery step should handle several tagged error types by
|
|
4181
|
+
* matching their readonly `_tag` fields. Pass a handler table whose keys are
|
|
4182
|
+
* tags, plus an optional fallback for unmatched errors.
|
|
4189
4183
|
*
|
|
4190
4184
|
* The error type must have a readonly `_tag` field to use `catchTag`. This
|
|
4191
4185
|
* field is used to identify and match errors.
|
|
@@ -4224,12 +4218,9 @@ export declare const catchTags: {
|
|
|
4224
4218
|
*
|
|
4225
4219
|
* **When to use**
|
|
4226
4220
|
*
|
|
4227
|
-
* Use when
|
|
4228
|
-
*
|
|
4229
|
-
*
|
|
4230
|
-
* for that specific error. This allows you to catch and recover from multiple
|
|
4231
|
-
* error types in a single call. You can also provide a fallback handler for
|
|
4232
|
-
* unhandled errors.
|
|
4221
|
+
* Use when one recovery step should handle several tagged error types by
|
|
4222
|
+
* matching their readonly `_tag` fields. Pass a handler table whose keys are
|
|
4223
|
+
* tags, plus an optional fallback for unmatched errors.
|
|
4233
4224
|
*
|
|
4234
4225
|
* The error type must have a readonly `_tag` field to use `catchTag`. This
|
|
4235
4226
|
* field is used to identify and match errors.
|
|
@@ -4288,12 +4279,9 @@ export declare const catchTags: {
|
|
|
4288
4279
|
*
|
|
4289
4280
|
* **When to use**
|
|
4290
4281
|
*
|
|
4291
|
-
* Use when
|
|
4292
|
-
*
|
|
4293
|
-
*
|
|
4294
|
-
* for that specific error. This allows you to catch and recover from multiple
|
|
4295
|
-
* error types in a single call. You can also provide a fallback handler for
|
|
4296
|
-
* unhandled errors.
|
|
4282
|
+
* Use when one recovery step should handle several tagged error types by
|
|
4283
|
+
* matching their readonly `_tag` fields. Pass a handler table whose keys are
|
|
4284
|
+
* tags, plus an optional fallback for unmatched errors.
|
|
4297
4285
|
*
|
|
4298
4286
|
* The error type must have a readonly `_tag` field to use `catchTag`. This
|
|
4299
4287
|
* field is used to identify and match errors.
|
|
@@ -4738,10 +4726,8 @@ export declare const unwrapReason: {
|
|
|
4738
4726
|
*
|
|
4739
4727
|
* **When to use**
|
|
4740
4728
|
*
|
|
4741
|
-
* Use when
|
|
4742
|
-
*
|
|
4743
|
-
* based on the `Cause` of the error, which provides detailed information about
|
|
4744
|
-
* the failure.
|
|
4729
|
+
* Use when recovery needs the full `Cause`, including recoverable failures,
|
|
4730
|
+
* defects, and interruptions, instead of only the typed error value.
|
|
4745
4731
|
*
|
|
4746
4732
|
* **Details**
|
|
4747
4733
|
*
|
|
@@ -4780,10 +4766,8 @@ export declare const catchCause: {
|
|
|
4780
4766
|
*
|
|
4781
4767
|
* **When to use**
|
|
4782
4768
|
*
|
|
4783
|
-
* Use when
|
|
4784
|
-
*
|
|
4785
|
-
* based on the `Cause` of the error, which provides detailed information about
|
|
4786
|
-
* the failure.
|
|
4769
|
+
* Use when recovery needs the full `Cause`, including recoverable failures,
|
|
4770
|
+
* defects, and interruptions, instead of only the typed error value.
|
|
4787
4771
|
*
|
|
4788
4772
|
* **Details**
|
|
4789
4773
|
*
|
|
@@ -4822,10 +4806,8 @@ export declare const catchCause: {
|
|
|
4822
4806
|
*
|
|
4823
4807
|
* **When to use**
|
|
4824
4808
|
*
|
|
4825
|
-
* Use when
|
|
4826
|
-
*
|
|
4827
|
-
* based on the `Cause` of the error, which provides detailed information about
|
|
4828
|
-
* the failure.
|
|
4809
|
+
* Use when recovery needs the full `Cause`, including recoverable failures,
|
|
4810
|
+
* defects, and interruptions, instead of only the typed error value.
|
|
4829
4811
|
*
|
|
4830
4812
|
* **Details**
|
|
4831
4813
|
*
|
|
@@ -4988,7 +4970,7 @@ export declare const catchDefect: {
|
|
|
4988
4970
|
*
|
|
4989
4971
|
* **When to use**
|
|
4990
4972
|
*
|
|
4991
|
-
* Use when
|
|
4973
|
+
* Use when you need to recover from errors that match a condition. Use a
|
|
4992
4974
|
* `Refinement` for type narrowing or a `Predicate` for simple boolean
|
|
4993
4975
|
* matching. Non-matching errors re-fail with the original cause. Defects and
|
|
4994
4976
|
* interrupts are not caught.
|
|
@@ -5028,7 +5010,7 @@ export declare const catchIf: {
|
|
|
5028
5010
|
*
|
|
5029
5011
|
* **When to use**
|
|
5030
5012
|
*
|
|
5031
|
-
* Use when
|
|
5013
|
+
* Use when you need to recover from errors that match a condition. Use a
|
|
5032
5014
|
* `Refinement` for type narrowing or a `Predicate` for simple boolean
|
|
5033
5015
|
* matching. Non-matching errors re-fail with the original cause. Defects and
|
|
5034
5016
|
* interrupts are not caught.
|
|
@@ -5068,7 +5050,7 @@ export declare const catchIf: {
|
|
|
5068
5050
|
*
|
|
5069
5051
|
* **When to use**
|
|
5070
5052
|
*
|
|
5071
|
-
* Use when
|
|
5053
|
+
* Use when you need to recover from errors that match a condition. Use a
|
|
5072
5054
|
* `Refinement` for type narrowing or a `Predicate` for simple boolean
|
|
5073
5055
|
* matching. Non-matching errors re-fail with the original cause. Defects and
|
|
5074
5056
|
* interrupts are not caught.
|
|
@@ -5108,7 +5090,7 @@ export declare const catchIf: {
|
|
|
5108
5090
|
*
|
|
5109
5091
|
* **When to use**
|
|
5110
5092
|
*
|
|
5111
|
-
* Use when
|
|
5093
|
+
* Use when you need to recover from errors that match a condition. Use a
|
|
5112
5094
|
* `Refinement` for type narrowing or a `Predicate` for simple boolean
|
|
5113
5095
|
* matching. Non-matching errors re-fail with the original cause. Defects and
|
|
5114
5096
|
* interrupts are not caught.
|
|
@@ -5148,7 +5130,7 @@ export declare const catchIf: {
|
|
|
5148
5130
|
*
|
|
5149
5131
|
* **When to use**
|
|
5150
5132
|
*
|
|
5151
|
-
* Use when
|
|
5133
|
+
* Use when you need to recover from errors that match a condition. Use a
|
|
5152
5134
|
* `Refinement` for type narrowing or a `Predicate` for simple boolean
|
|
5153
5135
|
* matching. Non-matching errors re-fail with the original cause. Defects and
|
|
5154
5136
|
* interrupts are not caught.
|
|
@@ -5493,8 +5475,7 @@ export declare const catchCauseFilter: {
|
|
|
5493
5475
|
<A, E, R, B, E2, R2, EB, X extends Cause.Cause<any>>(self: Effect<A, E, R>, filter: Filter.Filter<Cause.Cause<E>, EB, X>, f: (failure: EB, cause: Cause.Cause<E>) => Effect<B, E2, R2>): Effect<A | B, Cause.Cause.Error<X> | E2, R | R2>;
|
|
5494
5476
|
};
|
|
5495
5477
|
/**
|
|
5496
|
-
*
|
|
5497
|
-
* produced by an effect, without affecting its success value.
|
|
5478
|
+
* Transforms the failure value of an effect without changing its success value.
|
|
5498
5479
|
*
|
|
5499
5480
|
* **When to use**
|
|
5500
5481
|
*
|
|
@@ -5502,10 +5483,8 @@ export declare const catchCauseFilter: {
|
|
|
5502
5483
|
*
|
|
5503
5484
|
* **Details**
|
|
5504
5485
|
*
|
|
5505
|
-
*
|
|
5506
|
-
*
|
|
5507
|
-
* keeping the original behavior of the effect's success values intact. It only
|
|
5508
|
-
* operates on the error channel and leaves the success channel unchanged.
|
|
5486
|
+
* Only the failure channel is transformed. The success channel and requirements
|
|
5487
|
+
* are preserved.
|
|
5509
5488
|
*
|
|
5510
5489
|
* **Example** (Transforming the error channel)
|
|
5511
5490
|
*
|
|
@@ -5534,8 +5513,7 @@ export declare const catchCauseFilter: {
|
|
|
5534
5513
|
*/
|
|
5535
5514
|
export declare const mapError: {
|
|
5536
5515
|
/**
|
|
5537
|
-
*
|
|
5538
|
-
* produced by an effect, without affecting its success value.
|
|
5516
|
+
* Transforms the failure value of an effect without changing its success value.
|
|
5539
5517
|
*
|
|
5540
5518
|
* **When to use**
|
|
5541
5519
|
*
|
|
@@ -5543,10 +5521,8 @@ export declare const mapError: {
|
|
|
5543
5521
|
*
|
|
5544
5522
|
* **Details**
|
|
5545
5523
|
*
|
|
5546
|
-
*
|
|
5547
|
-
*
|
|
5548
|
-
* keeping the original behavior of the effect's success values intact. It only
|
|
5549
|
-
* operates on the error channel and leaves the success channel unchanged.
|
|
5524
|
+
* Only the failure channel is transformed. The success channel and requirements
|
|
5525
|
+
* are preserved.
|
|
5550
5526
|
*
|
|
5551
5527
|
* **Example** (Transforming the error channel)
|
|
5552
5528
|
*
|
|
@@ -5575,8 +5551,7 @@ export declare const mapError: {
|
|
|
5575
5551
|
*/
|
|
5576
5552
|
<E, E2>(f: (e: E) => E2): <A, R>(self: Effect<A, E, R>) => Effect<A, E2, R>;
|
|
5577
5553
|
/**
|
|
5578
|
-
*
|
|
5579
|
-
* produced by an effect, without affecting its success value.
|
|
5554
|
+
* Transforms the failure value of an effect without changing its success value.
|
|
5580
5555
|
*
|
|
5581
5556
|
* **When to use**
|
|
5582
5557
|
*
|
|
@@ -5584,10 +5559,8 @@ export declare const mapError: {
|
|
|
5584
5559
|
*
|
|
5585
5560
|
* **Details**
|
|
5586
5561
|
*
|
|
5587
|
-
*
|
|
5588
|
-
*
|
|
5589
|
-
* keeping the original behavior of the effect's success values intact. It only
|
|
5590
|
-
* operates on the error channel and leaves the success channel unchanged.
|
|
5562
|
+
* Only the failure channel is transformed. The success channel and requirements
|
|
5563
|
+
* are preserved.
|
|
5591
5564
|
*
|
|
5592
5565
|
* **Example** (Transforming the error channel)
|
|
5593
5566
|
*
|
|
@@ -6091,7 +6064,7 @@ export declare const tapCause: {
|
|
|
6091
6064
|
<A, E, R, X, E2, R2>(self: Effect<A, E, R>, f: (cause: Cause.Cause<E>) => Effect<X, E2, R2>): Effect<A, E | E2, R | R2>;
|
|
6092
6065
|
};
|
|
6093
6066
|
/**
|
|
6094
|
-
*
|
|
6067
|
+
* Executes a side effect conditionally when a failed effect's cause matches a predicate.
|
|
6095
6068
|
*
|
|
6096
6069
|
* **Details**
|
|
6097
6070
|
*
|
|
@@ -6123,7 +6096,7 @@ export declare const tapCause: {
|
|
|
6123
6096
|
*/
|
|
6124
6097
|
export declare const tapCauseIf: {
|
|
6125
6098
|
/**
|
|
6126
|
-
*
|
|
6099
|
+
* Executes a side effect conditionally when a failed effect's cause matches a predicate.
|
|
6127
6100
|
*
|
|
6128
6101
|
* **Details**
|
|
6129
6102
|
*
|
|
@@ -6155,7 +6128,7 @@ export declare const tapCauseIf: {
|
|
|
6155
6128
|
*/
|
|
6156
6129
|
<E, B, E2, R2>(predicate: Predicate.Predicate<Cause.Cause<E>>, f: (cause: Cause.Cause<E>) => Effect<B, E2, R2>): <A, R>(self: Effect<A, E, R>) => Effect<A, E | E2, R | R2>;
|
|
6157
6130
|
/**
|
|
6158
|
-
*
|
|
6131
|
+
* Executes a side effect conditionally when a failed effect's cause matches a predicate.
|
|
6159
6132
|
*
|
|
6160
6133
|
* **Details**
|
|
6161
6134
|
*
|
|
@@ -6188,7 +6161,7 @@ export declare const tapCauseIf: {
|
|
|
6188
6161
|
<A, E, R, B, E2, R2>(self: Effect<A, E, R>, predicate: Predicate.Predicate<Cause.Cause<E>>, f: (cause: Cause.Cause<E>) => Effect<B, E2, R2>): Effect<A, E | E2, R | R2>;
|
|
6189
6162
|
};
|
|
6190
6163
|
/**
|
|
6191
|
-
*
|
|
6164
|
+
* Executes a side effect conditionally when a failed effect's cause passes a filter.
|
|
6192
6165
|
*
|
|
6193
6166
|
* **When to use**
|
|
6194
6167
|
*
|
|
@@ -6210,7 +6183,7 @@ export declare const tapCauseIf: {
|
|
|
6210
6183
|
*/
|
|
6211
6184
|
export declare const tapCauseFilter: {
|
|
6212
6185
|
/**
|
|
6213
|
-
*
|
|
6186
|
+
* Executes a side effect conditionally when a failed effect's cause passes a filter.
|
|
6214
6187
|
*
|
|
6215
6188
|
* **When to use**
|
|
6216
6189
|
*
|
|
@@ -6232,7 +6205,7 @@ export declare const tapCauseFilter: {
|
|
|
6232
6205
|
*/
|
|
6233
6206
|
<E, B, E2, R2, EB, X extends Cause.Cause<any>>(filter: Filter.Filter<Cause.Cause<E>, EB, X>, f: (a: EB, cause: Cause.Cause<E>) => Effect<B, E2, R2>): <A, R>(self: Effect<A, E, R>) => Effect<A, E | E2, R | R2>;
|
|
6234
6207
|
/**
|
|
6235
|
-
*
|
|
6208
|
+
* Executes a side effect conditionally when a failed effect's cause passes a filter.
|
|
6236
6209
|
*
|
|
6237
6210
|
* **When to use**
|
|
6238
6211
|
*
|
|
@@ -7061,9 +7034,8 @@ export declare const sandbox: <A, E, R>(self: Effect<A, E, R>) => Effect<A, Caus
|
|
|
7061
7034
|
*
|
|
7062
7035
|
* **When to use**
|
|
7063
7036
|
*
|
|
7064
|
-
* Use when
|
|
7065
|
-
*
|
|
7066
|
-
* effects of the effect and do not need to handle or process its outcome.
|
|
7037
|
+
* Use when an effect should run for its side effects while both success and
|
|
7038
|
+
* failure values are discarded.
|
|
7067
7039
|
*
|
|
7068
7040
|
* Use the `log` option to emit the full {@link Cause} when the effect fails,
|
|
7069
7041
|
* and `message` to prepend a custom log message.
|
|
@@ -7139,7 +7111,7 @@ export declare const ignoreCause: <Arg extends Effect<any, any, any> | {
|
|
|
7139
7111
|
readonly message?: string | undefined;
|
|
7140
7112
|
} | undefined) => [Arg] extends [Effect<infer _A, infer _E, infer _R>] ? Effect<void, never, _R> : <A, E, R>(self: Effect<A, E, R>) => Effect<void, never, R>;
|
|
7141
7113
|
/**
|
|
7142
|
-
*
|
|
7114
|
+
* Applies an `ExecutionPlan` to an effect, retrying with step-provided resources
|
|
7143
7115
|
* until it succeeds or the plan is exhausted.
|
|
7144
7116
|
*
|
|
7145
7117
|
* **Details**
|
|
@@ -7176,7 +7148,7 @@ export declare const ignoreCause: <Arg extends Effect<any, any, any> | {
|
|
|
7176
7148
|
*/
|
|
7177
7149
|
export declare const withExecutionPlan: {
|
|
7178
7150
|
/**
|
|
7179
|
-
*
|
|
7151
|
+
* Applies an `ExecutionPlan` to an effect, retrying with step-provided resources
|
|
7180
7152
|
* until it succeeds or the plan is exhausted.
|
|
7181
7153
|
*
|
|
7182
7154
|
* **Details**
|
|
@@ -7218,7 +7190,7 @@ export declare const withExecutionPlan: {
|
|
|
7218
7190
|
requirements: PlanR;
|
|
7219
7191
|
}>): <A, E extends Input, R>(effect: Effect<A, E, R>) => Effect<A, E | PlanE, Exclude<R, Provides> | PlanR>;
|
|
7220
7192
|
/**
|
|
7221
|
-
*
|
|
7193
|
+
* Applies an `ExecutionPlan` to an effect, retrying with step-provided resources
|
|
7222
7194
|
* until it succeeds or the plan is exhausted.
|
|
7223
7195
|
*
|
|
7224
7196
|
* **Details**
|
|
@@ -7781,8 +7753,8 @@ export declare const timeoutOption: {
|
|
|
7781
7753
|
*
|
|
7782
7754
|
* **Details**
|
|
7783
7755
|
*
|
|
7784
|
-
*
|
|
7785
|
-
*
|
|
7756
|
+
* The fallback effect is created lazily by `orElse` and may introduce its own
|
|
7757
|
+
* success, failure, and requirement types.
|
|
7786
7758
|
*
|
|
7787
7759
|
* **Gotchas**
|
|
7788
7760
|
*
|
|
@@ -7835,8 +7807,8 @@ export declare const timeoutOrElse: {
|
|
|
7835
7807
|
*
|
|
7836
7808
|
* **Details**
|
|
7837
7809
|
*
|
|
7838
|
-
*
|
|
7839
|
-
*
|
|
7810
|
+
* The fallback effect is created lazily by `orElse` and may introduce its own
|
|
7811
|
+
* success, failure, and requirement types.
|
|
7840
7812
|
*
|
|
7841
7813
|
* **Gotchas**
|
|
7842
7814
|
*
|
|
@@ -7892,8 +7864,8 @@ export declare const timeoutOrElse: {
|
|
|
7892
7864
|
*
|
|
7893
7865
|
* **Details**
|
|
7894
7866
|
*
|
|
7895
|
-
*
|
|
7896
|
-
*
|
|
7867
|
+
* The fallback effect is created lazily by `orElse` and may introduce its own
|
|
7868
|
+
* success, failure, and requirement types.
|
|
7897
7869
|
*
|
|
7898
7870
|
* **Gotchas**
|
|
7899
7871
|
*
|
|
@@ -8031,7 +8003,7 @@ export declare const delay: {
|
|
|
8031
8003
|
*/
|
|
8032
8004
|
export declare const sleep: (duration: Duration.Input) => Effect<void>;
|
|
8033
8005
|
/**
|
|
8034
|
-
*
|
|
8006
|
+
* Returns the runtime duration of an effect together with its result.
|
|
8035
8007
|
*
|
|
8036
8008
|
* **Details**
|
|
8037
8009
|
*
|
|
@@ -8561,7 +8533,7 @@ export declare const filterMap: {
|
|
|
8561
8533
|
<A, B, X>(elements: Iterable<A>, filter: Filter.Filter<NoInfer<A>, B, X>): Effect<Array<B>>;
|
|
8562
8534
|
};
|
|
8563
8535
|
/**
|
|
8564
|
-
*
|
|
8536
|
+
* Filters and maps elements of an iterable effectfully with a `FilterEffect`.
|
|
8565
8537
|
*
|
|
8566
8538
|
* **When to use**
|
|
8567
8539
|
*
|
|
@@ -8586,7 +8558,7 @@ export declare const filterMap: {
|
|
|
8586
8558
|
*/
|
|
8587
8559
|
export declare const filterMapEffect: {
|
|
8588
8560
|
/**
|
|
8589
|
-
*
|
|
8561
|
+
* Filters and maps elements of an iterable effectfully with a `FilterEffect`.
|
|
8590
8562
|
*
|
|
8591
8563
|
* **When to use**
|
|
8592
8564
|
*
|
|
@@ -8613,7 +8585,7 @@ export declare const filterMapEffect: {
|
|
|
8613
8585
|
readonly concurrency?: Concurrency | undefined;
|
|
8614
8586
|
}): (elements: Iterable<A>) => Effect<Array<B>, E, R>;
|
|
8615
8587
|
/**
|
|
8616
|
-
*
|
|
8588
|
+
* Filters and maps elements of an iterable effectfully with a `FilterEffect`.
|
|
8617
8589
|
*
|
|
8618
8590
|
* **When to use**
|
|
8619
8591
|
*
|
|
@@ -9252,7 +9224,7 @@ export declare const filterMapOrFail: {
|
|
|
9252
9224
|
<A, E, R, B, X>(self: Effect<A, E, R>, filter: Filter.Filter<A, B, X>): Effect<B, Cause.NoSuchElementError | E, R>;
|
|
9253
9225
|
};
|
|
9254
9226
|
/**
|
|
9255
|
-
*
|
|
9227
|
+
* Runs an effect conditionally based on the result of an effectful boolean
|
|
9256
9228
|
* condition.
|
|
9257
9229
|
*
|
|
9258
9230
|
* **When to use**
|
|
@@ -9289,7 +9261,7 @@ export declare const filterMapOrFail: {
|
|
|
9289
9261
|
*/
|
|
9290
9262
|
export declare const when: {
|
|
9291
9263
|
/**
|
|
9292
|
-
*
|
|
9264
|
+
* Runs an effect conditionally based on the result of an effectful boolean
|
|
9293
9265
|
* condition.
|
|
9294
9266
|
*
|
|
9295
9267
|
* **When to use**
|
|
@@ -9326,7 +9298,7 @@ export declare const when: {
|
|
|
9326
9298
|
*/
|
|
9327
9299
|
<E2 = never, R2 = never>(condition: Effect<boolean, E2, R2>): <A, E, R>(self: Effect<A, E, R>) => Effect<Option<A>, E | E2, R | R2>;
|
|
9328
9300
|
/**
|
|
9329
|
-
*
|
|
9301
|
+
* Runs an effect conditionally based on the result of an effectful boolean
|
|
9330
9302
|
* condition.
|
|
9331
9303
|
*
|
|
9332
9304
|
* **When to use**
|
|
@@ -9863,7 +9835,7 @@ export declare const matchCauseEager: {
|
|
|
9863
9835
|
}): Effect<A2 | A3, never, R>;
|
|
9864
9836
|
};
|
|
9865
9837
|
/**
|
|
9866
|
-
*
|
|
9838
|
+
* Handles success or failure eagerly with effectful handlers when the effect is already resolved.
|
|
9867
9839
|
*
|
|
9868
9840
|
* **When to use**
|
|
9869
9841
|
*
|
|
@@ -9885,7 +9857,7 @@ export declare const matchCauseEager: {
|
|
|
9885
9857
|
*/
|
|
9886
9858
|
export declare const matchCauseEffectEager: {
|
|
9887
9859
|
/**
|
|
9888
|
-
*
|
|
9860
|
+
* Handles success or failure eagerly with effectful handlers when the effect is already resolved.
|
|
9889
9861
|
*
|
|
9890
9862
|
* **When to use**
|
|
9891
9863
|
*
|
|
@@ -9910,7 +9882,7 @@ export declare const matchCauseEffectEager: {
|
|
|
9910
9882
|
readonly onSuccess: (a: A) => Effect<A3, E3, R3>;
|
|
9911
9883
|
}): <R>(self: Effect<A, E, R>) => Effect<A2 | A3, E2 | E3, R2 | R3 | R>;
|
|
9912
9884
|
/**
|
|
9913
|
-
*
|
|
9885
|
+
* Handles success or failure eagerly with effectful handlers when the effect is already resolved.
|
|
9914
9886
|
*
|
|
9915
9887
|
* **When to use**
|
|
9916
9888
|
*
|
|
@@ -10873,6 +10845,11 @@ export declare const service: <I, S>(service: Context.Key<I, S>) => Effect<S, ne
|
|
|
10873
10845
|
/**
|
|
10874
10846
|
* Optionally accesses a service from the environment.
|
|
10875
10847
|
*
|
|
10848
|
+
* **When to use**
|
|
10849
|
+
*
|
|
10850
|
+
* Use to read an optional dependency from the current context without making
|
|
10851
|
+
* that dependency part of the effect's required environment.
|
|
10852
|
+
*
|
|
10876
10853
|
* **Details**
|
|
10877
10854
|
*
|
|
10878
10855
|
* This function attempts to access a service from the environment. If the
|
|
@@ -11143,8 +11120,7 @@ export declare const updateService: {
|
|
|
11143
11120
|
<XA, E, R, I, A>(self: Effect<XA, E, R>, service: Context.Key<I, A>, f: (value: A) => A): Effect<XA, E, R | I>;
|
|
11144
11121
|
};
|
|
11145
11122
|
/**
|
|
11146
|
-
*
|
|
11147
|
-
* implementation for a service in the context of an effect.
|
|
11123
|
+
* Provides one concrete service implementation to an effect.
|
|
11148
11124
|
*
|
|
11149
11125
|
* **When to use**
|
|
11150
11126
|
*
|
|
@@ -11152,11 +11128,8 @@ export declare const updateService: {
|
|
|
11152
11128
|
*
|
|
11153
11129
|
* **Details**
|
|
11154
11130
|
*
|
|
11155
|
-
*
|
|
11156
|
-
*
|
|
11157
|
-
* number generator), and then you use `provideService` to link that
|
|
11158
|
-
* service to its implementation. Once the implementation is provided, the
|
|
11159
|
-
* effect can be run successfully without further requirements.
|
|
11131
|
+
* The service requirement identified by the `Context.Key` is removed from the
|
|
11132
|
+
* effect requirements after the implementation is provided.
|
|
11160
11133
|
*
|
|
11161
11134
|
* **Example** (Providing a service value)
|
|
11162
11135
|
*
|
|
@@ -11197,8 +11170,7 @@ export declare const updateService: {
|
|
|
11197
11170
|
*/
|
|
11198
11171
|
export declare const provideService: {
|
|
11199
11172
|
/**
|
|
11200
|
-
*
|
|
11201
|
-
* implementation for a service in the context of an effect.
|
|
11173
|
+
* Provides one concrete service implementation to an effect.
|
|
11202
11174
|
*
|
|
11203
11175
|
* **When to use**
|
|
11204
11176
|
*
|
|
@@ -11206,11 +11178,8 @@ export declare const provideService: {
|
|
|
11206
11178
|
*
|
|
11207
11179
|
* **Details**
|
|
11208
11180
|
*
|
|
11209
|
-
*
|
|
11210
|
-
*
|
|
11211
|
-
* number generator), and then you use `provideService` to link that
|
|
11212
|
-
* service to its implementation. Once the implementation is provided, the
|
|
11213
|
-
* effect can be run successfully without further requirements.
|
|
11181
|
+
* The service requirement identified by the `Context.Key` is removed from the
|
|
11182
|
+
* effect requirements after the implementation is provided.
|
|
11214
11183
|
*
|
|
11215
11184
|
* **Example** (Providing a service value)
|
|
11216
11185
|
*
|
|
@@ -11251,8 +11220,7 @@ export declare const provideService: {
|
|
|
11251
11220
|
*/
|
|
11252
11221
|
<I, S>(service: Context.Key<I, S>): {
|
|
11253
11222
|
/**
|
|
11254
|
-
*
|
|
11255
|
-
* implementation for a service in the context of an effect.
|
|
11223
|
+
* Provides one concrete service implementation to an effect.
|
|
11256
11224
|
*
|
|
11257
11225
|
* **When to use**
|
|
11258
11226
|
*
|
|
@@ -11260,11 +11228,8 @@ export declare const provideService: {
|
|
|
11260
11228
|
*
|
|
11261
11229
|
* **Details**
|
|
11262
11230
|
*
|
|
11263
|
-
*
|
|
11264
|
-
*
|
|
11265
|
-
* number generator), and then you use `provideService` to link that
|
|
11266
|
-
* service to its implementation. Once the implementation is provided, the
|
|
11267
|
-
* effect can be run successfully without further requirements.
|
|
11231
|
+
* The service requirement identified by the `Context.Key` is removed from the
|
|
11232
|
+
* effect requirements after the implementation is provided.
|
|
11268
11233
|
*
|
|
11269
11234
|
* **Example** (Providing a service value)
|
|
11270
11235
|
*
|
|
@@ -11305,8 +11270,7 @@ export declare const provideService: {
|
|
|
11305
11270
|
*/
|
|
11306
11271
|
(implementation: S): <A, E, R>(self: Effect<A, E, R>) => Effect<A, E, Exclude<R, I>>;
|
|
11307
11272
|
/**
|
|
11308
|
-
*
|
|
11309
|
-
* implementation for a service in the context of an effect.
|
|
11273
|
+
* Provides one concrete service implementation to an effect.
|
|
11310
11274
|
*
|
|
11311
11275
|
* **When to use**
|
|
11312
11276
|
*
|
|
@@ -11314,11 +11278,8 @@ export declare const provideService: {
|
|
|
11314
11278
|
*
|
|
11315
11279
|
* **Details**
|
|
11316
11280
|
*
|
|
11317
|
-
*
|
|
11318
|
-
*
|
|
11319
|
-
* number generator), and then you use `provideService` to link that
|
|
11320
|
-
* service to its implementation. Once the implementation is provided, the
|
|
11321
|
-
* effect can be run successfully without further requirements.
|
|
11281
|
+
* The service requirement identified by the `Context.Key` is removed from the
|
|
11282
|
+
* effect requirements after the implementation is provided.
|
|
11322
11283
|
*
|
|
11323
11284
|
* **Example** (Providing a service value)
|
|
11324
11285
|
*
|
|
@@ -11360,8 +11321,7 @@ export declare const provideService: {
|
|
|
11360
11321
|
<A, E, R>(self: Effect<A, E, R>, implementation: S): Effect<A, E, Exclude<R, I>>;
|
|
11361
11322
|
};
|
|
11362
11323
|
/**
|
|
11363
|
-
*
|
|
11364
|
-
* implementation for a service in the context of an effect.
|
|
11324
|
+
* Provides one concrete service implementation to an effect.
|
|
11365
11325
|
*
|
|
11366
11326
|
* **When to use**
|
|
11367
11327
|
*
|
|
@@ -11369,11 +11329,8 @@ export declare const provideService: {
|
|
|
11369
11329
|
*
|
|
11370
11330
|
* **Details**
|
|
11371
11331
|
*
|
|
11372
|
-
*
|
|
11373
|
-
*
|
|
11374
|
-
* number generator), and then you use `provideService` to link that
|
|
11375
|
-
* service to its implementation. Once the implementation is provided, the
|
|
11376
|
-
* effect can be run successfully without further requirements.
|
|
11332
|
+
* The service requirement identified by the `Context.Key` is removed from the
|
|
11333
|
+
* effect requirements after the implementation is provided.
|
|
11377
11334
|
*
|
|
11378
11335
|
* **Example** (Providing a service value)
|
|
11379
11336
|
*
|
|
@@ -11414,8 +11371,7 @@ export declare const provideService: {
|
|
|
11414
11371
|
*/
|
|
11415
11372
|
<I, S>(service: Context.Key<I, S>, implementation: S): <A, E, R>(self: Effect<A, E, R>) => Effect<A, E, Exclude<R, I>>;
|
|
11416
11373
|
/**
|
|
11417
|
-
*
|
|
11418
|
-
* implementation for a service in the context of an effect.
|
|
11374
|
+
* Provides one concrete service implementation to an effect.
|
|
11419
11375
|
*
|
|
11420
11376
|
* **When to use**
|
|
11421
11377
|
*
|
|
@@ -11423,11 +11379,8 @@ export declare const provideService: {
|
|
|
11423
11379
|
*
|
|
11424
11380
|
* **Details**
|
|
11425
11381
|
*
|
|
11426
|
-
*
|
|
11427
|
-
*
|
|
11428
|
-
* number generator), and then you use `provideService` to link that
|
|
11429
|
-
* service to its implementation. Once the implementation is provided, the
|
|
11430
|
-
* effect can be run successfully without further requirements.
|
|
11382
|
+
* The service requirement identified by the `Context.Key` is removed from the
|
|
11383
|
+
* effect requirements after the implementation is provided.
|
|
11431
11384
|
*
|
|
11432
11385
|
* **Example** (Providing a service value)
|
|
11433
11386
|
*
|
|
@@ -11765,9 +11718,16 @@ export declare const withConcurrency: {
|
|
|
11765
11718
|
*/
|
|
11766
11719
|
export declare const scope: Effect<Scope, never, Scope>;
|
|
11767
11720
|
/**
|
|
11768
|
-
*
|
|
11769
|
-
*
|
|
11770
|
-
*
|
|
11721
|
+
* Runs an effect with a scope that closes when the effect completes.
|
|
11722
|
+
*
|
|
11723
|
+
* **When to use**
|
|
11724
|
+
*
|
|
11725
|
+
* Use to acquire scoped resources for the duration of a single workflow.
|
|
11726
|
+
*
|
|
11727
|
+
* **Details**
|
|
11728
|
+
*
|
|
11729
|
+
* Finalizers for resources acquired inside the workflow run as soon as the
|
|
11730
|
+
* workflow completes, whether by success, failure, or interruption.
|
|
11771
11731
|
*
|
|
11772
11732
|
* **Example** (Running a scoped acquisition)
|
|
11773
11733
|
*
|
|
@@ -11902,8 +11862,7 @@ export declare const acquireRelease: <A, E, R, R2>(acquire: Effect<A, E, R>, rel
|
|
|
11902
11862
|
readonly interruptible?: boolean;
|
|
11903
11863
|
}) => Effect<A, E, R | R2 | Scope>;
|
|
11904
11864
|
/**
|
|
11905
|
-
*
|
|
11906
|
-
* disposable value.
|
|
11865
|
+
* Acquires a scoped resource that implements JavaScript disposal protocols.
|
|
11907
11866
|
*
|
|
11908
11867
|
* **When to use**
|
|
11909
11868
|
*
|
|
@@ -11949,10 +11908,7 @@ export declare const acquireRelease: <A, E, R, R2>(acquire: Effect<A, E, R>, rel
|
|
|
11949
11908
|
*/
|
|
11950
11909
|
export declare const acquireDisposable: <A extends AsyncDisposable | Disposable, E, R>(acquire: Effect<A, E, R>) => Effect<A, E, R | Scope>;
|
|
11951
11910
|
/**
|
|
11952
|
-
*
|
|
11953
|
-
* acquisition of a resource (for example, opening a file, launching a thread,
|
|
11954
|
-
* etc.) will not be interrupted, and that the resource will always be released
|
|
11955
|
-
* when the `Effect` value completes execution.
|
|
11911
|
+
* Runs resource acquisition, usage, and release as one bracketed effect.
|
|
11956
11912
|
*
|
|
11957
11913
|
* **When to use**
|
|
11958
11914
|
*
|
|
@@ -12030,9 +11986,7 @@ export declare const acquireDisposable: <A extends AsyncDisposable | Disposable,
|
|
|
12030
11986
|
*/
|
|
12031
11987
|
export declare const acquireUseRelease: <Resource, E, R, A, E2, R2, E3, R3>(acquire: Effect<Resource, E, R>, use: (a: Resource) => Effect<A, E2, R2>, release: (a: Resource, exit: Exit.Exit<A, E2>) => Effect<void, E3, R3>) => Effect<A, E | E2 | E3, R | R2 | R3>;
|
|
12032
11988
|
/**
|
|
12033
|
-
*
|
|
12034
|
-
* The finalizer is guaranteed to be run when the scope is closed, and it may
|
|
12035
|
-
* depend on the `Exit` value that the scope is closed with.
|
|
11989
|
+
* Adds a finalizer to the current scope.
|
|
12036
11990
|
*
|
|
12037
11991
|
* **When to use**
|
|
12038
11992
|
*
|
|
@@ -12040,9 +11994,8 @@ export declare const acquireUseRelease: <Resource, E, R, A, E2, R2, E3, R3>(acqu
|
|
|
12040
11994
|
*
|
|
12041
11995
|
* **Details**
|
|
12042
11996
|
*
|
|
12043
|
-
*
|
|
12044
|
-
*
|
|
12045
|
-
* cleanup, logging, or other side effects that should always occur.
|
|
11997
|
+
* The finalizer runs when the surrounding scope is closed and receives the
|
|
11998
|
+
* `Exit` value used to close the scope.
|
|
12046
11999
|
*
|
|
12047
12000
|
* **Example** (Registering scope finalizers)
|
|
12048
12001
|
*
|
|
@@ -12446,8 +12399,8 @@ export declare const onErrorFilter: {
|
|
|
12446
12399
|
*/
|
|
12447
12400
|
export declare const onExitPrimitive: <A, E, R, XE = never, XR = never>(self: Effect<A, E, R>, f: (exit: Exit.Exit<A, E>) => Effect<void, XE, XR> | undefined, interruptible?: boolean) => Effect<A, E | XE, R | XR>;
|
|
12448
12401
|
/**
|
|
12449
|
-
* Ensures that a cleanup
|
|
12450
|
-
*
|
|
12402
|
+
* Ensures that a cleanup function runs whether this effect succeeds, fails, or
|
|
12403
|
+
* is interrupted.
|
|
12451
12404
|
*
|
|
12452
12405
|
* **Example** (Observing every exit)
|
|
12453
12406
|
*
|
|
@@ -12474,8 +12427,8 @@ export declare const onExitPrimitive: <A, E, R, XE = never, XR = never>(self: Ef
|
|
|
12474
12427
|
*/
|
|
12475
12428
|
export declare const onExit: {
|
|
12476
12429
|
/**
|
|
12477
|
-
* Ensures that a cleanup
|
|
12478
|
-
*
|
|
12430
|
+
* Ensures that a cleanup function runs whether this effect succeeds, fails, or
|
|
12431
|
+
* is interrupted.
|
|
12479
12432
|
*
|
|
12480
12433
|
* **Example** (Observing every exit)
|
|
12481
12434
|
*
|
|
@@ -12502,8 +12455,8 @@ export declare const onExit: {
|
|
|
12502
12455
|
*/
|
|
12503
12456
|
<A, E, XE = never, XR = never>(f: (exit: Exit.Exit<A, E>) => Effect<void, XE, XR>): <R>(self: Effect<A, E, R>) => Effect<A, E | XE, R | XR>;
|
|
12504
12457
|
/**
|
|
12505
|
-
* Ensures that a cleanup
|
|
12506
|
-
*
|
|
12458
|
+
* Ensures that a cleanup function runs whether this effect succeeds, fails, or
|
|
12459
|
+
* is interrupted.
|
|
12507
12460
|
*
|
|
12508
12461
|
* **Example** (Observing every exit)
|
|
12509
12462
|
*
|
|
@@ -12934,18 +12887,14 @@ export declare const cachedWithTTL: {
|
|
|
12934
12887
|
<A, E, R>(self: Effect<A, E, R>, timeToLive: Duration.Input): Effect<Effect<A, E, R>>;
|
|
12935
12888
|
};
|
|
12936
12889
|
/**
|
|
12937
|
-
*
|
|
12890
|
+
* Creates a cached effect result for a specified duration and allows manual
|
|
12938
12891
|
* invalidation before expiration.
|
|
12939
12892
|
*
|
|
12940
12893
|
* **When to use**
|
|
12941
12894
|
*
|
|
12942
|
-
* Use when
|
|
12943
|
-
*
|
|
12944
|
-
*
|
|
12945
|
-
*
|
|
12946
|
-
* This is useful when you need to ensure that the cached data remains valid for
|
|
12947
|
-
* a certain period but still want to invalidate it if the underlying data
|
|
12948
|
-
* changes or if you want to force a recomputation.
|
|
12895
|
+
* Use when an effect result should be cached for a bounded time and callers
|
|
12896
|
+
* also need a manual invalidation effect to force recomputation before
|
|
12897
|
+
* expiration.
|
|
12949
12898
|
*
|
|
12950
12899
|
* **Details**
|
|
12951
12900
|
*
|
|
@@ -13004,18 +12953,14 @@ export declare const cachedWithTTL: {
|
|
|
13004
12953
|
*/
|
|
13005
12954
|
export declare const cachedInvalidateWithTTL: {
|
|
13006
12955
|
/**
|
|
13007
|
-
*
|
|
12956
|
+
* Creates a cached effect result for a specified duration and allows manual
|
|
13008
12957
|
* invalidation before expiration.
|
|
13009
12958
|
*
|
|
13010
12959
|
* **When to use**
|
|
13011
12960
|
*
|
|
13012
|
-
* Use when
|
|
13013
|
-
*
|
|
13014
|
-
*
|
|
13015
|
-
*
|
|
13016
|
-
* This is useful when you need to ensure that the cached data remains valid for
|
|
13017
|
-
* a certain period but still want to invalidate it if the underlying data
|
|
13018
|
-
* changes or if you want to force a recomputation.
|
|
12961
|
+
* Use when an effect result should be cached for a bounded time and callers
|
|
12962
|
+
* also need a manual invalidation effect to force recomputation before
|
|
12963
|
+
* expiration.
|
|
13019
12964
|
*
|
|
13020
12965
|
* **Details**
|
|
13021
12966
|
*
|
|
@@ -13074,18 +13019,14 @@ export declare const cachedInvalidateWithTTL: {
|
|
|
13074
13019
|
*/
|
|
13075
13020
|
(timeToLive: Duration.Input): <A, E, R>(self: Effect<A, E, R>) => Effect<[Effect<A, E, R>, Effect<void>]>;
|
|
13076
13021
|
/**
|
|
13077
|
-
*
|
|
13022
|
+
* Creates a cached effect result for a specified duration and allows manual
|
|
13078
13023
|
* invalidation before expiration.
|
|
13079
13024
|
*
|
|
13080
13025
|
* **When to use**
|
|
13081
13026
|
*
|
|
13082
|
-
* Use when
|
|
13083
|
-
*
|
|
13084
|
-
*
|
|
13085
|
-
*
|
|
13086
|
-
* This is useful when you need to ensure that the cached data remains valid for
|
|
13087
|
-
* a certain period but still want to invalidate it if the underlying data
|
|
13088
|
-
* changes or if you want to force a recomputation.
|
|
13027
|
+
* Use when an effect result should be cached for a bounded time and callers
|
|
13028
|
+
* also need a manual invalidation effect to force recomputation before
|
|
13029
|
+
* expiration.
|
|
13089
13030
|
*
|
|
13090
13031
|
* **Details**
|
|
13091
13032
|
*
|
|
@@ -13319,9 +13260,8 @@ export declare const uninterruptible: <A, E, R>(self: Effect<A, E, R>) => Effect
|
|
|
13319
13260
|
*/
|
|
13320
13261
|
export declare const uninterruptibleMask: <A, E, R>(f: (restore: <AX, EX, RX>(effect: Effect<AX, EX, RX>) => Effect<AX, EX, RX>) => Effect<A, E, R>) => Effect<A, E, R>;
|
|
13321
13262
|
/**
|
|
13322
|
-
*
|
|
13323
|
-
*
|
|
13324
|
-
* of any specific region of code.
|
|
13263
|
+
* Runs an effect in an interruptible region while providing `restore` for
|
|
13264
|
+
* locally restoring the previous interruptibility.
|
|
13325
13265
|
*
|
|
13326
13266
|
* **Example** (Controlling interruptibility locally)
|
|
13327
13267
|
*
|
|
@@ -15116,7 +15056,7 @@ export declare const spanAnnotations: Effect<Readonly<Record<string, unknown>>>;
|
|
|
15116
15056
|
*/
|
|
15117
15057
|
export declare const spanLinks: Effect<ReadonlyArray<SpanLink>>;
|
|
15118
15058
|
/**
|
|
15119
|
-
*
|
|
15059
|
+
* Adds a link with the provided span to all spans in this effect.
|
|
15120
15060
|
*
|
|
15121
15061
|
* **Details**
|
|
15122
15062
|
*
|
|
@@ -15171,7 +15111,7 @@ export declare const spanLinks: Effect<ReadonlyArray<SpanLink>>;
|
|
|
15171
15111
|
*/
|
|
15172
15112
|
export declare const linkSpans: {
|
|
15173
15113
|
/**
|
|
15174
|
-
*
|
|
15114
|
+
* Adds a link with the provided span to all spans in this effect.
|
|
15175
15115
|
*
|
|
15176
15116
|
* **Details**
|
|
15177
15117
|
*
|
|
@@ -15226,7 +15166,7 @@ export declare const linkSpans: {
|
|
|
15226
15166
|
*/
|
|
15227
15167
|
(span: AnySpan | ReadonlyArray<AnySpan>, attributes?: Record<string, unknown>): <A, E, R>(self: Effect<A, E, R>) => Effect<A, E, R>;
|
|
15228
15168
|
/**
|
|
15229
|
-
*
|
|
15169
|
+
* Adds a link with the provided span to all spans in this effect.
|
|
15230
15170
|
*
|
|
15231
15171
|
* **Details**
|
|
15232
15172
|
*
|
|
@@ -15420,7 +15360,7 @@ export declare const useSpan: {
|
|
|
15420
15360
|
<A, E, R>(name: string, options: SpanOptionsNoTrace, evaluate: (span: Span) => Effect<A, E, R>): Effect<A, E, R>;
|
|
15421
15361
|
};
|
|
15422
15362
|
/**
|
|
15423
|
-
* Wraps the effect with a
|
|
15363
|
+
* Wraps the effect with a child span for tracing.
|
|
15424
15364
|
*
|
|
15425
15365
|
* **Example** (Wrapping an effect in a child span)
|
|
15426
15366
|
*
|
|
@@ -15442,7 +15382,7 @@ export declare const useSpan: {
|
|
|
15442
15382
|
*/
|
|
15443
15383
|
export declare const withSpan: {
|
|
15444
15384
|
/**
|
|
15445
|
-
* Wraps the effect with a
|
|
15385
|
+
* Wraps the effect with a child span for tracing.
|
|
15446
15386
|
*
|
|
15447
15387
|
* **Example** (Wrapping an effect in a child span)
|
|
15448
15388
|
*
|
|
@@ -15464,7 +15404,7 @@ export declare const withSpan: {
|
|
|
15464
15404
|
*/
|
|
15465
15405
|
<Args extends ReadonlyArray<any>>(name: string, options?: SpanOptionsNoTrace | ((...args: NoInfer<Args>) => SpanOptionsNoTrace) | undefined, traceOptions?: TraceOptions | undefined): <A, E, R>(self: Effect<A, E, R>, ...args: Args) => Effect<A, E, Exclude<R, ParentSpan>>;
|
|
15466
15406
|
/**
|
|
15467
|
-
* Wraps the effect with a
|
|
15407
|
+
* Wraps the effect with a child span for tracing.
|
|
15468
15408
|
*
|
|
15469
15409
|
* **Example** (Wrapping an effect in a child span)
|
|
15470
15410
|
*
|
|
@@ -15487,7 +15427,7 @@ export declare const withSpan: {
|
|
|
15487
15427
|
<A, E, R>(self: Effect<A, E, R>, name: string, options?: SpanOptions | undefined): Effect<A, E, Exclude<R, ParentSpan>>;
|
|
15488
15428
|
};
|
|
15489
15429
|
/**
|
|
15490
|
-
* Wraps the effect with a
|
|
15430
|
+
* Wraps the effect with a scoped child span for tracing.
|
|
15491
15431
|
*
|
|
15492
15432
|
* **Details**
|
|
15493
15433
|
*
|
|
@@ -15512,7 +15452,7 @@ export declare const withSpan: {
|
|
|
15512
15452
|
*/
|
|
15513
15453
|
export declare const withSpanScoped: {
|
|
15514
15454
|
/**
|
|
15515
|
-
* Wraps the effect with a
|
|
15455
|
+
* Wraps the effect with a scoped child span for tracing.
|
|
15516
15456
|
*
|
|
15517
15457
|
* **Details**
|
|
15518
15458
|
*
|
|
@@ -15537,7 +15477,7 @@ export declare const withSpanScoped: {
|
|
|
15537
15477
|
*/
|
|
15538
15478
|
(name: string, options?: SpanOptions): <A, E, R>(self: Effect<A, E, R>) => Effect<A, E, Exclude<R, ParentSpan> | Scope>;
|
|
15539
15479
|
/**
|
|
15540
|
-
* Wraps the effect with a
|
|
15480
|
+
* Wraps the effect with a scoped child span for tracing.
|
|
15541
15481
|
*
|
|
15542
15482
|
* **Details**
|
|
15543
15483
|
*
|
|
@@ -15745,7 +15685,7 @@ export declare const request: {
|
|
|
15745
15685
|
<A extends Request.Any, EX = never, RX = never>(self: A, resolver: RequestResolver<A> | Effect<RequestResolver<A>, EX, RX>): Effect<Request.Success<A>, Request.Error<A> | EX, Request.Services<A> | RX>;
|
|
15746
15686
|
};
|
|
15747
15687
|
/**
|
|
15748
|
-
*
|
|
15688
|
+
* Registers a request with a resolver and delivers the exit value via `onExit`.
|
|
15749
15689
|
*
|
|
15750
15690
|
* **When to use**
|
|
15751
15691
|
*
|
|
@@ -16029,7 +15969,7 @@ export declare const forkDetach: <Arg extends Effect<any, any, any> | {
|
|
|
16029
15969
|
*/
|
|
16030
15970
|
export declare const awaitAllChildren: <A, E, R>(self: Effect<A, E, R>) => Effect<A, E, R>;
|
|
16031
15971
|
/**
|
|
16032
|
-
*
|
|
15972
|
+
* Accesses the fiber currently executing the effect.
|
|
16033
15973
|
*
|
|
16034
15974
|
* **Example** (Accessing the current fiber)
|
|
16035
15975
|
*
|
|
@@ -16047,7 +15987,7 @@ export declare const awaitAllChildren: <A, E, R>(self: Effect<A, E, R>) => Effec
|
|
|
16047
15987
|
*/
|
|
16048
15988
|
export declare const fiber: Effect<Fiber<unknown, unknown>>;
|
|
16049
15989
|
/**
|
|
16050
|
-
*
|
|
15990
|
+
* Accesses the current fiber id executing the effect.
|
|
16051
15991
|
*
|
|
16052
15992
|
* **Example** (Accessing the current fiber id)
|
|
16053
15993
|
*
|
|
@@ -16099,17 +16039,14 @@ export interface RunOptions {
|
|
|
16099
16039
|
readonly onFiberStart?: ((fiber: Fiber<unknown, unknown>) => void) | undefined;
|
|
16100
16040
|
}
|
|
16101
16041
|
/**
|
|
16102
|
-
*
|
|
16042
|
+
* Runs an effect in the background, returning a fiber that can
|
|
16103
16043
|
* be observed or interrupted.
|
|
16104
16044
|
*
|
|
16105
16045
|
* **When to use**
|
|
16106
16046
|
*
|
|
16107
|
-
* Use when
|
|
16108
|
-
*
|
|
16109
|
-
*
|
|
16110
|
-
*
|
|
16111
|
-
* Unless you specifically need a `Promise` or synchronous operation,
|
|
16112
|
-
* `runFork` is a good default choice.
|
|
16047
|
+
* Use when an effect should start in the background and return a fiber that can
|
|
16048
|
+
* be observed or interrupted. Prefer this when you do not need a `Promise` or
|
|
16049
|
+
* synchronous result.
|
|
16113
16050
|
*
|
|
16114
16051
|
* **Example** (Running an effect in the background)
|
|
16115
16052
|
*
|
|
@@ -16412,7 +16349,8 @@ export declare const runPromiseExitWith: <R>(context: Context.Context<R>) => <A,
|
|
|
16412
16349
|
*
|
|
16413
16350
|
* **When to use**
|
|
16414
16351
|
*
|
|
16415
|
-
* Use when you
|
|
16352
|
+
* Use when you need to execute an effect that is guaranteed to complete
|
|
16353
|
+
* synchronously.
|
|
16416
16354
|
*
|
|
16417
16355
|
* **Details**
|
|
16418
16356
|
*
|
|
@@ -16499,7 +16437,7 @@ export declare const runSync: <A, E>(effect: Effect<A, E>) => A;
|
|
|
16499
16437
|
*/
|
|
16500
16438
|
export declare const runSyncWith: <R>(context: Context.Context<R>) => <A, E>(effect: Effect<A, E, R>) => A;
|
|
16501
16439
|
/**
|
|
16502
|
-
* Runs an effect synchronously and
|
|
16440
|
+
* Runs an effect synchronously and captures the outcome safely as an `Exit` type, which
|
|
16503
16441
|
* represents the outcome (success or failure) of the effect.
|
|
16504
16442
|
*
|
|
16505
16443
|
* **When to use**
|
|
@@ -16573,7 +16511,7 @@ export declare const runSyncWith: <R>(context: Context.Context<R>) => <A, E>(eff
|
|
|
16573
16511
|
*/
|
|
16574
16512
|
export declare const runSyncExit: <A, E>(effect: Effect<A, E>) => Exit.Exit<A, E>;
|
|
16575
16513
|
/**
|
|
16576
|
-
* Runs an effect synchronously with provided services, returning an Exit result.
|
|
16514
|
+
* Runs an effect synchronously with provided services, returning an Exit result safely.
|
|
16577
16515
|
*
|
|
16578
16516
|
* **Example** (Running synchronously with services as Exit)
|
|
16579
16517
|
*
|
|
@@ -19030,12 +18968,12 @@ declare const Transaction_base: Context.ServiceClass<Transaction, "effect/Effect
|
|
|
19030
18968
|
}>;
|
|
19031
18969
|
}>;
|
|
19032
18970
|
/**
|
|
19033
|
-
* Service that holds the current transaction state
|
|
18971
|
+
* Service that holds the current transaction state.
|
|
19034
18972
|
*
|
|
19035
18973
|
* **Details**
|
|
19036
18974
|
*
|
|
19037
|
-
*
|
|
19038
|
-
*
|
|
18975
|
+
* It includes a journal that stores non-committed changes to `TxRef` values and
|
|
18976
|
+
* a retry flag that records whether the transaction should be retried.
|
|
19039
18977
|
*
|
|
19040
18978
|
* **Example** (Building transactions)
|
|
19041
18979
|
*
|
|
@@ -19102,7 +19040,7 @@ export declare class Transaction extends Transaction_base {
|
|
|
19102
19040
|
*/
|
|
19103
19041
|
export declare const tx: <A, E, R>(effect: Effect<A, E, R>) => Effect<A, E, Exclude<R, Transaction>>;
|
|
19104
19042
|
/**
|
|
19105
|
-
*
|
|
19043
|
+
* Retries the current transaction by signaling that it must be retried.
|
|
19106
19044
|
*
|
|
19107
19045
|
* **Details**
|
|
19108
19046
|
*
|
|
@@ -19649,14 +19587,12 @@ export declare const satisfiesErrorType: <E>() => <A, E2 extends E, R>(effect: E
|
|
|
19649
19587
|
*/
|
|
19650
19588
|
export declare const satisfiesServicesType: <R>() => <A, E, R2 extends R>(effect: Effect<A, E, R2>) => Effect<A, E, R2>;
|
|
19651
19589
|
/**
|
|
19652
|
-
*
|
|
19653
|
-
* and applies the mapping function eagerly when possible.
|
|
19590
|
+
* Applies `map` eagerly when an effect is already resolved.
|
|
19654
19591
|
*
|
|
19655
19592
|
* **When to use**
|
|
19656
19593
|
*
|
|
19657
|
-
* Use when
|
|
19658
|
-
*
|
|
19659
|
-
* the effect pipeline.
|
|
19594
|
+
* Use when an already-resolved effect should apply a success transformation
|
|
19595
|
+
* immediately while pending effects still use regular mapping.
|
|
19660
19596
|
*
|
|
19661
19597
|
* **Details**
|
|
19662
19598
|
*
|
|
@@ -19685,14 +19621,12 @@ export declare const satisfiesServicesType: <R>() => <A, E, R2 extends R>(effect
|
|
|
19685
19621
|
*/
|
|
19686
19622
|
export declare const mapEager: {
|
|
19687
19623
|
/**
|
|
19688
|
-
*
|
|
19689
|
-
* and applies the mapping function eagerly when possible.
|
|
19624
|
+
* Applies `map` eagerly when an effect is already resolved.
|
|
19690
19625
|
*
|
|
19691
19626
|
* **When to use**
|
|
19692
19627
|
*
|
|
19693
|
-
* Use when
|
|
19694
|
-
*
|
|
19695
|
-
* the effect pipeline.
|
|
19628
|
+
* Use when an already-resolved effect should apply a success transformation
|
|
19629
|
+
* immediately while pending effects still use regular mapping.
|
|
19696
19630
|
*
|
|
19697
19631
|
* **Details**
|
|
19698
19632
|
*
|
|
@@ -19721,14 +19655,12 @@ export declare const mapEager: {
|
|
|
19721
19655
|
*/
|
|
19722
19656
|
<A, B>(f: (a: A) => B): <E, R>(self: Effect<A, E, R>) => Effect<B, E, R>;
|
|
19723
19657
|
/**
|
|
19724
|
-
*
|
|
19725
|
-
* and applies the mapping function eagerly when possible.
|
|
19658
|
+
* Applies `map` eagerly when an effect is already resolved.
|
|
19726
19659
|
*
|
|
19727
19660
|
* **When to use**
|
|
19728
19661
|
*
|
|
19729
|
-
* Use when
|
|
19730
|
-
*
|
|
19731
|
-
* the effect pipeline.
|
|
19662
|
+
* Use when an already-resolved effect should apply a success transformation
|
|
19663
|
+
* immediately while pending effects still use regular mapping.
|
|
19732
19664
|
*
|
|
19733
19665
|
* **Details**
|
|
19734
19666
|
*
|
|
@@ -19758,14 +19690,13 @@ export declare const mapEager: {
|
|
|
19758
19690
|
<A, E, R, B>(self: Effect<A, E, R>, f: (a: A) => B): Effect<B, E, R>;
|
|
19759
19691
|
};
|
|
19760
19692
|
/**
|
|
19761
|
-
*
|
|
19762
|
-
* and applies the error mapping function eagerly when possible.
|
|
19693
|
+
* Applies `mapError` eagerly when an effect is already resolved.
|
|
19763
19694
|
*
|
|
19764
19695
|
* **When to use**
|
|
19765
19696
|
*
|
|
19766
|
-
* Use when
|
|
19767
|
-
*
|
|
19768
|
-
*
|
|
19697
|
+
* Use when an already-resolved failed effect should apply an error
|
|
19698
|
+
* transformation immediately while pending effects still use regular error
|
|
19699
|
+
* mapping.
|
|
19769
19700
|
*
|
|
19770
19701
|
* **Details**
|
|
19771
19702
|
*
|
|
@@ -19797,14 +19728,13 @@ export declare const mapEager: {
|
|
|
19797
19728
|
*/
|
|
19798
19729
|
export declare const mapErrorEager: {
|
|
19799
19730
|
/**
|
|
19800
|
-
*
|
|
19801
|
-
* and applies the error mapping function eagerly when possible.
|
|
19731
|
+
* Applies `mapError` eagerly when an effect is already resolved.
|
|
19802
19732
|
*
|
|
19803
19733
|
* **When to use**
|
|
19804
19734
|
*
|
|
19805
|
-
* Use when
|
|
19806
|
-
*
|
|
19807
|
-
*
|
|
19735
|
+
* Use when an already-resolved failed effect should apply an error
|
|
19736
|
+
* transformation immediately while pending effects still use regular error
|
|
19737
|
+
* mapping.
|
|
19808
19738
|
*
|
|
19809
19739
|
* **Details**
|
|
19810
19740
|
*
|
|
@@ -19836,14 +19766,13 @@ export declare const mapErrorEager: {
|
|
|
19836
19766
|
*/
|
|
19837
19767
|
<E, E2>(f: (e: E) => E2): <A, R>(self: Effect<A, E, R>) => Effect<A, E2, R>;
|
|
19838
19768
|
/**
|
|
19839
|
-
*
|
|
19840
|
-
* and applies the error mapping function eagerly when possible.
|
|
19769
|
+
* Applies `mapError` eagerly when an effect is already resolved.
|
|
19841
19770
|
*
|
|
19842
19771
|
* **When to use**
|
|
19843
19772
|
*
|
|
19844
|
-
* Use when
|
|
19845
|
-
*
|
|
19846
|
-
*
|
|
19773
|
+
* Use when an already-resolved failed effect should apply an error
|
|
19774
|
+
* transformation immediately while pending effects still use regular error
|
|
19775
|
+
* mapping.
|
|
19847
19776
|
*
|
|
19848
19777
|
* **Details**
|
|
19849
19778
|
*
|
|
@@ -19876,14 +19805,12 @@ export declare const mapErrorEager: {
|
|
|
19876
19805
|
<A, E, R, E2>(self: Effect<A, E, R>, f: (e: E) => E2): Effect<A, E2, R>;
|
|
19877
19806
|
};
|
|
19878
19807
|
/**
|
|
19879
|
-
*
|
|
19880
|
-
* and applies the appropriate mapping function eagerly when possible.
|
|
19808
|
+
* Applies `mapBoth` eagerly when an effect is already resolved.
|
|
19881
19809
|
*
|
|
19882
19810
|
* **When to use**
|
|
19883
19811
|
*
|
|
19884
|
-
* Use when
|
|
19885
|
-
*
|
|
19886
|
-
* the effect pipeline.
|
|
19812
|
+
* Use when an already-resolved effect should transform either success or
|
|
19813
|
+
* failure immediately while pending effects still use regular channel mapping.
|
|
19887
19814
|
*
|
|
19888
19815
|
* **Details**
|
|
19889
19816
|
*
|
|
@@ -19917,14 +19844,12 @@ export declare const mapErrorEager: {
|
|
|
19917
19844
|
*/
|
|
19918
19845
|
export declare const mapBothEager: {
|
|
19919
19846
|
/**
|
|
19920
|
-
*
|
|
19921
|
-
* and applies the appropriate mapping function eagerly when possible.
|
|
19847
|
+
* Applies `mapBoth` eagerly when an effect is already resolved.
|
|
19922
19848
|
*
|
|
19923
19849
|
* **When to use**
|
|
19924
19850
|
*
|
|
19925
|
-
* Use when
|
|
19926
|
-
*
|
|
19927
|
-
* the effect pipeline.
|
|
19851
|
+
* Use when an already-resolved effect should transform either success or
|
|
19852
|
+
* failure immediately while pending effects still use regular channel mapping.
|
|
19928
19853
|
*
|
|
19929
19854
|
* **Details**
|
|
19930
19855
|
*
|
|
@@ -19961,14 +19886,12 @@ export declare const mapBothEager: {
|
|
|
19961
19886
|
readonly onSuccess: (a: A) => A2;
|
|
19962
19887
|
}): <R>(self: Effect<A, E, R>) => Effect<A2, E2, R>;
|
|
19963
19888
|
/**
|
|
19964
|
-
*
|
|
19965
|
-
* and applies the appropriate mapping function eagerly when possible.
|
|
19889
|
+
* Applies `mapBoth` eagerly when an effect is already resolved.
|
|
19966
19890
|
*
|
|
19967
19891
|
* **When to use**
|
|
19968
19892
|
*
|
|
19969
|
-
* Use when
|
|
19970
|
-
*
|
|
19971
|
-
* the effect pipeline.
|
|
19893
|
+
* Use when an already-resolved effect should transform either success or
|
|
19894
|
+
* failure immediately while pending effects still use regular channel mapping.
|
|
19972
19895
|
*
|
|
19973
19896
|
* **Details**
|
|
19974
19897
|
*
|
|
@@ -20006,14 +19929,12 @@ export declare const mapBothEager: {
|
|
|
20006
19929
|
}): Effect<A2, E2, R>;
|
|
20007
19930
|
};
|
|
20008
19931
|
/**
|
|
20009
|
-
*
|
|
20010
|
-
* and applies the flatMap function eagerly when possible.
|
|
19932
|
+
* Applies `flatMap` eagerly when an effect is already resolved.
|
|
20011
19933
|
*
|
|
20012
19934
|
* **When to use**
|
|
20013
19935
|
*
|
|
20014
|
-
* Use when
|
|
20015
|
-
*
|
|
20016
|
-
* the effect pipeline.
|
|
19936
|
+
* Use when an already-resolved successful effect should bind immediately to the
|
|
19937
|
+
* next effect while pending effects still use regular flat mapping.
|
|
20017
19938
|
*
|
|
20018
19939
|
* **Details**
|
|
20019
19940
|
*
|
|
@@ -20045,14 +19966,12 @@ export declare const mapBothEager: {
|
|
|
20045
19966
|
*/
|
|
20046
19967
|
export declare const flatMapEager: {
|
|
20047
19968
|
/**
|
|
20048
|
-
*
|
|
20049
|
-
* and applies the flatMap function eagerly when possible.
|
|
19969
|
+
* Applies `flatMap` eagerly when an effect is already resolved.
|
|
20050
19970
|
*
|
|
20051
19971
|
* **When to use**
|
|
20052
19972
|
*
|
|
20053
|
-
* Use when
|
|
20054
|
-
*
|
|
20055
|
-
* the effect pipeline.
|
|
19973
|
+
* Use when an already-resolved successful effect should bind immediately to the
|
|
19974
|
+
* next effect while pending effects still use regular flat mapping.
|
|
20056
19975
|
*
|
|
20057
19976
|
* **Details**
|
|
20058
19977
|
*
|
|
@@ -20084,14 +20003,12 @@ export declare const flatMapEager: {
|
|
|
20084
20003
|
*/
|
|
20085
20004
|
<A, B, E2, R2>(f: (a: A) => Effect<B, E2, R2>): <E, R>(self: Effect<A, E, R>) => Effect<B, E | E2, R | R2>;
|
|
20086
20005
|
/**
|
|
20087
|
-
*
|
|
20088
|
-
* and applies the flatMap function eagerly when possible.
|
|
20006
|
+
* Applies `flatMap` eagerly when an effect is already resolved.
|
|
20089
20007
|
*
|
|
20090
20008
|
* **When to use**
|
|
20091
20009
|
*
|
|
20092
|
-
* Use when
|
|
20093
|
-
*
|
|
20094
|
-
* the effect pipeline.
|
|
20010
|
+
* Use when an already-resolved successful effect should bind immediately to the
|
|
20011
|
+
* next effect while pending effects still use regular flat mapping.
|
|
20095
20012
|
*
|
|
20096
20013
|
* **Details**
|
|
20097
20014
|
*
|
|
@@ -20124,14 +20041,12 @@ export declare const flatMapEager: {
|
|
|
20124
20041
|
<A, E, R, B, E2, R2>(self: Effect<A, E, R>, f: (a: A) => Effect<B, E2, R2>): Effect<B, E | E2, R | R2>;
|
|
20125
20042
|
};
|
|
20126
20043
|
/**
|
|
20127
|
-
*
|
|
20128
|
-
* and applies the catch function eagerly when possible.
|
|
20044
|
+
* Applies `catch` eagerly when an effect is already resolved.
|
|
20129
20045
|
*
|
|
20130
20046
|
* **When to use**
|
|
20131
20047
|
*
|
|
20132
|
-
* Use when
|
|
20133
|
-
*
|
|
20134
|
-
* the effect pipeline.
|
|
20048
|
+
* Use when an already-resolved failed effect should recover immediately while
|
|
20049
|
+
* pending effects still use regular error recovery.
|
|
20135
20050
|
*
|
|
20136
20051
|
* **Details**
|
|
20137
20052
|
*
|
|
@@ -20173,14 +20088,12 @@ export declare const flatMapEager: {
|
|
|
20173
20088
|
*/
|
|
20174
20089
|
export declare const catchEager: {
|
|
20175
20090
|
/**
|
|
20176
|
-
*
|
|
20177
|
-
* and applies the catch function eagerly when possible.
|
|
20091
|
+
* Applies `catch` eagerly when an effect is already resolved.
|
|
20178
20092
|
*
|
|
20179
20093
|
* **When to use**
|
|
20180
20094
|
*
|
|
20181
|
-
* Use when
|
|
20182
|
-
*
|
|
20183
|
-
* the effect pipeline.
|
|
20095
|
+
* Use when an already-resolved failed effect should recover immediately while
|
|
20096
|
+
* pending effects still use regular error recovery.
|
|
20184
20097
|
*
|
|
20185
20098
|
* **Details**
|
|
20186
20099
|
*
|
|
@@ -20222,14 +20135,12 @@ export declare const catchEager: {
|
|
|
20222
20135
|
*/
|
|
20223
20136
|
<E, B, E2, R2>(f: (e: NoInfer<E>) => Effect<B, E2, R2>): <A, R>(self: Effect<A, E, R>) => Effect<A | B, E2, R | R2>;
|
|
20224
20137
|
/**
|
|
20225
|
-
*
|
|
20226
|
-
* and applies the catch function eagerly when possible.
|
|
20138
|
+
* Applies `catch` eagerly when an effect is already resolved.
|
|
20227
20139
|
*
|
|
20228
20140
|
* **When to use**
|
|
20229
20141
|
*
|
|
20230
|
-
* Use when
|
|
20231
|
-
*
|
|
20232
|
-
* the effect pipeline.
|
|
20142
|
+
* Use when an already-resolved failed effect should recover immediately while
|
|
20143
|
+
* pending effects still use regular error recovery.
|
|
20233
20144
|
*
|
|
20234
20145
|
* **Details**
|
|
20235
20146
|
*
|