package cn.stylefeng.workflow.instance.modular.task.holder;

import cn.stylefeng.workflow.instance.modular.task.pojo.operate.BackTaskRequest;

public class EventBackTaskParamHolder {

    private static final ThreadLocal<BackTaskRequest> CONTEXT_HOLDER = new ThreadLocal<>();

    public static void setParam(BackTaskRequest backTaskRequest) {
        CONTEXT_HOLDER.set(backTaskRequest);
    }

    public static BackTaskRequest getParam() {
        return CONTEXT_HOLDER.get();
    }

    public static void clearParam() {
        CONTEXT_HOLDER.remove();
    }

}
