import { Arbitrary } from 'fast-check/*'; import { Type } from 'io-ts'; import { JSONSchema } from '../json-schema/json-schema'; import { ProgramUnionURI } from './program'; import * as E from 'fp-ts/lib/Either'; import { NonEmptyArray } from 'fp-ts/lib/NonEmptyArray'; import { NamedSchemas } from '../json-schema-interpreters'; import { Summoners } from '../usage/summoner'; import { ProgramInterpreter, Materialized } from '../usage/materializer'; import { JsonSchemaError } from '../json-schema/json-schema-ctors'; import { ProgramType } from '../usage/ProgramType'; interface BASTJInterpreter { build: (a: A) => A; arb: Arbitrary; strictType: Type; type: Type; jsonSchema: E.Either, [JSONSchema, NamedSchemas]>; } export declare const BASTJInterpreterURI: unique symbol; export declare type BASTJInterpreterURI = typeof BASTJInterpreterURI; export declare const BASTJInterpreter: ProgramInterpreter; declare module '../usage/InterpreterResult' { interface InterpreterResult { [BASTJInterpreterURI]: BASTJInterpreter; } } declare module '../usage/ProgramType' { interface ProgramUnionInterpreters { [BASTJInterpreterURI]: Summoner; } } /** Type level override to keep Morph type name short */ export interface M extends Materialized { } export interface UM extends Materialized { } export declare const AsOpaque: (x: M) => M; export declare const AsUOpaque: (x: UM) => UM; export interface MorphAs { (F: ProgramType[ProgramUnionURI]): M; } export interface MorphAsA { (): (F: ProgramType[ProgramUnionURI]) => M; } export interface MorphAsL { (): (F: ProgramType[ProgramUnionURI]) => M; } export interface Morph { (F: ProgramType[ProgramUnionURI]): UM; } export interface Summoner extends Summoners { summonAs: MorphAs; summonAsA: MorphAsA; summonAsL: MorphAsL; summon: Morph; } export {};