@mondart/nestjs-common-module 1.1.44 → 1.1.46
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/lib/index.d.ts +1 -0
- package/dist/lib/index.js +1 -0
- package/dist/lib/saga/constant/index.d.ts +1 -0
- package/dist/lib/saga/constant/index.js +17 -0
- package/dist/lib/saga/constant/saga-handler.const.d.ts +1 -0
- package/dist/lib/saga/constant/saga-handler.const.js +4 -0
- package/dist/lib/saga/decorators/index.d.ts +1 -0
- package/dist/lib/saga/decorators/index.js +17 -0
- package/dist/lib/saga/decorators/saga.decorator.d.ts +4 -0
- package/dist/lib/saga/decorators/saga.decorator.js +15 -0
- package/dist/lib/saga/enums/index.d.ts +1 -0
- package/dist/lib/saga/enums/index.js +17 -0
- package/dist/lib/saga/enums/saga-status.enum.d.ts +8 -0
- package/dist/lib/saga/enums/saga-status.enum.js +12 -0
- package/dist/lib/saga/exceptions/index.d.ts +2 -0
- package/dist/lib/saga/exceptions/index.js +18 -0
- package/dist/lib/saga/exceptions/saga-compensation.exception.d.ts +5 -0
- package/dist/lib/saga/exceptions/saga-compensation.exception.js +13 -0
- package/dist/lib/saga/exceptions/saga-invocation.exception.d.ts +5 -0
- package/dist/lib/saga/exceptions/saga-invocation.exception.js +13 -0
- package/dist/lib/saga/helpers/index.d.ts +2 -0
- package/dist/lib/saga/helpers/index.js +18 -0
- package/dist/lib/saga/helpers/saga-exception-converter.helper.d.ts +3 -0
- package/dist/lib/saga/helpers/saga-exception-converter.helper.js +14 -0
- package/dist/lib/saga/helpers/wrap-if-not-error.helper.d.ts +1 -0
- package/dist/lib/saga/helpers/wrap-if-not-error.helper.js +9 -0
- package/dist/lib/saga/index.d.ts +6 -0
- package/dist/lib/saga/index.js +14 -0
- package/dist/lib/saga/interfaces/index.d.ts +1 -0
- package/dist/lib/saga/interfaces/index.js +17 -0
- package/dist/lib/saga/interfaces/saga-module-register.interface.d.ts +6 -0
- package/dist/lib/saga/interfaces/saga-module-register.interface.js +3 -0
- package/dist/lib/saga/saga.module.d.ts +5 -0
- package/dist/lib/saga/saga.module.js +49 -0
- package/dist/lib/saga/services/index.d.ts +4 -0
- package/dist/lib/saga/services/index.js +20 -0
- package/dist/lib/saga/services/saga-builder.service.d.ts +8 -0
- package/dist/lib/saga/services/saga-builder.service.js +40 -0
- package/dist/lib/saga/services/saga-flow.service.d.ts +14 -0
- package/dist/lib/saga/services/saga-flow.service.js +39 -0
- package/dist/lib/saga/services/saga-step.service.d.ts +16 -0
- package/dist/lib/saga/services/saga-step.service.js +37 -0
- package/dist/lib/saga/services/saga.service.d.ts +11 -0
- package/dist/lib/saga/services/saga.service.js +44 -0
- package/dist/lib/saga/types/builder-method-return-result.type.d.ts +4 -0
- package/dist/lib/saga/types/builder-method-return-result.type.js +2 -0
- package/dist/lib/saga/types/builder-method-step-result.type.d.ts +7 -0
- package/dist/lib/saga/types/builder-method-step-result.type.js +2 -0
- package/dist/lib/saga/types/condition.type.d.ts +1 -0
- package/dist/lib/saga/types/condition.type.js +2 -0
- package/dist/lib/saga/types/index.d.ts +6 -0
- package/dist/lib/saga/types/index.js +22 -0
- package/dist/lib/saga/types/next-options.type.d.ts +12 -0
- package/dist/lib/saga/types/next-options.type.js +2 -0
- package/dist/lib/saga/types/saga-fn.type.d.ts +1 -0
- package/dist/lib/saga/types/saga-fn.type.js +2 -0
- package/dist/lib/saga/types/saga.type.d.ts +4 -0
- package/dist/lib/saga/types/saga.type.js +2 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type Condition<IF, THEN, ELSE> = IF extends void ? ELSE : THEN;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./saga.type"), exports);
|
|
18
|
+
__exportStar(require("./saga-fn.type"), exports);
|
|
19
|
+
__exportStar(require("./next-options.type"), exports);
|
|
20
|
+
__exportStar(require("./condition.type"), exports);
|
|
21
|
+
__exportStar(require("./builder-method-return-result.type"), exports);
|
|
22
|
+
__exportStar(require("./builder-method-step-result.type"), exports);
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Condition } from './condition.type';
|
|
2
|
+
import { SagaCore } from '../services';
|
|
3
|
+
import { Fn } from './saga-fn.type';
|
|
4
|
+
import { BuilderMethodStepResult } from './builder-method-step-result.type';
|
|
5
|
+
import { BuilderMethodReturnResult } from './builder-method-return-result.type';
|
|
6
|
+
export type NextOptions<T, R> = {
|
|
7
|
+
step: (name?: string) => BuilderMethodStepResult<T, R>;
|
|
8
|
+
} & Condition<R, {
|
|
9
|
+
return: (method: Fn<T, R>) => BuilderMethodReturnResult<T, R>;
|
|
10
|
+
}, {
|
|
11
|
+
build: () => SagaCore<T, R>;
|
|
12
|
+
}>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type Fn<I, O = void> = (input: I) => Promise<O> | O;
|