|
@ -1,18 +1,22 @@ |
|
|
package antoniofrische.com; |
|
|
package antoniofrische.com; |
|
|
|
|
|
|
|
|
import java.io.IOException; |
|
|
import java.io.IOException; |
|
|
|
|
|
import java.util.Date; |
|
|
import java.io.File; |
|
|
import java.io.File; |
|
|
|
|
|
|
|
|
public class mkDirFuction { |
|
|
public class mkDirFuction { |
|
|
public static File direct = new File("C:\\Users\\AntonioFrische\\OneDrive - ABACCO Solutions\\Documents\\Schule_22_23_CFGS\\Acceso_Datos\\SpringTool_4"); |
|
|
public static File direct = new File("C:\\Users\\AntonioFrische\\OneDrive - ABACCO Solutions\\Documents\\Schule_22_23_CFGS\\Acceso_Datos\\SpringTool_4"); |
|
|
public static void main(String args[]) { |
|
|
public static void main(String args[]) { |
|
|
File[] dirList = direct.listFiles(); |
|
|
File[] dirList = direct.listFiles(); |
|
|
|
|
|
System.out.println("--R----W----E-- LastWrite Time lenght name"); |
|
|
for(int i = 0; i < dirList.length; i++) { |
|
|
for(int i = 0; i < dirList.length; i++) { |
|
|
if(dirList[i].isDirectory()) { |
|
|
|
|
|
System.out.println("Dic: "+dirList[i]); |
|
|
|
|
|
}else { |
|
|
|
|
|
System.out.println("Archivo: "+dirList[i]); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
System.out.print(dirList[i].canRead()+" "); |
|
|
|
|
|
System.out.print(dirList[i].canWrite()+ " "); |
|
|
|
|
|
System.out.print(dirList[i].canExecute()+" "); |
|
|
|
|
|
System.out.print(new Date(dirList[i].lastModified())+" "); |
|
|
|
|
|
System.out.print(dirList[i].length()+" "); |
|
|
|
|
|
System.out.print(dirList[i].getName()); |
|
|
|
|
|
System.out.println(); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |