In the below code I am checking whether file ends with CSV extension. My question is : If file ends with xls extension I need to change to csv.
Example: AA.xls file to AA.CSV (only extension change).
public boolean accept(File dir, String name) {
System.out.println("CSV Files Present in Dir are: " + name);
return name.toLowerCase().endsWith("csv");
}
});