1 | import convict from 'convict';
|
2 | import SchemaCore, { OpType } from './core/schema-core';
|
3 | import { Context, OpConfig, APIConfig } from '../interfaces';
|
4 |
|
5 |
|
6 |
|
7 | export default abstract class ConvictSchema<T extends Object, S = any> extends SchemaCore<T> {
|
8 | schema: convict.Schema<S>;
|
9 | constructor(context: Context, opType?: OpType);
|
10 | validate(inputConfig: any): APIConfig & T;
|
11 | validate(inputConfig: any): OpConfig & T;
|
12 | validateJob(job: any): void;
|
13 | static type(): string;
|
14 | abstract build<U = any>(context?: Context): convict.Schema<S & U>;
|
15 | }
|