Prendi la classe "comm" (nome bruttissimo, visto che rappresenta un commento potresti chiamarla "Comment") e falle implementare Comparable:
codice:
public class Comment implements Comparable<Comment> {
...
...
public int compareTo(Comment c) {
// Questo è un metodo di Comparable. Per un ordinamento crescente deve restituire:
// un numero minore di zero se "commento chiamante" < c
// 0 se "commento chiamante" = c
// un numero positivo se "commento chiamante" > c
}
}
Decidi te come deve essere ordinato