//log.debug(importBean.getImportfile().getFileName());
PoiManager result = new PoiManager();
//result.excelData(importBean.getImportfile(),(String)session.getAttribute(Constants.SESSION_UNIT_ID));
int proUid = result.LinkData(curArr, "admin");
Project projectForm = new Project();
projectForm.setProUid(proUid);
projectForm.setProIterNum(50);
projectForm.setProStartTime(0);
projectForm.setProLifeTime(20);
projectForm.setProTd(365);
SampleEngineImpl sampleEngine = new SampleEngineImpl();
SampleBean samplebean = new SampleBean();
ActionMessages msg = new ActionMessages();
int message = -1;
message = (Integer) sqlMap.update("Project.simulatorUpdate", projectForm);
if(message == 0){
msg.add("message", new ActionMessage("저장에 실패했습니다."));
}else if(message > 0){
msg.add("message", new ActionMessage("저장에 성공했습니다."));
}
saveMessages(request, msg);
List modelingList = sqlMap.queryForList("Modeling.getModeling", ""+projectForm.getProUid()); // Project Uid Modeling Get
HashMap<String, ArrayList<Modeling>> cenarioMap = new HashMap<String, ArrayList<Modeling>>();
Vector<Modeling> modelingVector = new Vector<Modeling>(modelingList.size()); //modelingList를 Vetor로 변경하기 위한 객체 선언
ArrayList<SampleBean> sampleBean = new ArrayList<SampleBean>();
modelingVector.addAll(modelingList); //Vetor 에 List 값 적용
for (int i=0;i<modelingVector.size();i++) {
ArrayList<Modeling> cenarioModeling = (ArrayList<Modeling>)sqlMap.queryForList("Modeling.getSNModeling", ""+modelingVector.get(i).getMoSelf());
if (cenarioModeling != null) {
cenarioMap.put(modelingVector.get(i).getMoSelf(), cenarioModeling);
}
if (modelingVector.get(i).getSamplesList().size()>0) {
sampleBean.addAll(modelingVector.get(i).getSamplesList());
}
}
ArrayList<Figures> figList = (ArrayList<Figures>) sqlMap.queryForList("Figures.figures", new Figures(projectForm));
samplebean.setFigProjectUid(projectForm.getProUid());
//sampleBean = (ArrayList<SampleBean>) sqlMap.queryForList("Sample.figures",samplebean);
//System.out.println("sampleBean.size() : " + sampleBean.size());
Sampleform sampleform = sampleEngine.engineCore(projectForm,sampleBean,simulationArr);
SimulationFields[] simFieldsArr = new SimulationFields[sampleform.getIterationArr().length];