package com.prolog.cs.biz.inbound.domain.executor;

import com.prolog.cs.biz.inbound.service.impl.processor.enums.ConclusionEnum;
import com.prolog.cs.biz.inbound.service.impl.processor.enums.RcvTypeStrategyEnum;
import com.prolog.cs.biz.inbound.service.impl.processor.enums.RqcStrategyEnum;
import com.prolog.cs.biz.inbound.service.impl.processor.enums.SubjectStrategyEnum;
import com.prolog.cs.biz.inbound.service.impl.processor.handler.TaskHandler;
import org.springframework.stereotype.Service;

import java.util.Map;

@Service
public class DefaultExecutor implements RcvExecutor{
	

	@Override
	public Object excuteTask(Map<String, Object> dataMapList, TaskHandler handler, RcvTypeStrategyEnum rcvType,
			RqcStrategyEnum rqcStrategy, ConclusionEnum conclusionEnum,boolean isAuto) {
		// 操作执行器执行具体任务
		SubjectStrategyEnum subjectStrategy = (SubjectStrategyEnum) getSubjectStrategy();
		Object obj = handler.excute(subjectStrategy, rcvType, rqcStrategy, dataMapList, conclusionEnum,isAuto);
		// 处理前
		// 处理后
		return obj;
	}

	@Override
	public Object getSubjectStrategy() {
		return SubjectStrategyEnum.ZKY;
	}
	
}
