exupery-core-async 0.3.29 → 0.3.30

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.
@@ -8,6 +8,7 @@ export declare namespace p {
8
8
  const conditional_sync: <Error>(precondition: boolean, procedure: _et.Procedure_Promise<Error>) => _et.Procedure_Promise<Error>;
9
9
  const dictionary_serie: <Error, Entry_Error>(dictionary: _et.Dictionary<_et.Procedure_Promise<Entry_Error>>, transform_error: _et.Transformer_Without_Parameters<_et.Key_Value_Pair<Entry_Error>, Error>) => _et.Procedure_Promise<Error>;
10
10
  const dictionary_parallel: <Error, Entry_Error>(dictionary: _et.Dictionary<_et.Procedure_Promise<Entry_Error>>, aggregate_errors: _et.Transformer_Without_Parameters<_et.Dictionary<Entry_Error>, Error>) => _et.Procedure_Promise<Error>;
11
+ const dictionary_parallel_without_transforming_the_error: <Error, Entry_Error>(dictionary: _et.Dictionary<_et.Procedure_Promise<Entry_Error>>) => _et.Procedure_Promise<_et.Dictionary<Entry_Error>>;
11
12
  const execute_with_async_data: <Parameters, Error>(procedure: _et.Procedure_Primed_With_Resources<Parameters, Error>, query: _et.Query_Promise<Parameters, Error>) => _et.Procedure_Promise<Error>;
12
13
  const sequence: <Error>(steps: _et.Procedure_Promise<Error>[]) => _et.Procedure_Promise<Error>;
13
14
  }
@@ -182,6 +182,31 @@ var p;
182
182
  }
183
183
  });
184
184
  };
185
+ p.dictionary_parallel_without_transforming_the_error = (dictionary) => {
186
+ return (0, create_procedure_promise_1.__create_procedure_promise)({
187
+ 'execute': (on_success, on_error) => {
188
+ const errors = {};
189
+ (0, create_asynchronous_processes_monitor_1.create_asynchronous_processes_monitor)((monitor) => {
190
+ dictionary.map(($, key) => {
191
+ monitor['report process started']();
192
+ $.__start(() => {
193
+ monitor['report process finished']();
194
+ }, (e) => {
195
+ errors[key] = e;
196
+ monitor['report process finished']();
197
+ });
198
+ });
199
+ }, () => {
200
+ if (Object.keys(errors).length === 0) {
201
+ on_success();
202
+ }
203
+ else {
204
+ on_error(_ei.dictionary_literal(errors));
205
+ }
206
+ });
207
+ }
208
+ });
209
+ };
185
210
  p.execute_with_async_data = (procedure, query) => {
186
211
  return (0, create_procedure_promise_1.__create_procedure_promise)({
187
212
  'execute': (on_success, on_error) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "exupery-core-async",
3
- "version": "0.3.29",
3
+ "version": "0.3.30",
4
4
  "license": "Apache-2.0",
5
5
  "author": "Corno",
6
6
  "description": "async types for Exupery",