This method should be check if a file is MIME type. To achieve this goal I am using method probeContentType(). However maybe is another way to decide same question. Whic
You can use String mimeType = new MimetypesFileTypeMap().getContentType(theFile);.
String mimeType = new MimetypesFileTypeMap().getContentType(theFile);
Note that if no MIME type is found, application/octet-stream is returned instead of null.
application/octet-stream
null