I have a list of management songs, so this is my criteria to sort now the songs. How can i "convert" this to a lambda expression?
gestionCancionList.sort(new Comparator<GestionCancion>() {
@Override
public int compare(GestionCancion t1, GestionCancion t2){
return t1.vecesQueSeRepite == t2.vecesQueSeRepite ?
t1.song.dameInterprete().compareTo(t2.song.dameInterprete())
: (int)(t2.vecesQueSeRepite - t1.vecesQueSeRepite);
}
}