public void printTypes(PrintStream out) throws RulesException {
Object typenames[] = types.keySet().toArray();
for(int i=0;i<typenames.length-1;i++){
for(int j=0;j<typenames.length-1;j++){
RName one = (RName)typenames[j], two = (RName)typenames[j+1];
if(one.compare(two)>0){
Object hold = typenames[j];
typenames[j]=typenames[j+1];
typenames[j+1]=hold;
}
}