Java get file type without extension code example
Example 1: how to get filename without extension in java
FilenameUtils.removeExtension(fileNameWithExt);
Example 2: java get filename without extension
String fname = file.getName();
int pos = fname.lastIndexOf(".");
if (pos > 0) {
fname = fname.substring(0, pos);
}