-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathUserFileRunner.java
More file actions
129 lines (83 loc) · 2.69 KB
/
Copy pathUserFileRunner.java
File metadata and controls
129 lines (83 loc) · 2.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
package FsdProject;
import java.util.Scanner;
public class UserFileRunner {
UserFileRunner Userfiles;
public static void main(String[] args) {
UserFileRunner userfilesrunner =new UserFileRunner();
userfilesrunner.MainMenu();
}
public void MainMenu() {
System.out.println("Main Menu");
Userfiles = new UserFileRunner();
this.Userfiles.createDirectory();
try (Scanner input = new Scanner(System.in)) {
int mainSelection;
System.out.println("*************************************SIMPLILEARN*********************************************");
System.out.println("**********************************FSD PHASE1 PROJECT**********************************************");
System.out.println("**********************************Bhabananda Prusty***********************************************************");
System.out.println();
do {
System.out.println("Choose from the below options");
System.out.println("1.Display the File Names in Ascending Order");
System.out.println("2.Display User Interface Menu");
System.out.println("3.Exit");
mainSelection = input.nextInt();
switch(mainSelection) {
case 1:
Userfiles.listFilesinAscendingOrder();
break;
case 2:
System.out.println("Option 2 selected");
userInterfaceMenu();
break; case 3:
System.out.println("Thank You for using our Application");
System.exit(0);
break;
default:
System.out.println("Wrong option");
}
}while(mainSelection!=3);
}
}
private void createDirectory() {
// TODO Auto-generated method stub
}
private void listFilesinAscendingOrder() {
// TODO Auto-generated method stub
}
public void userInterfaceMenu() {
try (Scanner input = new Scanner(System.in)) {
int selection;
do {
System.out.println("***************USER INTERFACE MENU**************");
System.out.println("Choose from the below options");
System.out.println("1.Add a user specified file to the application");
System.out.println("2.Delete a user specified file from the application");
System.out.println("3.Search for a user specified file from the application");
System.out.println("4.Back to Main Menu");
selection = input.nextInt();
switch(selection) {
case 1:
this.Userfiles.createuserFile();
break;
case 2:
System.out.println("Option 2 Selected");
this.Userfiles.createuserFile(); break;
case 3:
System.out.println("Option 3 Selected");
this.Userfiles.searchFile(); break;
case 4:
MainMenu();
default:
System.out.println("Wrong Option Selected");
}
}while(selection!=4);
}
}
private void searchFile() {
// TODO Auto-generated method stub
}
private void createuserFile() {
// TODO Auto-generated method stub
}
}