}
}
size=scenarioRoleList.size();
for(int i=0;i<size;i++) {
ScenarioRoleRelation relation=(ScenarioRoleRelation)scenarioRoleList.get(i);
String scenarioName=relation.getScenarioName();
if(sbuffer.indexOf(scenarioName)<0) {
sbuffer.append(scenarioName);
sbuffer.append("\n");
}
String roleName=relation.getRoleName();
if(rbuffer.indexOf(roleName) <0) {
rbuffer.append(roleName);
rbuffer.append("\n");
}
String roleScenario=roleName+","+scenarioName;
if(srbuffer.indexOf(roleScenario)<0) {
srbuffer.append(relation.getRoleName());
srbuffer.append(",");
srbuffer.append(relation.getScenarioName());
srbuffer.append("\n");
}
}
size=scenarioDataList.size();
HashMap<String,String> dataScenario=new HashMap<String,String>();
//找场景之间的数据关系,因为还没有数据传递关系的抽取,所以这里把所有的关系输出,将来需要修改
for(int i=0;i<size;i++) {
ScenarioDataRelation relation=(ScenarioDataRelation)scenarioDataList.get(i);
String data=relation.getDataName();
String scenarioRelations=(String)dataScenario.get(data);
if(scenarioRelations==null) {
dataScenario.put(data, relation.getScenarioName());
} else {
dataScenario.put(data, scenarioRelations+","+relation.getScenarioName());
}
}
for(Entry<String, String> entry: dataScenario.entrySet()) {
String scenarioRelations=entry.getValue();