I think you must give option to select the drives for which user wants to filter the files. Please refer below code to get the system drives and add one check box for each on frame:
JFrame frame=new JFrame("File Filter");
To get all the information about files or sub folders inside a directory please check below link as reference:
How to get all files and sub directories in java- Click Here
or to know the extension of file, it´s as simple as above code will return fileName with extension.
if(fileName.lastIndexOf(".") != -1 && fileName.lastIndexOf(".") != 0)
Now all you need to do is now, integrate all the code snippet.