Explorar el Código

updated main application

William Simkins hace 6 años
padre
commit
5c1ea41c01
Se han modificado 2 ficheros con 64 adiciones y 15 borrados
  1. 4
    4
      MainApplication.java
  2. 60
    11
      package.bluej

+ 4
- 4
MainApplication.java Ver fichero

@@ -13,11 +13,11 @@ public class MainApplication {
13 13
         int petNumber = scanner.nextInt();
14 14
         
15 15
         for(int i = 1; i <= petNumber; i++){
16
-        System.out.println("What kind of pet do you have?");
17
-        String petKind = scanner.nextLine();
16
+            System.out.println("What kind of pet do you have?");
17
+            String petKind = scanner.next();
18 18
         
19
-        System.out.println("What is your pets' name?");
20
-        String petName = scanner.nextLine();
19
+            System.out.println("What is your pets' name?");
20
+            String petName = scanner.next();
21 21
         
22 22
          if(petKind.equalsIgnoreCase("cat")){
23 23
              Cat cat = new Cat();

+ 60
- 11
package.bluej Ver fichero

@@ -1,20 +1,41 @@
1 1
 #BlueJ package file
2
+dependency1.from=MainApplicationTest
3
+dependency1.to=Dog
4
+dependency1.type=UsesDependency
5
+dependency2.from=MainApplicationTest
6
+dependency2.to=Cat
7
+dependency2.type=UsesDependency
8
+dependency3.from=MainApplicationTest
9
+dependency3.to=Cow
10
+dependency3.type=UsesDependency
11
+dependency4.from=MainApplication
12
+dependency4.to=Pet
13
+dependency4.type=UsesDependency
14
+dependency5.from=MainApplication
15
+dependency5.to=Cat
16
+dependency5.type=UsesDependency
17
+dependency6.from=MainApplication
18
+dependency6.to=Dog
19
+dependency6.type=UsesDependency
20
+dependency7.from=MainApplication
21
+dependency7.to=Cow
22
+dependency7.type=UsesDependency
2 23
 editor.fx.0.height=722
3 24
 editor.fx.0.width=800
4
-editor.fx.0.x=480
5
-editor.fx.0.y=30
25
+editor.fx.0.x=399
26
+editor.fx.0.y=26
6 27
 objectbench.height=164
7 28
 objectbench.width=776
8 29
 package.divider.horizontal=0.6
9 30
 package.divider.vertical=0.6845018450184502
10 31
 package.editor.height=364
11 32
 package.editor.width=674
12
-package.editor.x=221
13
-package.editor.y=129
33
+package.editor.x=122
34
+package.editor.y=104
14 35
 package.frame.height=600
15 36
 package.frame.width=800
16
-package.numDependencies=0
17
-package.numTargets=2
37
+package.numDependencies=7
38
+package.numTargets=6
18 39
 package.showExtends=true
19 40
 package.showUses=true
20 41
 project.charset=UTF-8
@@ -26,14 +47,42 @@ readme.y=10
26 47
 target1.height=50
27 48
 target1.name=MainApplicationTest
28 49
 target1.showInterface=false
29
-target1.type=ClassTarget
50
+target1.type=UnitTestTargetJunit4
30 51
 target1.width=150
31 52
 target1.x=130
32 53
 target1.y=10
33 54
 target2.height=50
34
-target2.name=MainApplication
55
+target2.name=Cat
35 56
 target2.showInterface=false
36 57
 target2.type=ClassTarget
37
-target2.width=120
38
-target2.x=70
39
-target2.y=70
58
+target2.width=80
59
+target2.x=260
60
+target2.y=260
61
+target3.height=50
62
+target3.name=Cow
63
+target3.showInterface=false
64
+target3.type=ClassTarget
65
+target3.width=80
66
+target3.x=370
67
+target3.y=260
68
+target4.height=50
69
+target4.name=Dog
70
+target4.showInterface=false
71
+target4.type=ClassTarget
72
+target4.width=80
73
+target4.x=160
74
+target4.y=260
75
+target5.height=50
76
+target5.name=Pet
77
+target5.showInterface=false
78
+target5.type=ClassTarget
79
+target5.width=80
80
+target5.x=260
81
+target5.y=150
82
+target6.height=50
83
+target6.name=MainApplication
84
+target6.showInterface=false
85
+target6.type=ClassTarget
86
+target6.width=120
87
+target6.x=70
88
+target6.y=70