code: public String getExtension(String fileName) {
  		if (fileName.lastIndexOf('.') > -1) {
  			return (fileName.substring(fileName.lastIndexOf('.') + 1, fileName.length())).toLowerCase();
  		}
  		return null;
  	}
docs: returns the file extension by filename separated by last dot
  @param fileName
  @return null or extension