Posts

Showing posts with the label File

Simple file manager app

Very simple console based file manager application. Just an exercise for file system handling. Created on: Jan 23, 2017. Main.java 1: import java.util.Scanner; 2: 3: public class Main { 4: 5: public static void main(String[] args) { 6: 7: System.out.println("LIST, INFO, CREATE_DIR, RENAME, COPY, MOVE, DELETE"); 8: System.out.print("Select the desired operation: "); 9: Scanner s = new Scanner (System.in); 10: String input = s.nextLine(); 11: 12: try { 13: Operacije op = Operacije.valueOf(input); 14: System.out.print("Operation accepted "); 15: switch (op){ 16: case LIST : 17: Manipulacije.list(); 18: break; 19: case INFO : 20: Manipulacije.info(); 21: break; 22: case CREATE_DIR : 23: Manipulacije.createDir(); 24: break; 25: case RENAME :...