public static ExpList parseExpressionList(String kif) throws InvalidKIFException {
try{
kif = kif.replace(")", ") ").trim();
if(kif.charAt(0) != '(' || kif.charAt(kif.length()-1) != ')')
throw new InvalidKIFException("not a valid kif list:"+kif);
kif = "(bla " + kif.substring(1, kif.length()).trim();
ExpList list=Parser.parseDesc(kif);
if(list.size() != 1){
throw new InvalidKIFException("Exception while parsing \""+kif+"\":...");
}
return ((Connective)list.get(0)).getOperands();
}catch(Exception ex){
throw new InvalidKIFException("Exception while parsing \""+kif+"\":"+ex.getMessage());
}
}