Java7: Vérifier si un fichier est exécutable

Author:

 int,string,char,static, url, socket, url, socket, java
Download

/**
 * @(#)ExecutableFile.java
 *
 *
 * @author 
 * @version 1.00 2012/12/11
 */
 
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.FileSystems;
 
public class ExecutableFile {
 
    public static void main (String[] args) 
    {
    	Path path = FileSystems.getDefault().getPath("c:/users.txt");
    	System.out.println ("Fichier est il exécutable? "+Files.isExecutable(path));
    }
 
}

Cet article Java7: Vérifier si un fichier est exécutable est apparu en premier sur .