effect 4.0.0-beta.73 → 4.0.0-beta.74
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 +16 -16
- package/dist/Array.js +4 -4
- package/dist/Boolean.d.ts +2 -2
- package/dist/Boolean.js +2 -2
- package/dist/Channel.d.ts +63 -63
- package/dist/Channel.js +25 -25
- package/dist/Chunk.d.ts +17 -17
- package/dist/Chunk.js +5 -5
- package/dist/Context.d.ts +3 -3
- package/dist/Context.js +1 -1
- package/dist/Cron.d.ts +4 -4
- package/dist/Cron.js +4 -4
- package/dist/Deferred.d.ts +37 -37
- package/dist/Deferred.js +13 -13
- package/dist/Duration.d.ts +6 -6
- package/dist/Duration.js +2 -2
- package/dist/Effect.d.ts +58 -58
- package/dist/Effect.js +39 -39
- package/dist/Equal.d.ts +2 -2
- package/dist/Equal.js +2 -2
- package/dist/Equivalence.d.ts +1 -1
- package/dist/Equivalence.js +1 -1
- package/dist/ExecutionPlan.d.ts +2 -2
- package/dist/ExecutionPlan.js +1 -1
- package/dist/FileSystem.d.ts +6 -6
- package/dist/FileSystem.js +2 -2
- package/dist/Function.d.ts +5 -5
- package/dist/Function.js +5 -5
- package/dist/Graph.d.ts +11 -11
- package/dist/Graph.js +5 -5
- package/dist/HKT.d.ts +1 -1
- package/dist/HashMap.d.ts +3 -3
- package/dist/HashSet.d.ts +1 -1
- package/dist/Iterable.d.ts +15 -15
- package/dist/Iterable.js +5 -5
- package/dist/Layer.d.ts +16 -16
- package/dist/Layer.js +5 -5
- package/dist/Logger.d.ts +5 -5
- package/dist/Logger.js +4 -4
- package/dist/ManagedRuntime.d.ts +2 -2
- package/dist/Match.d.ts +20 -20
- package/dist/Match.js +16 -16
- package/dist/Metric.d.ts +16 -16
- package/dist/Metric.js +3 -3
- package/dist/Option.d.ts +36 -36
- package/dist/Option.js +17 -17
- package/dist/Order.d.ts +1 -1
- package/dist/Order.js +1 -1
- package/dist/Path.d.ts +1 -1
- package/dist/Path.js +1 -1
- package/dist/Pipeable.d.ts +1 -1
- package/dist/Pipeable.js +1 -1
- package/dist/Predicate.d.ts +5 -5
- package/dist/PubSub.d.ts +9 -9
- package/dist/PubSub.js +5 -5
- package/dist/Queue.d.ts +24 -24
- package/dist/Queue.js +20 -20
- package/dist/Record.d.ts +15 -15
- package/dist/Record.js +5 -5
- package/dist/Redacted.d.ts +2 -2
- package/dist/Redacted.js +1 -1
- package/dist/Ref.d.ts +6 -6
- package/dist/Ref.js +6 -6
- package/dist/RegExp.d.ts +1 -1
- package/dist/RegExp.js +1 -1
- package/dist/Request.d.ts +4 -4
- package/dist/RequestResolver.d.ts +6 -6
- package/dist/RequestResolver.js +2 -2
- package/dist/Resource.d.ts +1 -1
- package/dist/Resource.js +1 -1
- package/dist/Result.d.ts +18 -18
- package/dist/Result.js +11 -11
- package/dist/Schedule.d.ts +44 -44
- package/dist/Schedule.js +18 -18
- package/dist/Schema.d.ts +177 -459
- package/dist/Schema.d.ts.map +1 -1
- package/dist/Schema.js +25 -25
- package/dist/Schema.js.map +1 -1
- package/dist/SchemaAST.d.ts +1 -1
- package/dist/SchemaGetter.d.ts +13 -13
- package/dist/SchemaGetter.js +12 -12
- package/dist/SchemaParser.d.ts +3 -3
- package/dist/SchemaParser.js +3 -3
- package/dist/Scope.d.ts +1 -1
- package/dist/Scope.js +1 -1
- package/dist/Sink.d.ts +5 -5
- package/dist/Sink.js +3 -3
- package/dist/Stream.d.ts +55 -55
- package/dist/Stream.js +21 -21
- package/dist/String.d.ts +5 -5
- package/dist/String.js +3 -3
- package/dist/Struct.d.ts +8 -8
- package/dist/Struct.js +3 -3
- package/dist/SynchronizedRef.d.ts +57 -57
- package/dist/SynchronizedRef.js +19 -19
- package/dist/Terminal.d.ts +1 -1
- package/dist/Terminal.js +1 -1
- package/dist/Tracer.d.ts +5 -5
- package/dist/Tracer.js +2 -2
- package/dist/Tuple.d.ts +14 -14
- package/dist/Tuple.js +6 -6
- package/dist/TxHashMap.d.ts +3 -3
- package/dist/TxHashSet.d.ts +1 -1
- package/dist/Unify.d.ts +7 -7
- package/dist/Unify.js +1 -1
- package/dist/testing/TestClock.d.ts +5 -5
- package/dist/testing/TestClock.js +4 -4
- package/dist/testing/TestConsole.d.ts +3 -3
- package/dist/testing/TestConsole.js +3 -3
- package/dist/unstable/ai/Chat.d.ts +2 -2
- package/dist/unstable/ai/Chat.js +2 -2
- package/dist/unstable/ai/EmbeddingModel.d.ts +1 -1
- package/dist/unstable/ai/IdGenerator.d.ts +2 -2
- package/dist/unstable/ai/IdGenerator.js +1 -1
- package/dist/unstable/ai/LanguageModel.d.ts +4 -4
- package/dist/unstable/ai/LanguageModel.js +1 -1
- package/dist/unstable/ai/Prompt.d.ts +15 -15
- package/dist/unstable/ai/Prompt.js +1 -1
- package/dist/unstable/ai/Telemetry.d.ts +5 -5
- package/dist/unstable/ai/Telemetry.js +2 -2
- package/dist/unstable/ai/Tokenizer.d.ts +1 -1
- package/dist/unstable/ai/Tokenizer.js +1 -1
- package/dist/unstable/ai/Tool.d.ts +6 -6
- package/dist/unstable/ai/Tool.js +6 -6
- package/dist/unstable/cli/Command.d.ts.map +1 -1
- package/dist/unstable/cli/Command.js +1 -1
- package/dist/unstable/cli/Command.js.map +1 -1
- package/dist/unstable/cli/Param.d.ts +1 -1
- package/dist/unstable/cli/Primitive.d.ts +3 -3
- package/dist/unstable/cli/Primitive.js +1 -1
- package/dist/unstable/cli/Prompt.d.ts +11 -11
- package/dist/unstable/cli/internal/parser.js +145 -10
- package/dist/unstable/cli/internal/parser.js.map +1 -1
- package/dist/unstable/cluster/Entity.d.ts +1 -1
- package/dist/unstable/cluster/Entity.js +1 -1
- package/dist/unstable/cluster/HttpRunner.d.ts +2 -2
- package/dist/unstable/cluster/HttpRunner.js +2 -2
- package/dist/unstable/cluster/K8sHttpClient.d.ts +1 -1
- package/dist/unstable/cluster/K8sHttpClient.js +1 -1
- package/dist/unstable/cluster/Runners.d.ts +1 -1
- package/dist/unstable/cluster/Runners.js +1 -1
- package/dist/unstable/cluster/Sharding.d.ts +1 -1
- package/dist/unstable/cluster/Sharding.js +1 -1
- package/dist/unstable/cluster/SingletonAddress.d.ts +1 -1
- package/dist/unstable/cluster/SingletonAddress.js +1 -1
- package/dist/unstable/cluster/Snowflake.d.ts +5 -5
- package/dist/unstable/cluster/Snowflake.js +5 -5
- package/dist/unstable/devtools/DevToolsClient.d.ts +1 -1
- package/dist/unstable/devtools/DevToolsClient.js +1 -1
- package/dist/unstable/eventlog/EventLog.d.ts +1 -1
- package/dist/unstable/eventlog/EventLog.js +1 -1
- package/dist/unstable/eventlog/EventLogEncryption.d.ts +1 -1
- package/dist/unstable/eventlog/EventLogEncryption.js +1 -1
- package/dist/unstable/eventlog/EventLogRemote.d.ts +1 -1
- package/dist/unstable/eventlog/EventLogRemote.js +1 -1
- package/dist/unstable/eventlog/EventLogServerUnencrypted.d.ts +3 -3
- package/dist/unstable/eventlog/EventLogServerUnencrypted.js +3 -3
- package/dist/unstable/http/Cookies.d.ts +1 -1
- package/dist/unstable/http/Etag.d.ts +1 -1
- package/dist/unstable/http/Etag.js +1 -1
- package/dist/unstable/http/FetchHttpClient.d.ts +2 -2
- package/dist/unstable/http/FetchHttpClient.js +2 -2
- package/dist/unstable/http/HttpClient.d.ts +1 -1
- package/dist/unstable/http/HttpClient.js +1 -1
- package/dist/unstable/http/HttpClientRequest.d.ts +2 -2
- package/dist/unstable/http/HttpMiddleware.d.ts +1 -1
- package/dist/unstable/http/HttpMiddleware.js +1 -1
- package/dist/unstable/http/HttpPlatform.d.ts +1 -1
- package/dist/unstable/http/HttpPlatform.js +1 -1
- package/dist/unstable/http/HttpRouter.d.ts +4 -4
- package/dist/unstable/http/HttpRouter.js +4 -4
- package/dist/unstable/http/HttpServerResponse.d.ts +3 -3
- package/dist/unstable/http/Url.d.ts +33 -33
- package/dist/unstable/http/Url.js +11 -11
- package/dist/unstable/httpapi/HttpApi.d.ts +1 -1
- package/dist/unstable/httpapi/HttpApi.js +1 -1
- package/dist/unstable/httpapi/HttpApiError.d.ts +13 -13
- package/dist/unstable/httpapi/HttpApiError.js +13 -13
- package/dist/unstable/observability/PrometheusMetrics.d.ts +4 -4
- package/dist/unstable/observability/PrometheusMetrics.js +2 -2
- package/dist/unstable/persistence/KeyValueStore.d.ts +3 -3
- package/dist/unstable/persistence/KeyValueStore.js +1 -1
- package/dist/unstable/persistence/Persistable.d.ts +2 -2
- package/dist/unstable/persistence/Persistable.js +2 -2
- package/dist/unstable/persistence/PersistedQueue.d.ts +8 -8
- package/dist/unstable/persistence/PersistedQueue.js +8 -8
- package/dist/unstable/persistence/RateLimiter.d.ts +1 -1
- package/dist/unstable/persistence/RateLimiter.js +1 -1
- package/dist/unstable/process/ChildProcess.d.ts +5 -5
- package/dist/unstable/process/ChildProcess.js +2 -2
- package/dist/unstable/reactivity/AsyncResult.d.ts +4 -4
- package/dist/unstable/reactivity/AsyncResult.js +1 -1
- package/dist/unstable/reactivity/Atom.d.ts +1 -1
- package/dist/unstable/reactivity/Atom.js +1 -1
- package/dist/unstable/reactivity/AtomRegistry.d.ts +1 -1
- package/dist/unstable/reactivity/AtomRegistry.js +1 -1
- package/dist/unstable/reactivity/Reactivity.d.ts +1 -1
- package/dist/unstable/reactivity/Reactivity.js +1 -1
- package/dist/unstable/rpc/Rpc.d.ts +5 -5
- package/dist/unstable/rpc/Rpc.js +1 -1
- package/dist/unstable/rpc/RpcMiddleware.d.ts +1 -1
- package/dist/unstable/rpc/RpcMiddleware.js +1 -1
- package/dist/unstable/rpc/RpcSchema.d.ts +3 -3
- package/dist/unstable/rpc/RpcSchema.js +2 -2
- package/dist/unstable/schema/Model.d.ts +2 -2
- package/dist/unstable/schema/Model.js +1 -1
- package/dist/unstable/socket/Socket.d.ts +3 -3
- package/dist/unstable/socket/Socket.js +3 -3
- package/dist/unstable/socket/SocketServer.d.ts +1 -1
- package/dist/unstable/socket/SocketServer.js +1 -1
- package/dist/unstable/sql/Migrator.d.ts +1 -1
- package/dist/unstable/sql/SqlClient.d.ts +3 -3
- package/dist/unstable/sql/SqlClient.js +2 -2
- package/dist/unstable/sql/SqlConnection.d.ts +1 -1
- package/dist/unstable/sql/SqlConnection.js +1 -1
- package/dist/unstable/sql/Statement.d.ts +2 -2
- package/dist/unstable/sql/Statement.js +2 -2
- package/dist/unstable/workers/Transferable.d.ts +1 -1
- package/dist/unstable/workers/Transferable.js +1 -1
- package/dist/unstable/workers/Worker.d.ts +1 -1
- package/dist/unstable/workers/Worker.js +1 -1
- package/dist/unstable/workflow/Activity.d.ts +1 -1
- package/dist/unstable/workflow/Activity.js +1 -1
- package/dist/unstable/workflow/DurableDeferred.d.ts +1 -1
- package/dist/unstable/workflow/DurableDeferred.js +1 -1
- package/package.json +1 -1
- package/src/Array.ts +16 -16
- package/src/Boolean.ts +2 -2
- package/src/Channel.ts +67 -67
- package/src/Chunk.ts +18 -18
- package/src/Context.ts +4 -4
- package/src/Cron.ts +4 -4
- package/src/Deferred.ts +37 -37
- package/src/Duration.ts +6 -6
- package/src/Effect.ts +58 -58
- package/src/Equal.ts +2 -2
- package/src/Equivalence.ts +1 -1
- package/src/ExecutionPlan.ts +2 -2
- package/src/FileSystem.ts +6 -6
- package/src/Function.ts +5 -5
- package/src/Graph.ts +11 -11
- package/src/HKT.ts +1 -1
- package/src/HashMap.ts +3 -3
- package/src/HashSet.ts +1 -1
- package/src/Iterable.ts +15 -15
- package/src/Layer.ts +16 -16
- package/src/Logger.ts +7 -7
- package/src/ManagedRuntime.ts +2 -2
- package/src/Match.ts +20 -20
- package/src/Metric.ts +20 -20
- package/src/Option.ts +36 -36
- package/src/Order.ts +1 -1
- package/src/Path.ts +1 -1
- package/src/Pipeable.ts +1 -1
- package/src/Predicate.ts +5 -5
- package/src/PubSub.ts +9 -9
- package/src/Queue.ts +24 -24
- package/src/Record.ts +15 -15
- package/src/Redacted.ts +2 -2
- package/src/Ref.ts +18 -18
- package/src/RegExp.ts +1 -1
- package/src/Request.ts +4 -4
- package/src/RequestResolver.ts +8 -8
- package/src/Resource.ts +1 -1
- package/src/Result.ts +18 -18
- package/src/Schedule.ts +45 -45
- package/src/Schema.ts +177 -459
- package/src/SchemaAST.ts +1 -1
- package/src/SchemaGetter.ts +13 -13
- package/src/SchemaParser.ts +3 -3
- package/src/Scope.ts +1 -1
- package/src/Sink.ts +5 -5
- package/src/Stream.ts +57 -57
- package/src/String.ts +5 -5
- package/src/Struct.ts +8 -8
- package/src/SynchronizedRef.ts +57 -57
- package/src/Terminal.ts +1 -1
- package/src/Tracer.ts +5 -5
- package/src/Tuple.ts +14 -14
- package/src/TxHashMap.ts +3 -3
- package/src/TxHashSet.ts +1 -1
- package/src/Unify.ts +7 -7
- package/src/testing/TestClock.ts +5 -5
- package/src/testing/TestConsole.ts +3 -3
- package/src/unstable/ai/Chat.ts +2 -2
- package/src/unstable/ai/EmbeddingModel.ts +1 -1
- package/src/unstable/ai/IdGenerator.ts +2 -2
- package/src/unstable/ai/LanguageModel.ts +4 -4
- package/src/unstable/ai/Prompt.ts +15 -15
- package/src/unstable/ai/Telemetry.ts +5 -5
- package/src/unstable/ai/Tokenizer.ts +1 -1
- package/src/unstable/ai/Tool.ts +6 -6
- package/src/unstable/cli/Command.ts +5 -1
- package/src/unstable/cli/Param.ts +1 -1
- package/src/unstable/cli/Primitive.ts +3 -3
- package/src/unstable/cli/Prompt.ts +11 -11
- package/src/unstable/cli/internal/parser.ts +204 -10
- package/src/unstable/cluster/Entity.ts +1 -1
- package/src/unstable/cluster/HttpRunner.ts +2 -2
- package/src/unstable/cluster/K8sHttpClient.ts +1 -1
- package/src/unstable/cluster/Runners.ts +1 -1
- package/src/unstable/cluster/Sharding.ts +1 -1
- package/src/unstable/cluster/SingletonAddress.ts +1 -1
- package/src/unstable/cluster/Snowflake.ts +5 -5
- package/src/unstable/devtools/DevToolsClient.ts +1 -1
- package/src/unstable/eventlog/EventLog.ts +1 -1
- package/src/unstable/eventlog/EventLogEncryption.ts +1 -1
- package/src/unstable/eventlog/EventLogRemote.ts +1 -1
- package/src/unstable/eventlog/EventLogServerUnencrypted.ts +3 -3
- package/src/unstable/http/Cookies.ts +1 -1
- package/src/unstable/http/Etag.ts +1 -1
- package/src/unstable/http/FetchHttpClient.ts +2 -2
- package/src/unstable/http/HttpClient.ts +1 -1
- package/src/unstable/http/HttpClientRequest.ts +2 -2
- package/src/unstable/http/HttpMiddleware.ts +1 -1
- package/src/unstable/http/HttpPlatform.ts +1 -1
- package/src/unstable/http/HttpRouter.ts +4 -4
- package/src/unstable/http/HttpServerResponse.ts +3 -3
- package/src/unstable/http/Url.ts +33 -33
- package/src/unstable/httpapi/HttpApi.ts +1 -1
- package/src/unstable/httpapi/HttpApiError.ts +13 -13
- package/src/unstable/observability/PrometheusMetrics.ts +4 -4
- package/src/unstable/persistence/KeyValueStore.ts +3 -3
- package/src/unstable/persistence/Persistable.ts +2 -2
- package/src/unstable/persistence/PersistedQueue.ts +8 -8
- package/src/unstable/persistence/RateLimiter.ts +1 -1
- package/src/unstable/process/ChildProcess.ts +5 -5
- package/src/unstable/reactivity/AsyncResult.ts +4 -4
- package/src/unstable/reactivity/Atom.ts +1 -1
- package/src/unstable/reactivity/AtomRegistry.ts +1 -1
- package/src/unstable/reactivity/Reactivity.ts +1 -1
- package/src/unstable/rpc/Rpc.ts +5 -5
- package/src/unstable/rpc/RpcMiddleware.ts +1 -1
- package/src/unstable/rpc/RpcSchema.ts +3 -3
- package/src/unstable/schema/Model.ts +2 -2
- package/src/unstable/socket/Socket.ts +3 -3
- package/src/unstable/socket/SocketServer.ts +1 -1
- package/src/unstable/sql/Migrator.ts +1 -1
- package/src/unstable/sql/SqlClient.ts +3 -3
- package/src/unstable/sql/SqlConnection.ts +1 -1
- package/src/unstable/sql/Statement.ts +2 -2
- package/src/unstable/workers/Transferable.ts +1 -1
- package/src/unstable/workers/Worker.ts +1 -1
- package/src/unstable/workflow/Activity.ts +1 -1
- package/src/unstable/workflow/DurableDeferred.ts +1 -1
package/dist/Schedule.d.ts
CHANGED
|
@@ -474,7 +474,7 @@ export declare const toStepWithSleep: <Output, Input, Error, Env>(schedule: Sche
|
|
|
474
474
|
* })
|
|
475
475
|
* ```
|
|
476
476
|
*
|
|
477
|
-
* @category
|
|
477
|
+
* @category delays & timeouts
|
|
478
478
|
* @since 2.0.0
|
|
479
479
|
*/
|
|
480
480
|
export declare const addDelay: {
|
|
@@ -574,7 +574,7 @@ export declare const addDelay: {
|
|
|
574
574
|
* })
|
|
575
575
|
* ```
|
|
576
576
|
*
|
|
577
|
-
* @category
|
|
577
|
+
* @category delays & timeouts
|
|
578
578
|
* @since 2.0.0
|
|
579
579
|
*/
|
|
580
580
|
<Output, Error2 = never, Env2 = never>(f: (output: Output) => Effect<Duration.Input, Error2, Env2>): <Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output, Input, Error | Error2, Env | Env2>;
|
|
@@ -674,7 +674,7 @@ export declare const addDelay: {
|
|
|
674
674
|
* })
|
|
675
675
|
* ```
|
|
676
676
|
*
|
|
677
|
-
* @category
|
|
677
|
+
* @category delays & timeouts
|
|
678
678
|
* @since 2.0.0
|
|
679
679
|
*/
|
|
680
680
|
<Output, Input, Error, Env, Error2 = never, Env2 = never>(self: Schedule<Output, Input, Error, Env>, f: (output: Output) => Effect<Duration.Input, Error2, Env2>): Schedule<Output, Input, Error | Error2, Env | Env2>;
|
|
@@ -1008,7 +1008,7 @@ export declare const andThenResult: {
|
|
|
1008
1008
|
*
|
|
1009
1009
|
* @see {@link either} for continuing while either schedule still recurs
|
|
1010
1010
|
*
|
|
1011
|
-
* @category
|
|
1011
|
+
* @category combining
|
|
1012
1012
|
* @since 2.0.0
|
|
1013
1013
|
*/
|
|
1014
1014
|
export declare const both: {
|
|
@@ -1087,7 +1087,7 @@ export declare const both: {
|
|
|
1087
1087
|
*
|
|
1088
1088
|
* @see {@link either} for continuing while either schedule still recurs
|
|
1089
1089
|
*
|
|
1090
|
-
* @category
|
|
1090
|
+
* @category combining
|
|
1091
1091
|
* @since 2.0.0
|
|
1092
1092
|
*/
|
|
1093
1093
|
<Output2, Input2, Error2, Env2, Output>(other: Schedule<Output2, Input2, Error2, Env2>): <Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<[Output, Output2], Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -1166,7 +1166,7 @@ export declare const both: {
|
|
|
1166
1166
|
*
|
|
1167
1167
|
* @see {@link either} for continuing while either schedule still recurs
|
|
1168
1168
|
*
|
|
1169
|
-
* @category
|
|
1169
|
+
* @category combining
|
|
1170
1170
|
* @since 2.0.0
|
|
1171
1171
|
*/
|
|
1172
1172
|
<Output, Input, Error, Env, Output2, Input2, Error2, Env2>(self: Schedule<Output, Input, Error, Env>, other: Schedule<Output2, Input2, Error2, Env2>): Schedule<[Output, Output2], Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -1200,7 +1200,7 @@ export declare const both: {
|
|
|
1200
1200
|
* })
|
|
1201
1201
|
* ```
|
|
1202
1202
|
*
|
|
1203
|
-
* @category
|
|
1203
|
+
* @category combining
|
|
1204
1204
|
* @since 2.0.0
|
|
1205
1205
|
*/
|
|
1206
1206
|
export declare const bothLeft: {
|
|
@@ -1233,7 +1233,7 @@ export declare const bothLeft: {
|
|
|
1233
1233
|
* })
|
|
1234
1234
|
* ```
|
|
1235
1235
|
*
|
|
1236
|
-
* @category
|
|
1236
|
+
* @category combining
|
|
1237
1237
|
* @since 2.0.0
|
|
1238
1238
|
*/
|
|
1239
1239
|
<Output2, Input2, Error2, Env2>(other: Schedule<Output2, Input2, Error2, Env2>): <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -1266,7 +1266,7 @@ export declare const bothLeft: {
|
|
|
1266
1266
|
* })
|
|
1267
1267
|
* ```
|
|
1268
1268
|
*
|
|
1269
|
-
* @category
|
|
1269
|
+
* @category combining
|
|
1270
1270
|
* @since 2.0.0
|
|
1271
1271
|
*/
|
|
1272
1272
|
<Output, Input, Error, Env, Output2, Input2, Error2, Env2>(self: Schedule<Output, Input, Error, Env>, other: Schedule<Output2, Input2, Error2, Env2>): Schedule<Output, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -1302,7 +1302,7 @@ export declare const bothLeft: {
|
|
|
1302
1302
|
* })
|
|
1303
1303
|
* ```
|
|
1304
1304
|
*
|
|
1305
|
-
* @category
|
|
1305
|
+
* @category combining
|
|
1306
1306
|
* @since 2.0.0
|
|
1307
1307
|
*/
|
|
1308
1308
|
export declare const bothRight: {
|
|
@@ -1337,7 +1337,7 @@ export declare const bothRight: {
|
|
|
1337
1337
|
* })
|
|
1338
1338
|
* ```
|
|
1339
1339
|
*
|
|
1340
|
-
* @category
|
|
1340
|
+
* @category combining
|
|
1341
1341
|
* @since 2.0.0
|
|
1342
1342
|
*/
|
|
1343
1343
|
<Output2, Input2, Error2, Env2>(other: Schedule<Output2, Input2, Error2, Env2>): <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -1372,7 +1372,7 @@ export declare const bothRight: {
|
|
|
1372
1372
|
* })
|
|
1373
1373
|
* ```
|
|
1374
1374
|
*
|
|
1375
|
-
* @category
|
|
1375
|
+
* @category combining
|
|
1376
1376
|
* @since 2.0.0
|
|
1377
1377
|
*/
|
|
1378
1378
|
<Output, Input, Error, Env, Output2, Input2, Error2, Env2>(self: Schedule<Output, Input, Error, Env>, other: Schedule<Output2, Input2, Error2, Env2>): Schedule<Output, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -1413,7 +1413,7 @@ export declare const bothRight: {
|
|
|
1413
1413
|
* })
|
|
1414
1414
|
* ```
|
|
1415
1415
|
*
|
|
1416
|
-
* @category
|
|
1416
|
+
* @category combining
|
|
1417
1417
|
* @since 2.0.0
|
|
1418
1418
|
*/
|
|
1419
1419
|
export declare const bothWith: {
|
|
@@ -1453,7 +1453,7 @@ export declare const bothWith: {
|
|
|
1453
1453
|
* })
|
|
1454
1454
|
* ```
|
|
1455
1455
|
*
|
|
1456
|
-
* @category
|
|
1456
|
+
* @category combining
|
|
1457
1457
|
* @since 2.0.0
|
|
1458
1458
|
*/
|
|
1459
1459
|
<Output2, Input2, Error2, Env2, Output, Output3>(other: Schedule<Output2, Input2, Error2, Env2>, combine: (selfOutput: Output, otherOutput: Output2) => Output3): <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output3, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -1493,7 +1493,7 @@ export declare const bothWith: {
|
|
|
1493
1493
|
* })
|
|
1494
1494
|
* ```
|
|
1495
1495
|
*
|
|
1496
|
-
* @category
|
|
1496
|
+
* @category combining
|
|
1497
1497
|
* @since 2.0.0
|
|
1498
1498
|
*/
|
|
1499
1499
|
<Output, Input, Error, Env, Output2, Input2, Error2, Env2, Output3>(self: Schedule<Output, Input, Error, Env>, other: Schedule<Output2, Input2, Error2, Env2>, combine: (selfOutput: Output, otherOutput: Output2) => Output3): Schedule<Output3, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -1530,7 +1530,7 @@ export declare const bothWith: {
|
|
|
1530
1530
|
* })
|
|
1531
1531
|
* ```
|
|
1532
1532
|
*
|
|
1533
|
-
* @category
|
|
1533
|
+
* @category collecting
|
|
1534
1534
|
* @since 4.0.0
|
|
1535
1535
|
*/
|
|
1536
1536
|
export declare const collectInputs: <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Array<Input>, Input, Error, Env>;
|
|
@@ -1564,7 +1564,7 @@ export declare const collectInputs: <Output, Input, Error, Env>(self: Schedule<O
|
|
|
1564
1564
|
* })
|
|
1565
1565
|
* ```
|
|
1566
1566
|
*
|
|
1567
|
-
* @category
|
|
1567
|
+
* @category collecting
|
|
1568
1568
|
* @since 4.0.0
|
|
1569
1569
|
*/
|
|
1570
1570
|
export declare const collectOutputs: <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Array<Output>, Input, Error, Env>;
|
|
@@ -1648,7 +1648,7 @@ export declare const collectOutputs: <Output, Input, Error, Env>(self: Schedule<
|
|
|
1648
1648
|
* })
|
|
1649
1649
|
* ```
|
|
1650
1650
|
*
|
|
1651
|
-
* @category
|
|
1651
|
+
* @category collecting
|
|
1652
1652
|
* @since 2.0.0
|
|
1653
1653
|
*/
|
|
1654
1654
|
export declare const collectWhile: {
|
|
@@ -1732,7 +1732,7 @@ export declare const collectWhile: {
|
|
|
1732
1732
|
* })
|
|
1733
1733
|
* ```
|
|
1734
1734
|
*
|
|
1735
|
-
* @category
|
|
1735
|
+
* @category collecting
|
|
1736
1736
|
* @since 2.0.0
|
|
1737
1737
|
*/
|
|
1738
1738
|
<Input, Output, Error2 = never, Env2 = never>(predicate: (metadata: Metadata<Output, Input>) => boolean | Effect<boolean, Error2, Env2>): <Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Array<Output>, Input, Error | Error2, Env | Env2>;
|
|
@@ -1816,7 +1816,7 @@ export declare const collectWhile: {
|
|
|
1816
1816
|
* })
|
|
1817
1817
|
* ```
|
|
1818
1818
|
*
|
|
1819
|
-
* @category
|
|
1819
|
+
* @category collecting
|
|
1820
1820
|
* @since 2.0.0
|
|
1821
1821
|
*/
|
|
1822
1822
|
<Output, Input, Error, Env, Error2 = never, Env2 = never>(self: Schedule<Output, Input, Error, Env>, predicate: (metadata: Metadata<Output, Input>) => boolean | Effect<boolean, Error2, Env2>): Schedule<Array<Output>, Input, Error | Error2, Env | Env2>;
|
|
@@ -2502,7 +2502,7 @@ export declare const during: (duration: Duration.Input) => Schedule<Duration.Dur
|
|
|
2502
2502
|
*
|
|
2503
2503
|
* @see {@link both} for continuing only while both schedules still recur
|
|
2504
2504
|
*
|
|
2505
|
-
* @category
|
|
2505
|
+
* @category combining
|
|
2506
2506
|
* @since 2.0.0
|
|
2507
2507
|
*/
|
|
2508
2508
|
export declare const either: {
|
|
@@ -2582,7 +2582,7 @@ export declare const either: {
|
|
|
2582
2582
|
*
|
|
2583
2583
|
* @see {@link both} for continuing only while both schedules still recur
|
|
2584
2584
|
*
|
|
2585
|
-
* @category
|
|
2585
|
+
* @category combining
|
|
2586
2586
|
* @since 2.0.0
|
|
2587
2587
|
*/
|
|
2588
2588
|
<Output2, Input2, Error2, Env2>(other: Schedule<Output2, Input2, Error2, Env2>): <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<[Output, Output2], Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -2662,7 +2662,7 @@ export declare const either: {
|
|
|
2662
2662
|
*
|
|
2663
2663
|
* @see {@link both} for continuing only while both schedules still recur
|
|
2664
2664
|
*
|
|
2665
|
-
* @category
|
|
2665
|
+
* @category combining
|
|
2666
2666
|
* @since 2.0.0
|
|
2667
2667
|
*/
|
|
2668
2668
|
<Output, Input, Error, Env, Output2, Input2, Error2, Env2>(self: Schedule<Output, Input, Error, Env>, other: Schedule<Output2, Input2, Error2, Env2>): Schedule<[Output, Output2], Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -2699,7 +2699,7 @@ export declare const either: {
|
|
|
2699
2699
|
* })
|
|
2700
2700
|
* ```
|
|
2701
2701
|
*
|
|
2702
|
-
* @category
|
|
2702
|
+
* @category combining
|
|
2703
2703
|
* @since 4.0.0
|
|
2704
2704
|
*/
|
|
2705
2705
|
export declare const eitherLeft: {
|
|
@@ -2735,7 +2735,7 @@ export declare const eitherLeft: {
|
|
|
2735
2735
|
* })
|
|
2736
2736
|
* ```
|
|
2737
2737
|
*
|
|
2738
|
-
* @category
|
|
2738
|
+
* @category combining
|
|
2739
2739
|
* @since 4.0.0
|
|
2740
2740
|
*/
|
|
2741
2741
|
<Output2, Input2, Error2, Env2>(other: Schedule<Output2, Input2, Error2, Env2>): <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -2771,7 +2771,7 @@ export declare const eitherLeft: {
|
|
|
2771
2771
|
* })
|
|
2772
2772
|
* ```
|
|
2773
2773
|
*
|
|
2774
|
-
* @category
|
|
2774
|
+
* @category combining
|
|
2775
2775
|
* @since 4.0.0
|
|
2776
2776
|
*/
|
|
2777
2777
|
<Output, Input, Error, Env, Output2, Input2, Error2, Env2>(self: Schedule<Output, Input, Error, Env>, other: Schedule<Output2, Input2, Error2, Env2>): Schedule<Output, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -2808,7 +2808,7 @@ export declare const eitherLeft: {
|
|
|
2808
2808
|
* })
|
|
2809
2809
|
* ```
|
|
2810
2810
|
*
|
|
2811
|
-
* @category
|
|
2811
|
+
* @category combining
|
|
2812
2812
|
* @since 4.0.0
|
|
2813
2813
|
*/
|
|
2814
2814
|
export declare const eitherRight: {
|
|
@@ -2844,7 +2844,7 @@ export declare const eitherRight: {
|
|
|
2844
2844
|
* })
|
|
2845
2845
|
* ```
|
|
2846
2846
|
*
|
|
2847
|
-
* @category
|
|
2847
|
+
* @category combining
|
|
2848
2848
|
* @since 4.0.0
|
|
2849
2849
|
*/
|
|
2850
2850
|
<Output2, Input2, Error2, Env2>(other: Schedule<Output2, Input2, Error2, Env2>): <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output2, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -2880,7 +2880,7 @@ export declare const eitherRight: {
|
|
|
2880
2880
|
* })
|
|
2881
2881
|
* ```
|
|
2882
2882
|
*
|
|
2883
|
-
* @category
|
|
2883
|
+
* @category combining
|
|
2884
2884
|
* @since 4.0.0
|
|
2885
2885
|
*/
|
|
2886
2886
|
<Output, Input, Error, Env, Output2, Input2, Error2, Env2>(self: Schedule<Output, Input, Error, Env>, other: Schedule<Output2, Input2, Error2, Env2>): Schedule<Output2, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -2922,7 +2922,7 @@ export declare const eitherRight: {
|
|
|
2922
2922
|
* })
|
|
2923
2923
|
* ```
|
|
2924
2924
|
*
|
|
2925
|
-
* @category
|
|
2925
|
+
* @category combining
|
|
2926
2926
|
* @since 2.0.0
|
|
2927
2927
|
*/
|
|
2928
2928
|
export declare const eitherWith: {
|
|
@@ -2963,7 +2963,7 @@ export declare const eitherWith: {
|
|
|
2963
2963
|
* })
|
|
2964
2964
|
* ```
|
|
2965
2965
|
*
|
|
2966
|
-
* @category
|
|
2966
|
+
* @category combining
|
|
2967
2967
|
* @since 2.0.0
|
|
2968
2968
|
*/
|
|
2969
2969
|
<Output2, Input2, Error2, Env2, Output, Output3>(other: Schedule<Output2, Input2, Error2, Env2>, combine: (selfOutput: Output, otherOutput: Output2) => Output3): <Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output3, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -3004,7 +3004,7 @@ export declare const eitherWith: {
|
|
|
3004
3004
|
* })
|
|
3005
3005
|
* ```
|
|
3006
3006
|
*
|
|
3007
|
-
* @category
|
|
3007
|
+
* @category combining
|
|
3008
3008
|
* @since 2.0.0
|
|
3009
3009
|
*/
|
|
3010
3010
|
<Output, Input, Error, Env, Output2, Input2, Error2, Env2, Output3>(self: Schedule<Output, Input, Error, Env>, other: Schedule<Output2, Input2, Error2, Env2>, combine: (selfOutput: Output, otherOutput: Output2) => Output3): Schedule<Output3, Input & Input2, Error | Error2, Env | Env2>;
|
|
@@ -3452,7 +3452,7 @@ export declare const map: {
|
|
|
3452
3452
|
* })
|
|
3453
3453
|
* ```
|
|
3454
3454
|
*
|
|
3455
|
-
* @category
|
|
3455
|
+
* @category delays & timeouts
|
|
3456
3456
|
* @since 2.0.0
|
|
3457
3457
|
*/
|
|
3458
3458
|
export declare const modifyDelay: {
|
|
@@ -3486,7 +3486,7 @@ export declare const modifyDelay: {
|
|
|
3486
3486
|
* })
|
|
3487
3487
|
* ```
|
|
3488
3488
|
*
|
|
3489
|
-
* @category
|
|
3489
|
+
* @category delays & timeouts
|
|
3490
3490
|
* @since 2.0.0
|
|
3491
3491
|
*/
|
|
3492
3492
|
<Output, Error2 = never, Env2 = never>(f: (output: Output, delay: Duration.Duration) => Effect<Duration.Input, Error2, Env2>): <Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output, Input, Error | Error2, Env | Env2>;
|
|
@@ -3520,7 +3520,7 @@ export declare const modifyDelay: {
|
|
|
3520
3520
|
* })
|
|
3521
3521
|
* ```
|
|
3522
3522
|
*
|
|
3523
|
-
* @category
|
|
3523
|
+
* @category delays & timeouts
|
|
3524
3524
|
* @since 2.0.0
|
|
3525
3525
|
*/
|
|
3526
3526
|
<Output, Input, Error, Env, Error2 = never, Env2 = never>(self: Schedule<Output, Input, Error, Env>, f: (output: Output, delay: Duration.Input) => Effect<Duration.Input, Error2, Env2>): Schedule<Output, Input, Error | Error2, Env | Env2>;
|
|
@@ -3539,7 +3539,7 @@ export declare const modifyDelay: {
|
|
|
3539
3539
|
*
|
|
3540
3540
|
* @see {@link modifyDelay} for replacing recurrence delays with a custom effectful transformation
|
|
3541
3541
|
*
|
|
3542
|
-
* @category
|
|
3542
|
+
* @category delays & timeouts
|
|
3543
3543
|
* @since 2.0.0
|
|
3544
3544
|
*/
|
|
3545
3545
|
export declare const jittered: <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output, Input, Error, Env>;
|
|
@@ -3569,7 +3569,7 @@ export declare const jittered: <Output, Input, Error, Env>(self: Schedule<Output
|
|
|
3569
3569
|
* })
|
|
3570
3570
|
* ```
|
|
3571
3571
|
*
|
|
3572
|
-
* @category
|
|
3572
|
+
* @category mapping
|
|
3573
3573
|
* @since 2.0.0
|
|
3574
3574
|
*/
|
|
3575
3575
|
export declare const passthrough: <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Input, Input, Error, Env>;
|
|
@@ -3754,7 +3754,7 @@ export declare const recurs: (times: number) => Schedule<number>;
|
|
|
3754
3754
|
* })
|
|
3755
3755
|
* ```
|
|
3756
3756
|
*
|
|
3757
|
-
* @category
|
|
3757
|
+
* @category folding
|
|
3758
3758
|
* @since 2.0.0
|
|
3759
3759
|
*/
|
|
3760
3760
|
export declare const reduce: {
|
|
@@ -3867,7 +3867,7 @@ export declare const reduce: {
|
|
|
3867
3867
|
* })
|
|
3868
3868
|
* ```
|
|
3869
3869
|
*
|
|
3870
|
-
* @category
|
|
3870
|
+
* @category folding
|
|
3871
3871
|
* @since 2.0.0
|
|
3872
3872
|
*/
|
|
3873
3873
|
<State, Output, Error2 = never, Env2 = never>(initial: LazyArg<State>, combine: (state: State, output: Output) => State | Effect<State, Error2, Env2>): <Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<State, Input, Error | Error2, Env | Env2>;
|
|
@@ -3980,7 +3980,7 @@ export declare const reduce: {
|
|
|
3980
3980
|
* })
|
|
3981
3981
|
* ```
|
|
3982
3982
|
*
|
|
3983
|
-
* @category
|
|
3983
|
+
* @category folding
|
|
3984
3984
|
* @since 2.0.0
|
|
3985
3985
|
*/
|
|
3986
3986
|
<Output, Input, Error, Env, State, Error2 = never, Env2 = never>(self: Schedule<Output, Input, Error, Env>, initial: LazyArg<State>, combine: (state: State, output: Output) => State | Effect<State, Error2, Env2>): Schedule<State, Input, Error | Error2, Env | Env2>;
|
|
@@ -4886,7 +4886,7 @@ export declare const tapOutput: {
|
|
|
4886
4886
|
*
|
|
4887
4887
|
* @see {@link recurs} for creating a count-limited schedule
|
|
4888
4888
|
*
|
|
4889
|
-
* @category
|
|
4889
|
+
* @category taking
|
|
4890
4890
|
* @since 4.0.0
|
|
4891
4891
|
*/
|
|
4892
4892
|
export declare const take: {
|
|
@@ -4982,7 +4982,7 @@ export declare const take: {
|
|
|
4982
4982
|
*
|
|
4983
4983
|
* @see {@link recurs} for creating a count-limited schedule
|
|
4984
4984
|
*
|
|
4985
|
-
* @category
|
|
4985
|
+
* @category taking
|
|
4986
4986
|
* @since 4.0.0
|
|
4987
4987
|
*/
|
|
4988
4988
|
(n: number): <Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>) => Schedule<Output, Input, Error, Env>;
|
|
@@ -5078,7 +5078,7 @@ export declare const take: {
|
|
|
5078
5078
|
*
|
|
5079
5079
|
* @see {@link recurs} for creating a count-limited schedule
|
|
5080
5080
|
*
|
|
5081
|
-
* @category
|
|
5081
|
+
* @category taking
|
|
5082
5082
|
* @since 4.0.0
|
|
5083
5083
|
*/
|
|
5084
5084
|
<Output, Input, Error, Env>(self: Schedule<Output, Input, Error, Env>, n: number): Schedule<Output, Input, Error, Env>;
|
|
@@ -5202,7 +5202,7 @@ export {
|
|
|
5202
5202
|
* @see {@link collectWhile} for collecting outputs while using the same predicate
|
|
5203
5203
|
* @see {@link take} for stopping after a fixed number of schedule outputs
|
|
5204
5204
|
*
|
|
5205
|
-
* @category
|
|
5205
|
+
* @category filtering
|
|
5206
5206
|
* @since 4.0.0
|
|
5207
5207
|
*/
|
|
5208
5208
|
while_ as while };
|
package/dist/Schedule.js
CHANGED
|
@@ -395,7 +395,7 @@ export const toStepWithSleep = schedule => effect.map(toStepWithMetadata(schedul
|
|
|
395
395
|
* })
|
|
396
396
|
* ```
|
|
397
397
|
*
|
|
398
|
-
* @category
|
|
398
|
+
* @category delays & timeouts
|
|
399
399
|
* @since 2.0.0
|
|
400
400
|
*/
|
|
401
401
|
export const addDelay = /*#__PURE__*/dual(2, (self, f) => modifyDelay(self, (output, delay) => effect.map(f(output), d => Duration.sum(Duration.fromInputUnsafe(d), Duration.fromInputUnsafe(delay)))));
|
|
@@ -578,7 +578,7 @@ export const andThenResult = /*#__PURE__*/dual(2, (self, other) => fromStep(effe
|
|
|
578
578
|
*
|
|
579
579
|
* @see {@link either} for continuing while either schedule still recurs
|
|
580
580
|
*
|
|
581
|
-
* @category
|
|
581
|
+
* @category combining
|
|
582
582
|
* @since 2.0.0
|
|
583
583
|
*/
|
|
584
584
|
export const both = /*#__PURE__*/dual(2, (self, other) => bothWith(self, other, (left, right) => [left, right]));
|
|
@@ -611,7 +611,7 @@ export const both = /*#__PURE__*/dual(2, (self, other) => bothWith(self, other,
|
|
|
611
611
|
* })
|
|
612
612
|
* ```
|
|
613
613
|
*
|
|
614
|
-
* @category
|
|
614
|
+
* @category combining
|
|
615
615
|
* @since 2.0.0
|
|
616
616
|
*/
|
|
617
617
|
export const bothLeft = /*#__PURE__*/dual(2, (self, other) => bothWith(self, other, output => output));
|
|
@@ -646,7 +646,7 @@ export const bothLeft = /*#__PURE__*/dual(2, (self, other) => bothWith(self, oth
|
|
|
646
646
|
* })
|
|
647
647
|
* ```
|
|
648
648
|
*
|
|
649
|
-
* @category
|
|
649
|
+
* @category combining
|
|
650
650
|
* @since 2.0.0
|
|
651
651
|
*/
|
|
652
652
|
export const bothRight = /*#__PURE__*/dual(2, (self, other) => bothWith(self, other, (_, output) => output));
|
|
@@ -686,7 +686,7 @@ export const bothRight = /*#__PURE__*/dual(2, (self, other) => bothWith(self, ot
|
|
|
686
686
|
* })
|
|
687
687
|
* ```
|
|
688
688
|
*
|
|
689
|
-
* @category
|
|
689
|
+
* @category combining
|
|
690
690
|
* @since 2.0.0
|
|
691
691
|
*/
|
|
692
692
|
export const bothWith = /*#__PURE__*/dual(3, (self, other, combine) => fromStep(effect.map(effect.zip(toStep(self), toStep(other)), ([stepLeft, stepRight]) => (now, input) => Pull.matchEffect(stepLeft(now, input), {
|
|
@@ -726,7 +726,7 @@ export const bothWith = /*#__PURE__*/dual(3, (self, other, combine) => fromStep(
|
|
|
726
726
|
* })
|
|
727
727
|
* ```
|
|
728
728
|
*
|
|
729
|
-
* @category
|
|
729
|
+
* @category collecting
|
|
730
730
|
* @since 4.0.0
|
|
731
731
|
*/
|
|
732
732
|
export const collectInputs = self => collectWhile(passthrough(self), () => effect.succeed(true));
|
|
@@ -760,7 +760,7 @@ export const collectInputs = self => collectWhile(passthrough(self), () => effec
|
|
|
760
760
|
* })
|
|
761
761
|
* ```
|
|
762
762
|
*
|
|
763
|
-
* @category
|
|
763
|
+
* @category collecting
|
|
764
764
|
* @since 4.0.0
|
|
765
765
|
*/
|
|
766
766
|
export const collectOutputs = self => collectWhile(self, () => effect.succeed(true));
|
|
@@ -844,7 +844,7 @@ export const collectOutputs = self => collectWhile(self, () => effect.succeed(tr
|
|
|
844
844
|
* })
|
|
845
845
|
* ```
|
|
846
846
|
*
|
|
847
|
-
* @category
|
|
847
|
+
* @category collecting
|
|
848
848
|
* @since 2.0.0
|
|
849
849
|
*/
|
|
850
850
|
export const collectWhile = /*#__PURE__*/dual(2, (self, predicate) => reduce(while_(self, predicate), () => [], (outputs, output) => {
|
|
@@ -1279,7 +1279,7 @@ export const during = duration => while_(elapsed, ({
|
|
|
1279
1279
|
*
|
|
1280
1280
|
* @see {@link both} for continuing only while both schedules still recur
|
|
1281
1281
|
*
|
|
1282
|
-
* @category
|
|
1282
|
+
* @category combining
|
|
1283
1283
|
* @since 2.0.0
|
|
1284
1284
|
*/
|
|
1285
1285
|
export const either = /*#__PURE__*/dual(2, (self, other) => eitherWith(self, other, (left, right) => [left, right]));
|
|
@@ -1315,7 +1315,7 @@ export const either = /*#__PURE__*/dual(2, (self, other) => eitherWith(self, oth
|
|
|
1315
1315
|
* })
|
|
1316
1316
|
* ```
|
|
1317
1317
|
*
|
|
1318
|
-
* @category
|
|
1318
|
+
* @category combining
|
|
1319
1319
|
* @since 4.0.0
|
|
1320
1320
|
*/
|
|
1321
1321
|
export const eitherLeft = /*#__PURE__*/dual(2, (self, other) => eitherWith(self, other, output => output));
|
|
@@ -1351,7 +1351,7 @@ export const eitherLeft = /*#__PURE__*/dual(2, (self, other) => eitherWith(self,
|
|
|
1351
1351
|
* })
|
|
1352
1352
|
* ```
|
|
1353
1353
|
*
|
|
1354
|
-
* @category
|
|
1354
|
+
* @category combining
|
|
1355
1355
|
* @since 4.0.0
|
|
1356
1356
|
*/
|
|
1357
1357
|
export const eitherRight = /*#__PURE__*/dual(2, (self, other) => eitherWith(self, other, (_, output) => output));
|
|
@@ -1392,7 +1392,7 @@ export const eitherRight = /*#__PURE__*/dual(2, (self, other) => eitherWith(self
|
|
|
1392
1392
|
* })
|
|
1393
1393
|
* ```
|
|
1394
1394
|
*
|
|
1395
|
-
* @category
|
|
1395
|
+
* @category combining
|
|
1396
1396
|
* @since 2.0.0
|
|
1397
1397
|
*/
|
|
1398
1398
|
export const eitherWith = /*#__PURE__*/dual(3, (self, other, combine) => fromStep(effect.map(effect.zip(toStep(self), toStep(other)), ([stepLeft, stepRight]) => (now, input) => Pull.matchEffect(stepLeft(now, input), {
|
|
@@ -1771,7 +1771,7 @@ export const map = /*#__PURE__*/dual(2, (self, f) => {
|
|
|
1771
1771
|
* })
|
|
1772
1772
|
* ```
|
|
1773
1773
|
*
|
|
1774
|
-
* @category
|
|
1774
|
+
* @category delays & timeouts
|
|
1775
1775
|
* @since 2.0.0
|
|
1776
1776
|
*/
|
|
1777
1777
|
export const modifyDelay = /*#__PURE__*/dual(2, (self, f) => fromStep(effect.map(toStep(self), step => (now, input) => effect.flatMap(step(now, input), ([output, delay]) => effect.map(f(output, delay), delay => [output, Duration.fromInputUnsafe(delay)])))));
|
|
@@ -1789,7 +1789,7 @@ export const modifyDelay = /*#__PURE__*/dual(2, (self, f) => fromStep(effect.map
|
|
|
1789
1789
|
*
|
|
1790
1790
|
* @see {@link modifyDelay} for replacing recurrence delays with a custom effectful transformation
|
|
1791
1791
|
*
|
|
1792
|
-
* @category
|
|
1792
|
+
* @category delays & timeouts
|
|
1793
1793
|
* @since 2.0.0
|
|
1794
1794
|
*/
|
|
1795
1795
|
export const jittered = self => modifyDelay(self, (_, delay) => effect.map(randomNext, random => {
|
|
@@ -1822,7 +1822,7 @@ export const jittered = self => modifyDelay(self, (_, delay) => effect.map(rando
|
|
|
1822
1822
|
* })
|
|
1823
1823
|
* ```
|
|
1824
1824
|
*
|
|
1825
|
-
* @category
|
|
1825
|
+
* @category mapping
|
|
1826
1826
|
* @since 2.0.0
|
|
1827
1827
|
*/
|
|
1828
1828
|
export const passthrough = self => fromStep(effect.map(toStep(self), step => (now, input) => Pull.matchEffect(step(now, input), {
|
|
@@ -2013,7 +2013,7 @@ export const recurs = times => while_(forever, ({
|
|
|
2013
2013
|
* })
|
|
2014
2014
|
* ```
|
|
2015
2015
|
*
|
|
2016
|
-
* @category
|
|
2016
|
+
* @category folding
|
|
2017
2017
|
* @since 2.0.0
|
|
2018
2018
|
*/
|
|
2019
2019
|
export const reduce = /*#__PURE__*/dual(3, (self, initial, combine) => fromStep(effect.map(toStep(self), step => {
|
|
@@ -2447,7 +2447,7 @@ export const tapOutput = /*#__PURE__*/dual(2, (self, f) => fromStep(effect.map(t
|
|
|
2447
2447
|
*
|
|
2448
2448
|
* @see {@link recurs} for creating a count-limited schedule
|
|
2449
2449
|
*
|
|
2450
|
-
* @category
|
|
2450
|
+
* @category taking
|
|
2451
2451
|
* @since 4.0.0
|
|
2452
2452
|
*/
|
|
2453
2453
|
export const take = /*#__PURE__*/dual(2, (self, n) => while_(self, ({
|
|
@@ -2587,7 +2587,7 @@ export {
|
|
|
2587
2587
|
* @see {@link collectWhile} for collecting outputs while using the same predicate
|
|
2588
2588
|
* @see {@link take} for stopping after a fixed number of schedule outputs
|
|
2589
2589
|
*
|
|
2590
|
-
* @category
|
|
2590
|
+
* @category filtering
|
|
2591
2591
|
* @since 4.0.0
|
|
2592
2592
|
*/
|
|
2593
2593
|
while_ as while };
|