Schema.d.ts 799 B

1234567891011121314151617
  1. import { MAP, SCALAR, SEQ } from '../nodes/identity.js';
  2. import type { Pair } from '../nodes/Pair.js';
  3. import type { SchemaOptions, ToStringOptions } from '../options.js';
  4. import type { CollectionTag, ScalarTag } from './types.js';
  5. export declare class Schema {
  6. compat: Array<CollectionTag | ScalarTag> | null;
  7. knownTags: Record<string, CollectionTag | ScalarTag>;
  8. name: string;
  9. sortMapEntries: ((a: Pair, b: Pair) => number) | null;
  10. tags: Array<CollectionTag | ScalarTag>;
  11. toStringOptions: Readonly<ToStringOptions> | null;
  12. readonly [MAP]: CollectionTag;
  13. readonly [SCALAR]: ScalarTag;
  14. readonly [SEQ]: CollectionTag;
  15. constructor({ compat, customTags, merge, resolveKnownTags, schema, sortMapEntries, toStringDefaults }: SchemaOptions);
  16. clone(): Schema;
  17. }