import { PushImpactListenerInvocation } from "../listener/PushImpactListener";
import { PushRegistration } from "./PushRegistration";
/**
 * A code action response that affects delivery:
 * failing the current goal or requiring approval,
 * causing dependent goals to fail or wait.
 */
export declare enum PushImpactResponse {
    /**
     * Everything's good. Keep going.
     */
    proceed = "proceed",
    /**
     * Fail execution of the present goalset. Any dependent goals will stop.
     * Will not stop execution of non-dependent goals.
     */
    failGoals = "fail",
    /**
     * Require approval to proceed to dependent goals in the present goalset.
     */
    requireApprovalToProceed = "requireApproval"
}
declare type DefaultPushImpactListenerResult = void | PushImpactResponse;
/**
 * Reaction on a push, with the code available.
 * Can optionally return a response that
 * determines whether to ask for approval or terminate current delivery flow.
 */
export declare type PushImpactListener<R = DefaultPushImpactListenerResult> = (i: PushImpactListenerInvocation) => Promise<R>;
/**
 * Used to register actions on a push that can potentially
 * influence downstream goals. Will be invoked if a PushReactionGoal has
 * been set for the given push.
 * Use ReviewerRegistration if you want to return a structured review.
 */
export declare type PushImpactListenerRegistration<R = DefaultPushImpactListenerResult> = PushRegistration<PushImpactListener<R>>;
/**
 * Something we can register as a push reaction
 */
export declare type PushImpactListenerRegisterable<R = DefaultPushImpactListenerResult> = PushImpactListenerRegistration<R> | PushImpactListener<R>;
/**
 * Convert an action function to a PushImpactListener if necessary
 * @param {PushImpactListenerRegisterable<any>} prr
 * @return {PushImpactListenerRegistration}
 */
export declare function toPushReactionRegistration(prr: PushImpactListenerRegisterable): PushImpactListenerRegistration;
export {};
//# sourceMappingURL=PushImpactListenerRegistration.d.ts.map