for(int j=START_INDEX;j<cols.size();j++){
if(cols.get(j) instanceof Otherwise){
isOtherwise = true;
break;
}else if(cols.get(j) instanceof RoleExist){
RoleExist role = (RoleExist)cols.get(j);
if(role!=null){
and.addCondition(role);
}
}else{
Evaluate eval = (Evaluate)cols.get(j);
if(eval!=null){
and.addCondition(eval);
}
}
}
if(!isOtherwise && and.getConditionsVt().size()>0){
or.addCondition(and);
}
if(isOtherwise){
Otherwise otherwise = new Otherwise();
map.put(key, otherwise);
otherwise.getDescription().setText(key);
ors.addCondition(otherwise);
}else{
map.put(key, or);
or.getDescription().setText(key);
ors.addCondition(or);
}
}else{
And and = new And();
for(int j=START_INDEX;j<cols.size();j++){
if(cols.get(j) instanceof Evaluate){
Evaluate eval = (Evaluate)cols.get(j);
if(eval!=null){
and.addCondition(eval);
}
}else{
RoleExist role = (RoleExist)cols.get(j);
if(role!=null){
and.addCondition(role);
}
}
}