import { AppendPosition } from '../constants'; import Open from './Open'; import Schema from './Schema'; import { InputExpressionValue } from "../../MagicExpressionWidget/types"; export default class SchemaDescription { schema: Schema; open: Open; fieldNum: number; constructor(schema?: Schema); changeSchema(value: Schema): void; addChildField({ keys, customFieldName, }: { keys: string[]; /** 自定义field的name */ customFieldName?: string; }): void; deleteField({ keys }: { keys: string[]; }): void; addField({ keys, name, position, }: { keys: string[]; name?: string; position: AppendPosition; }): void; changeType({ keys, value, itemsType }: { keys: string[]; value: string; itemsType?: string; }): void; insertFields({ keys, name, position, fields }: { keys: string[]; name?: string; position: AppendPosition; fields?: Schema; }): void; enableRequire({ keys, name, required, }: { keys: string[]; name: string; required: boolean; }): void; changeName({ keys, name, value, }: { keys: string[]; name: string; value: string; }): void; changeValue({ keys, value, }: { keys: string[]; value: string | boolean | { mock: string; } | InputExpressionValue; }): void; requireAll({ required }: { required: boolean; }): void; setOpenValue({ key, value }: { key: string[]; value?: boolean; }): void; }