I wonder how to get the portion of text after the last dot in a string.
For example to get .java from my.project.java or .jpg from my-photo.jpg
String[] parts = "test.test.test".split(".");
if(parts.length == 0) return false;
return true;
For some reason it returns false!