import { Method, MethodWithParameters } from '@rxap/pattern'; export interface FormSubmitMethod extends MethodWithParameters { call(parameters: FormSate, context?: Context | null, initial?: Initial | null): any | Promise; } export interface FormLoadMethod extends Method { call(data: { context: Context | null; initial: Initial | null; }): FormState | Promise; } export interface FormLoadFailedMethod extends MethodWithParameters { call(error: Error): Promise | any; } export interface FormLoadSuccessfulMethod extends Method { call(value: T): Promise | any; } export interface FormSubmitFailedMethod extends MethodWithParameters { call(error: Error): Promise | any; } export interface FormSubmitSuccessfulMethod extends Method { call(result: T): Promise | any; } export declare function ToFormMethod, R, P>(call: (value: P) => R | Promise): Method; /** * @deprecated use ToFormMethod instead * * @param call the call method implementation */ export declare function ToFormSubmitMethod(call: (value: T) => boolean): FormSubmitMethod;