bahdan.siamionau@gmail.com
@blazer2007
До Java 9
BufferedReader br = new BufferedReader(new FileReader(path));
try (br) {
return br.readLine();
}
Теперь
BufferedReader br = new BufferedReader(new FileReader(path));
try (BufferedReader omg = br) {
return omg.readLine();
}
До Java 9
Comparator<String> comparator = new Comparator<String>() {
@Override
public int compare(String o1, String o2) {
return o1.compareTo(o2);
}
};
Comparator<String> comparator = new Comparator<>() {
@Override
public int compare(String o1, String o2) {
return o1.compareTo(o2);
}
};
Теперь
@Deprecated(since="1.4", forRemoval=true)
public class X500Principal implements Principal {
...
}