1
- export interface AdditionalPropertiesValidatorError extends SchemaValidatorErrorBase {
2
- keyword : 'additionalProperties' ;
3
- params : {
4
- additionalProperty : string ;
5
- } ;
6
- }
7
-
8
1
export declare function addUndefinedDefaults ( value : JsonValue , _pointer : JsonPointer , schema ?: JsonSchema ) : JsonValue ;
9
2
10
3
export declare class AliasHost < StatsT extends object = { } > extends ResolverHost < StatsT > {
@@ -157,8 +150,8 @@ export interface CordHostRename {
157
150
158
151
export declare class CoreSchemaRegistry implements SchemaRegistry {
159
152
constructor ( formats ?: SchemaFormat [ ] ) ;
160
- protected _resolver ( ref : string , validate ?: ajv . ValidateFunction ) : {
161
- context ?: ajv . ValidateFunction ;
153
+ protected _resolver ( ref : string , validate ?: ValidateFunction ) : {
154
+ context ?: ValidateFunction ;
162
155
schema ?: JsonObject ;
163
156
} ;
164
157
addFormat ( format : SchemaFormat ) : void ;
@@ -228,13 +221,6 @@ export declare class FileDoesNotExistException extends BaseException {
228
221
constructor ( path : string ) ;
229
222
}
230
223
231
- export interface FormatValidatorError extends SchemaValidatorErrorBase {
232
- keyword : 'format' ;
233
- params : {
234
- format : string ;
235
- } ;
236
- }
237
-
238
224
export declare class ForwardingAnalytics implements Analytics {
239
225
protected _fn : AnalyticsForwarderFn ;
240
226
constructor ( _fn : AnalyticsForwarderFn ) ;
@@ -451,13 +437,6 @@ export declare class LevelTransformLogger extends Logger {
451
437
452
438
export declare function levenshtein ( a : string , b : string ) : number ;
453
439
454
- export interface LimitValidatorError extends SchemaValidatorErrorBase {
455
- keyword : 'maxItems' | 'minItems' | 'maxLength' | 'minLength' | 'maxProperties' | 'minProperties' ;
456
- params : {
457
- limit : number ;
458
- } ;
459
- }
460
-
461
440
export interface LogEntry extends LoggerMetadata {
462
441
level : LogLevel ;
463
442
message : string ;
@@ -746,24 +725,10 @@ export interface ReferenceResolver<ContextT> {
746
725
} ;
747
726
}
748
727
749
- export interface RefValidatorError extends SchemaValidatorErrorBase {
750
- keyword : '$ref' ;
751
- params : {
752
- ref : string ;
753
- } ;
754
- }
755
-
756
728
export declare function relative ( from : Path , to : Path ) : Path ;
757
729
758
730
export declare type ReplacementFunction = ( path : Path ) => Path ;
759
731
760
- export interface RequiredValidatorError extends SchemaValidatorErrorBase {
761
- keyword : 'required' ;
762
- params : {
763
- missingProperty : string ;
764
- } ;
765
- }
766
-
767
732
export declare function resetNormalizeCache ( ) : void ;
768
733
769
734
export declare function resolve ( p1 : Path , p2 : Path ) : Path ;
@@ -801,10 +766,7 @@ export interface SchemaFormat {
801
766
name : string ;
802
767
}
803
768
804
- export interface SchemaFormatter {
805
- readonly async : boolean ;
806
- validate ( data : any ) : boolean | Observable < boolean > ;
807
- }
769
+ export declare type SchemaFormatter = Format ;
808
770
809
771
export interface SchemaKeywordValidator {
810
772
( data : JsonValue , schema : JsonValue , parent : JsonObject | JsonArray | undefined , parentProperty : string | number | undefined , pointer : JsonPointer , rootData : JsonValue ) : boolean | Observable < boolean > ;
@@ -831,14 +793,7 @@ export interface SchemaValidator {
831
793
( data : JsonValue , options ?: SchemaValidatorOptions ) : Observable < SchemaValidatorResult > ;
832
794
}
833
795
834
- export declare type SchemaValidatorError = RefValidatorError | LimitValidatorError | AdditionalPropertiesValidatorError | FormatValidatorError | RequiredValidatorError ;
835
-
836
- export interface SchemaValidatorErrorBase {
837
- data ?: JsonValue ;
838
- dataPath : string ;
839
- keyword : string ;
840
- message ?: string ;
841
- }
796
+ export declare type SchemaValidatorError = ErrorObject ;
842
797
843
798
export interface SchemaValidatorOptions {
844
799
applyPostTransforms ?: boolean ;
0 commit comments