//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package nc.impl.pu.m23.maintain.action;

import nc.bs.pu.m23.maintain.ArriveInsertBP;
import nc.bs.pu.m23.plugin.ArriveActionPlugInPoint;
import nc.impl.pu.m23.maintain.rule.CheckBillDateRule;
import nc.impl.pubapp.pattern.rule.processer.AroundProcesser;
import nc.vo.pu.m23.entity.ArriveVO;
import nc.vo.pu.m23.env.ArrivalUIToBSEnv;

public class ArriveInsertAction {
    public ArriveInsertAction() {
    }

    public ArriveVO[] insertArrive(ArriveVO[] voArray, ArrivalUIToBSEnv env) {
        AroundProcesser<ArriveVO> processer = new AroundProcesser(ArriveActionPlugInPoint.ArriveInsertAction);
        addBeforeRule(processer);
        processer.addBeforeRule(new CheckBillDateRule());
        processer.before(voArray);
        ArriveInsertBP bp = new ArriveInsertBP(env);
        ArriveVO[] ret = bp.insertArrive(voArray);
        processer.after(ret);
        return ret;
    }
    private void addBeforeRule(AroundProcesser<ArriveVO> processer) {
        processer.addBeforeFinalRule(new CheckBillDateRule());
    }
}
