Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public boolean check(File fileCheck) {
- try {
- Path filePath = FileSystems.getDefault().getPath(
- fileCheck.getAbsolutePath());
- if ((Files.probeContentType(filePath) == null)) {
- return false;
- }
- } catch (IOException e) {
- e.printStackTrace();
- }
- return true;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement