diff options
Diffstat (limited to 'server/models/request/abstract-request-interface.ts')
-rw-r--r-- | server/models/request/abstract-request-interface.ts | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/server/models/request/abstract-request-interface.ts b/server/models/request/abstract-request-interface.ts new file mode 100644 index 000000000..a384f4d27 --- /dev/null +++ b/server/models/request/abstract-request-interface.ts | |||
@@ -0,0 +1,12 @@ | |||
1 | import * as Promise from 'bluebird' | ||
2 | |||
3 | export interface AbstractRequestClass <T> { | ||
4 | countTotalRequests: () => Promise<number> | ||
5 | listWithLimitAndRandom: (limitPods: number, limitRequestsPerPod: number) => Promise<T> | ||
6 | removeWithEmptyTo: () => Promise<number> | ||
7 | removeAll: () => Promise<void> | ||
8 | } | ||
9 | |||
10 | export interface AbstractRequestToPodClass { | ||
11 | removeByRequestIdsAndPod: (ids: number[], podId: number) => Promise<number> | ||
12 | } | ||