瀏覽代碼

parts 1-3 ready

yauhenip 6 年之前
父節點
當前提交
ebecc3603d

+ 1
- 0
.idea/.name 查看文件

@@ -0,0 +1 @@
1
+interfaces-1

+ 13
- 0
.idea/compiler.xml 查看文件

@@ -0,0 +1,13 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="CompilerConfiguration">
4
+    <annotationProcessing>
5
+      <profile name="Maven default annotation processors profile" enabled="true">
6
+        <sourceOutputDir name="target/generated-sources/annotations" />
7
+        <sourceTestOutputDir name="target/generated-test-sources/test-annotations" />
8
+        <outputRelativeToContentRoot value="true" />
9
+        <module name="interfaces-1" />
10
+      </profile>
11
+    </annotationProcessing>
12
+  </component>
13
+</project>

+ 6
- 0
.idea/encodings.xml 查看文件

@@ -0,0 +1,6 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="Encoding">
4
+    <file url="file://$PROJECT_DIR$" charset="UTF-8" />
5
+  </component>
6
+</project>

+ 14
- 0
.idea/misc.xml 查看文件

@@ -0,0 +1,14 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="ExternalStorageConfigurationManager" enabled="true" />
4
+  <component name="MavenProjectsManager">
5
+    <option name="originalFiles">
6
+      <list>
7
+        <option value="$PROJECT_DIR$/pom.xml" />
8
+      </list>
9
+    </option>
10
+  </component>
11
+  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
12
+    <output url="file://$PROJECT_DIR$/out" />
13
+  </component>
14
+</project>

+ 6
- 0
.idea/vcs.xml 查看文件

@@ -0,0 +1,6 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="VcsDirectoryMappings">
4
+    <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
+  </component>
6
+</project>

+ 646
- 0
.idea/workspace.xml 查看文件

@@ -0,0 +1,646 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="ChangeListManager">
4
+    <list default="true" id="b687e1df-9808-436a-bc56-89b32f0b6d26" name="Default" comment="">
5
+      <change afterPath="$PROJECT_DIR$/.idea/compiler.xml" afterDir="false" />
6
+      <change afterPath="$PROJECT_DIR$/.idea/encodings.xml" afterDir="false" />
7
+      <change afterPath="$PROJECT_DIR$/.idea/vcs.xml" afterDir="false" />
8
+      <change afterPath="$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Learner.java" afterDir="false" />
9
+      <change afterPath="$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Student.java" afterDir="false" />
10
+      <change afterPath="$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestStudent.java" afterDir="false" />
11
+      <change beforePath="$PROJECT_DIR$/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/pom.xml" afterDir="false" />
12
+      <change beforePath="$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Person.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Person.java" afterDir="false" />
13
+      <change beforePath="$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestPerson.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestPerson.java" afterDir="false" />
14
+    </list>
15
+    <ignored path="$PROJECT_DIR$/target/" />
16
+    <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
17
+    <option name="TRACKING_ENABLED" value="true" />
18
+    <option name="SHOW_DIALOG" value="false" />
19
+    <option name="HIGHLIGHT_CONFLICTS" value="true" />
20
+    <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
21
+    <option name="LAST_RESOLUTION" value="IGNORE" />
22
+  </component>
23
+  <component name="FileEditorManager">
24
+    <leaf>
25
+      <file leaf-file-name="Person.java" pinned="false" current-in-tab="false">
26
+        <entry file="file://$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Person.java">
27
+          <provider selected="true" editor-type-id="text-editor">
28
+            <state relative-caret-position="85">
29
+              <caret line="5" lean-forward="true" selection-start-line="5" selection-end-line="5" />
30
+              <folding>
31
+                <element signature="e#128#129#0" expanded="true" />
32
+                <element signature="e#156#157#0" expanded="true" />
33
+                <element signature="e#184#185#0" expanded="true" />
34
+                <element signature="e#210#211#0" expanded="true" />
35
+                <element signature="e#246#247#0" expanded="true" />
36
+                <element signature="e#276#277#0" expanded="true" />
37
+                <element signature="e#317#318#0" expanded="true" />
38
+                <element signature="e#349#350#0" expanded="true" />
39
+              </folding>
40
+            </state>
41
+          </provider>
42
+        </entry>
43
+      </file>
44
+      <file leaf-file-name="Learner.java" pinned="false" current-in-tab="false">
45
+        <entry file="file://$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Learner.java">
46
+          <provider selected="true" editor-type-id="text-editor">
47
+            <state relative-caret-position="45">
48
+              <caret line="3" column="22" lean-forward="true" selection-start-line="3" selection-start-column="22" selection-end-line="3" selection-end-column="42" />
49
+            </state>
50
+          </provider>
51
+        </entry>
52
+      </file>
53
+      <file leaf-file-name="TestPerson.java" pinned="false" current-in-tab="false">
54
+        <entry file="file://$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestPerson.java">
55
+          <provider selected="true" editor-type-id="text-editor">
56
+            <state relative-caret-position="225">
57
+              <caret line="15" column="4" selection-start-line="15" selection-start-column="4" selection-end-line="22" selection-end-column="5" />
58
+              <folding>
59
+                <element signature="imports" expanded="true" />
60
+              </folding>
61
+            </state>
62
+          </provider>
63
+        </entry>
64
+      </file>
65
+      <file leaf-file-name="Student.java" pinned="false" current-in-tab="false">
66
+        <entry file="file://$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Student.java">
67
+          <provider selected="true" editor-type-id="text-editor">
68
+            <state relative-caret-position="150">
69
+              <caret line="10" column="45" lean-forward="true" selection-start-line="10" selection-start-column="45" selection-end-line="10" selection-end-column="45" />
70
+              <folding>
71
+                <element signature="e#150#151#0" expanded="true" />
72
+                <element signature="e#170#171#0" expanded="true" />
73
+                <element signature="e#225#226#0" expanded="true" />
74
+                <element signature="e#276#277#0" expanded="true" />
75
+                <element signature="e#316#317#0" expanded="true" />
76
+                <element signature="e#353#354#0" expanded="true" />
77
+              </folding>
78
+            </state>
79
+          </provider>
80
+        </entry>
81
+      </file>
82
+      <file leaf-file-name="TestStudent.java" pinned="false" current-in-tab="true">
83
+        <entry file="file://$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestStudent.java">
84
+          <provider selected="true" editor-type-id="text-editor">
85
+            <state relative-caret-position="340">
86
+              <caret line="32" lean-forward="true" selection-start-line="32" selection-end-line="32" />
87
+              <folding>
88
+                <element signature="imports" expanded="true" />
89
+              </folding>
90
+            </state>
91
+          </provider>
92
+        </entry>
93
+      </file>
94
+    </leaf>
95
+  </component>
96
+  <component name="FileTemplateManagerImpl">
97
+    <option name="RECENT_TEMPLATES">
98
+      <list>
99
+        <option value="Interface" />
100
+        <option value="Class" />
101
+      </list>
102
+    </option>
103
+  </component>
104
+  <component name="Git.Settings">
105
+    <option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
106
+  </component>
107
+  <component name="IdeDocumentHistory">
108
+    <option name="CHANGED_PATHS">
109
+      <list>
110
+        <option value="$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Person.java" />
111
+        <option value="$PROJECT_DIR$/pom.xml" />
112
+        <option value="$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestPerson.java" />
113
+        <option value="$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Learner.java" />
114
+        <option value="$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Student.java" />
115
+        <option value="$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestStudent.java" />
116
+      </list>
117
+    </option>
118
+  </component>
119
+  <component name="JsBuildToolGruntFileManager" detection-done="true" sorting="DEFINITION_ORDER" />
120
+  <component name="JsBuildToolPackageJson" detection-done="true" sorting="DEFINITION_ORDER" />
121
+  <component name="JsGulpfileManager">
122
+    <detection-done>true</detection-done>
123
+    <sorting>DEFINITION_ORDER</sorting>
124
+  </component>
125
+  <component name="MavenImportPreferences">
126
+    <option name="importingSettings">
127
+      <MavenImportingSettings>
128
+        <option name="importAutomatically" value="true" />
129
+      </MavenImportingSettings>
130
+    </option>
131
+  </component>
132
+  <component name="NodePackageJsonFileManager">
133
+    <packageJsonPaths />
134
+  </component>
135
+  <component name="ProjectFrameBounds" extendedState="6">
136
+    <option name="y" value="23" />
137
+    <option name="width" value="1440" />
138
+    <option name="height" value="807" />
139
+  </component>
140
+  <component name="ProjectLevelVcsManager" settingsEditedManually="true">
141
+    <ConfirmationsSetting value="2" id="Add" />
142
+  </component>
143
+  <component name="ProjectView">
144
+    <navigator proportions="" version="1">
145
+      <foldersAlwaysOnTop value="true" />
146
+    </navigator>
147
+    <panes>
148
+      <pane id="ProjectPane">
149
+        <subPane>
150
+          <expand>
151
+            <path>
152
+              <item name="interfaces-1" type="b2602c69:ProjectViewProjectNode" />
153
+              <item name="CR-MacroLabs-OOP-InstructorStudentClassroom" type="462c0819:PsiDirectoryNode" />
154
+            </path>
155
+            <path>
156
+              <item name="interfaces-1" type="b2602c69:ProjectViewProjectNode" />
157
+              <item name="CR-MacroLabs-OOP-InstructorStudentClassroom" type="462c0819:PsiDirectoryNode" />
158
+              <item name="src" type="462c0819:PsiDirectoryNode" />
159
+            </path>
160
+            <path>
161
+              <item name="interfaces-1" type="b2602c69:ProjectViewProjectNode" />
162
+              <item name="CR-MacroLabs-OOP-InstructorStudentClassroom" type="462c0819:PsiDirectoryNode" />
163
+              <item name="src" type="462c0819:PsiDirectoryNode" />
164
+              <item name="main" type="462c0819:PsiDirectoryNode" />
165
+            </path>
166
+            <path>
167
+              <item name="interfaces-1" type="b2602c69:ProjectViewProjectNode" />
168
+              <item name="CR-MacroLabs-OOP-InstructorStudentClassroom" type="462c0819:PsiDirectoryNode" />
169
+              <item name="src" type="462c0819:PsiDirectoryNode" />
170
+              <item name="main" type="462c0819:PsiDirectoryNode" />
171
+              <item name="java" type="462c0819:PsiDirectoryNode" />
172
+            </path>
173
+            <path>
174
+              <item name="interfaces-1" type="b2602c69:ProjectViewProjectNode" />
175
+              <item name="CR-MacroLabs-OOP-InstructorStudentClassroom" type="462c0819:PsiDirectoryNode" />
176
+              <item name="src" type="462c0819:PsiDirectoryNode" />
177
+              <item name="main" type="462c0819:PsiDirectoryNode" />
178
+              <item name="java" type="462c0819:PsiDirectoryNode" />
179
+              <item name="interfaces" type="462c0819:PsiDirectoryNode" />
180
+            </path>
181
+            <path>
182
+              <item name="interfaces-1" type="b2602c69:ProjectViewProjectNode" />
183
+              <item name="CR-MacroLabs-OOP-InstructorStudentClassroom" type="462c0819:PsiDirectoryNode" />
184
+              <item name="src" type="462c0819:PsiDirectoryNode" />
185
+              <item name="test" type="462c0819:PsiDirectoryNode" />
186
+            </path>
187
+            <path>
188
+              <item name="interfaces-1" type="b2602c69:ProjectViewProjectNode" />
189
+              <item name="CR-MacroLabs-OOP-InstructorStudentClassroom" type="462c0819:PsiDirectoryNode" />
190
+              <item name="src" type="462c0819:PsiDirectoryNode" />
191
+              <item name="test" type="462c0819:PsiDirectoryNode" />
192
+              <item name="java" type="462c0819:PsiDirectoryNode" />
193
+            </path>
194
+            <path>
195
+              <item name="interfaces-1" type="b2602c69:ProjectViewProjectNode" />
196
+              <item name="CR-MacroLabs-OOP-InstructorStudentClassroom" type="462c0819:PsiDirectoryNode" />
197
+              <item name="src" type="462c0819:PsiDirectoryNode" />
198
+              <item name="test" type="462c0819:PsiDirectoryNode" />
199
+              <item name="java" type="462c0819:PsiDirectoryNode" />
200
+              <item name="interfaces" type="462c0819:PsiDirectoryNode" />
201
+            </path>
202
+          </expand>
203
+          <select />
204
+        </subPane>
205
+      </pane>
206
+      <pane id="Scope" />
207
+      <pane id="AndroidView" />
208
+      <pane id="PackagesPane" />
209
+    </panes>
210
+  </component>
211
+  <component name="PropertiesComponent">
212
+    <property name="WebServerToolWindowFactoryState" value="false" />
213
+    <property name="aspect.path.notification.shown" value="true" />
214
+    <property name="nodejs_interpreter_path.stuck_in_default_project" value="undefined stuck path" />
215
+    <property name="nodejs_npm_path_reset_for_default_project" value="true" />
216
+    <property name="project.structure.last.edited" value="Modules" />
217
+    <property name="project.structure.proportion" value="0.0" />
218
+    <property name="project.structure.side.proportion" value="0.0" />
219
+  </component>
220
+  <component name="RunDashboard">
221
+    <option name="ruleStates">
222
+      <list>
223
+        <RuleState>
224
+          <option name="name" value="ConfigurationTypeDashboardGroupingRule" />
225
+        </RuleState>
226
+        <RuleState>
227
+          <option name="name" value="StatusDashboardGroupingRule" />
228
+        </RuleState>
229
+      </list>
230
+    </option>
231
+  </component>
232
+  <component name="RunManager" selected="JUnit.TestStudent">
233
+    <configuration default="true" type="Application" factoryName="Application">
234
+      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
235
+    </configuration>
236
+    <configuration name="TestPerson" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
237
+      <module name="interfaces-1" />
238
+      <extension name="coverage">
239
+        <pattern>
240
+          <option name="PATTERN" value="io.zipcoder.interfaces.*" />
241
+          <option name="ENABLED" value="true" />
242
+        </pattern>
243
+      </extension>
244
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
245
+      <option name="ALTERNATIVE_JRE_PATH" />
246
+      <option name="PACKAGE_NAME" value="io.zipcoder.interfaces" />
247
+      <option name="MAIN_CLASS_NAME" value="io.zipcoder.interfaces.TestPerson" />
248
+      <option name="METHOD_NAME" />
249
+      <option name="TEST_OBJECT" value="class" />
250
+      <option name="VM_PARAMETERS" value="-ea" />
251
+      <option name="PARAMETERS" />
252
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
253
+      <option name="PASS_PARENT_ENVS" value="true" />
254
+      <option name="TEST_SEARCH_SCOPE">
255
+        <value defaultName="singleModule" />
256
+      </option>
257
+      <patterns />
258
+    </configuration>
259
+    <configuration name="TestStudent" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
260
+      <module name="interfaces-1" />
261
+      <extension name="coverage">
262
+        <pattern>
263
+          <option name="PATTERN" value="io.zipcoder.interfaces.*" />
264
+          <option name="ENABLED" value="true" />
265
+        </pattern>
266
+      </extension>
267
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
268
+      <option name="ALTERNATIVE_JRE_PATH" />
269
+      <option name="PACKAGE_NAME" value="io.zipcoder.interfaces" />
270
+      <option name="MAIN_CLASS_NAME" value="io.zipcoder.interfaces.TestStudent" />
271
+      <option name="METHOD_NAME" />
272
+      <option name="TEST_OBJECT" value="class" />
273
+      <option name="VM_PARAMETERS" value="-ea" />
274
+      <option name="PARAMETERS" />
275
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
276
+      <option name="PASS_PARENT_ENVS" value="true" />
277
+      <option name="TEST_SEARCH_SCOPE">
278
+        <value defaultName="singleModule" />
279
+      </option>
280
+      <patterns />
281
+    </configuration>
282
+    <configuration name="TestStudent.testConstructor" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
283
+      <module name="interfaces-1" />
284
+      <extension name="coverage">
285
+        <pattern>
286
+          <option name="PATTERN" value="io.zipcoder.interfaces.*" />
287
+          <option name="ENABLED" value="true" />
288
+        </pattern>
289
+      </extension>
290
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
291
+      <option name="ALTERNATIVE_JRE_PATH" />
292
+      <option name="PACKAGE_NAME" value="io.zipcoder.interfaces" />
293
+      <option name="MAIN_CLASS_NAME" value="io.zipcoder.interfaces.TestStudent" />
294
+      <option name="METHOD_NAME" value="testConstructor" />
295
+      <option name="TEST_OBJECT" value="method" />
296
+      <option name="VM_PARAMETERS" value="-ea" />
297
+      <option name="PARAMETERS" />
298
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
299
+      <option name="PASS_PARENT_ENVS" value="true" />
300
+      <option name="TEST_SEARCH_SCOPE">
301
+        <value defaultName="singleModule" />
302
+      </option>
303
+      <patterns />
304
+    </configuration>
305
+    <configuration name="TestStudent.testImplementation" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
306
+      <module name="interfaces-1" />
307
+      <extension name="coverage">
308
+        <pattern>
309
+          <option name="PATTERN" value="io.zipcoder.interfaces.*" />
310
+          <option name="ENABLED" value="true" />
311
+        </pattern>
312
+      </extension>
313
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
314
+      <option name="ALTERNATIVE_JRE_PATH" />
315
+      <option name="PACKAGE_NAME" value="io.zipcoder.interfaces" />
316
+      <option name="MAIN_CLASS_NAME" value="io.zipcoder.interfaces.TestStudent" />
317
+      <option name="METHOD_NAME" value="testImplementation" />
318
+      <option name="TEST_OBJECT" value="method" />
319
+      <option name="VM_PARAMETERS" value="-ea" />
320
+      <option name="PARAMETERS" />
321
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
322
+      <option name="PASS_PARENT_ENVS" value="true" />
323
+      <option name="TEST_SEARCH_SCOPE">
324
+        <value defaultName="singleModule" />
325
+      </option>
326
+      <patterns />
327
+    </configuration>
328
+    <configuration name="TestStudent.testInheritance" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
329
+      <module name="interfaces-1" />
330
+      <extension name="coverage">
331
+        <pattern>
332
+          <option name="PATTERN" value="io.zipcoder.interfaces.*" />
333
+          <option name="ENABLED" value="true" />
334
+        </pattern>
335
+      </extension>
336
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
337
+      <option name="ALTERNATIVE_JRE_PATH" />
338
+      <option name="PACKAGE_NAME" value="io.zipcoder.interfaces" />
339
+      <option name="MAIN_CLASS_NAME" value="io.zipcoder.interfaces.TestStudent" />
340
+      <option name="METHOD_NAME" value="testInheritance" />
341
+      <option name="TEST_OBJECT" value="method" />
342
+      <option name="VM_PARAMETERS" value="-ea" />
343
+      <option name="PARAMETERS" />
344
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
345
+      <option name="PASS_PARENT_ENVS" value="true" />
346
+      <option name="TEST_SEARCH_SCOPE">
347
+        <value defaultName="singleModule" />
348
+      </option>
349
+      <patterns />
350
+    </configuration>
351
+    <configuration default="true" type="JUnit" factoryName="JUnit">
352
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
353
+      <option name="ALTERNATIVE_JRE_PATH" />
354
+      <option name="PACKAGE_NAME" />
355
+      <option name="MAIN_CLASS_NAME" />
356
+      <option name="METHOD_NAME" />
357
+      <option name="TEST_OBJECT" value="class" />
358
+      <option name="VM_PARAMETERS" value="-ea" />
359
+      <option name="PARAMETERS" />
360
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
361
+      <option name="PASS_PARENT_ENVS" value="true" />
362
+      <option name="TEST_SEARCH_SCOPE">
363
+        <value defaultName="singleModule" />
364
+      </option>
365
+      <patterns />
366
+    </configuration>
367
+    <configuration default="true" type="TestNG" factoryName="TestNG">
368
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
369
+      <option name="ALTERNATIVE_JRE_PATH" />
370
+      <option name="SUITE_NAME" />
371
+      <option name="PACKAGE_NAME" />
372
+      <option name="MAIN_CLASS_NAME" />
373
+      <option name="METHOD_NAME" />
374
+      <option name="GROUP_NAME" />
375
+      <option name="TEST_OBJECT" value="CLASS" />
376
+      <option name="VM_PARAMETERS" value="-ea" />
377
+      <option name="PARAMETERS" />
378
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
379
+      <option name="OUTPUT_DIRECTORY" />
380
+      <option name="PASS_PARENT_ENVS" value="true" />
381
+      <option name="TEST_SEARCH_SCOPE">
382
+        <value defaultName="singleModule" />
383
+      </option>
384
+      <option name="USE_DEFAULT_REPORTERS" value="false" />
385
+      <option name="PROPERTIES_FILE" />
386
+      <properties />
387
+      <listeners />
388
+    </configuration>
389
+    <list>
390
+      <item itemvalue="JUnit.TestPerson" />
391
+      <item itemvalue="JUnit.TestStudent.testConstructor" />
392
+      <item itemvalue="JUnit.TestStudent.testImplementation" />
393
+      <item itemvalue="JUnit.TestStudent.testInheritance" />
394
+      <item itemvalue="JUnit.TestStudent" />
395
+    </list>
396
+    <recent_temporary>
397
+      <list>
398
+        <item itemvalue="JUnit.TestStudent" />
399
+        <item itemvalue="JUnit.TestPerson" />
400
+        <item itemvalue="JUnit.TestStudent.testImplementation" />
401
+        <item itemvalue="JUnit.TestStudent.testInheritance" />
402
+        <item itemvalue="JUnit.TestStudent.testConstructor" />
403
+      </list>
404
+    </recent_temporary>
405
+  </component>
406
+  <component name="SvnConfiguration">
407
+    <configuration />
408
+  </component>
409
+  <component name="TaskManager">
410
+    <task active="true" id="Default" summary="Default task">
411
+      <changelist id="b687e1df-9808-436a-bc56-89b32f0b6d26" name="Default" comment="" />
412
+      <created>1529197757236</created>
413
+      <option name="number" value="Default" />
414
+      <option name="presentableId" value="Default" />
415
+      <updated>1529197757236</updated>
416
+      <workItem from="1529197758758" duration="2575000" />
417
+    </task>
418
+    <servers />
419
+  </component>
420
+  <component name="TestHistory">
421
+    <history-entry file="TestPerson_testConstructor - 2018.06.16 at 21h 23m 53s.xml">
422
+      <configuration name="TestPerson.testConstructor" configurationId="JUnit" />
423
+    </history-entry>
424
+    <history-entry file="TestPerson_testSetName - 2018.06.16 at 21h 25m 32s.xml">
425
+      <configuration name="TestPerson.testSetName" configurationId="JUnit" />
426
+    </history-entry>
427
+    <history-entry file="TestPerson - 2018.06.16 at 21h 25m 37s.xml">
428
+      <configuration name="TestPerson" configurationId="JUnit" />
429
+    </history-entry>
430
+    <history-entry file="TestStudent_testConstructor - 2018.06.16 at 21h 45m 29s.xml">
431
+      <configuration name="TestStudent.testConstructor" configurationId="JUnit" />
432
+    </history-entry>
433
+    <history-entry file="TestStudent_testConstructor - 2018.06.16 at 21h 45m 40s.xml">
434
+      <configuration name="TestStudent.testConstructor" configurationId="JUnit" />
435
+    </history-entry>
436
+    <history-entry file="TestStudent_testImplementation - 2018.06.16 at 21h 47m 06s.xml">
437
+      <configuration name="TestStudent.testImplementation" configurationId="JUnit" />
438
+    </history-entry>
439
+    <history-entry file="TestStudent_testInheritance - 2018.06.16 at 21h 47m 10s.xml">
440
+      <configuration name="TestStudent.testInheritance" configurationId="JUnit" />
441
+    </history-entry>
442
+  </component>
443
+  <component name="TimeTrackingManager">
444
+    <option name="totallyTimeSpent" value="2575000" />
445
+  </component>
446
+  <component name="ToolWindowManager">
447
+    <frame x="0" y="23" width="1440" height="807" extended-state="6" />
448
+    <editor active="true" />
449
+    <layout>
450
+      <window_info anchor="right" id="Palette" />
451
+      <window_info anchor="bottom" id="TODO" order="6" />
452
+      <window_info anchor="bottom" id="Messages" visible="true" weight="0.32957748" />
453
+      <window_info anchor="right" id="Palette&#9;" />
454
+      <window_info id="Image Layers" />
455
+      <window_info anchor="right" id="Capture Analysis" />
456
+      <window_info anchor="bottom" id="Event Log" side_tool="true" />
457
+      <window_info anchor="right" id="Maven Projects" />
458
+      <window_info anchor="bottom" id="Database Changes" show_stripe_button="false" />
459
+      <window_info anchor="bottom" id="Run" order="2" weight="0.32957748" />
460
+      <window_info anchor="bottom" id="Version Control" />
461
+      <window_info anchor="bottom" id="Terminal" />
462
+      <window_info id="Capture Tool" />
463
+      <window_info id="Designer" />
464
+      <window_info active="true" content_ui="combo" id="Project" order="0" visible="true" weight="0.24964234" />
465
+      <window_info anchor="right" id="Database" />
466
+      <window_info id="Structure" order="1" side_tool="true" weight="0.25" />
467
+      <window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
468
+      <window_info id="UI Designer" />
469
+      <window_info anchor="right" id="Theme Preview" />
470
+      <window_info anchor="bottom" id="Debug" order="3" weight="0.4" />
471
+      <window_info id="Favorites" side_tool="true" />
472
+      <window_info anchor="bottom" id="Find" order="1" />
473
+      <window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" />
474
+      <window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
475
+      <window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
476
+      <window_info anchor="bottom" id="Message" order="0" />
477
+      <window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
478
+    </layout>
479
+  </component>
480
+  <component name="TypeScriptGeneratedFilesManager">
481
+    <option name="version" value="1" />
482
+  </component>
483
+  <component name="VcsContentAnnotationSettings">
484
+    <option name="myLimit" value="2678400000" />
485
+  </component>
486
+  <component name="XDebuggerManager">
487
+    <breakpoint-manager>
488
+      <option name="time" value="1" />
489
+    </breakpoint-manager>
490
+  </component>
491
+  <component name="editorHistoryManager">
492
+    <entry file="file://$PROJECT_DIR$/pom.xml">
493
+      <provider selected="true" editor-type-id="text-editor">
494
+        <state relative-caret-position="345">
495
+          <caret line="23" column="10" selection-start-line="23" selection-start-column="10" selection-end-line="23" selection-end-column="10" />
496
+        </state>
497
+      </provider>
498
+    </entry>
499
+    <entry file="file://$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Learner.java">
500
+      <provider selected="true" editor-type-id="text-editor">
501
+        <state relative-caret-position="45">
502
+          <caret line="3" column="22" lean-forward="true" selection-start-line="3" selection-start-column="22" selection-end-line="3" selection-end-column="42" />
503
+        </state>
504
+      </provider>
505
+    </entry>
506
+    <entry file="file://$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestPerson.java">
507
+      <provider selected="true" editor-type-id="text-editor">
508
+        <state relative-caret-position="225">
509
+          <caret line="15" column="4" selection-start-line="15" selection-start-column="4" selection-end-line="22" selection-end-column="5" />
510
+          <folding>
511
+            <element signature="imports" expanded="true" />
512
+          </folding>
513
+        </state>
514
+      </provider>
515
+    </entry>
516
+    <entry file="file://$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Person.java">
517
+      <provider selected="true" editor-type-id="text-editor">
518
+        <state relative-caret-position="85">
519
+          <caret line="5" lean-forward="true" selection-start-line="5" selection-end-line="5" />
520
+          <folding>
521
+            <element signature="e#128#129#0" expanded="true" />
522
+            <element signature="e#156#157#0" expanded="true" />
523
+            <element signature="e#184#185#0" expanded="true" />
524
+            <element signature="e#210#211#0" expanded="true" />
525
+            <element signature="e#246#247#0" expanded="true" />
526
+            <element signature="e#276#277#0" expanded="true" />
527
+            <element signature="e#317#318#0" expanded="true" />
528
+            <element signature="e#349#350#0" expanded="true" />
529
+          </folding>
530
+        </state>
531
+      </provider>
532
+    </entry>
533
+    <entry file="file://$PROJECT_DIR$/src/main/java/io/zipcoder/interfaces/Student.java">
534
+      <provider selected="true" editor-type-id="text-editor">
535
+        <state relative-caret-position="150">
536
+          <caret line="10" column="45" lean-forward="true" selection-start-line="10" selection-start-column="45" selection-end-line="10" selection-end-column="45" />
537
+          <folding>
538
+            <element signature="e#150#151#0" expanded="true" />
539
+            <element signature="e#170#171#0" expanded="true" />
540
+            <element signature="e#225#226#0" expanded="true" />
541
+            <element signature="e#276#277#0" expanded="true" />
542
+            <element signature="e#316#317#0" expanded="true" />
543
+            <element signature="e#353#354#0" expanded="true" />
544
+          </folding>
545
+        </state>
546
+      </provider>
547
+    </entry>
548
+    <entry file="file://$PROJECT_DIR$/src/test/java/io/zipcoder/interfaces/TestStudent.java">
549
+      <provider selected="true" editor-type-id="text-editor">
550
+        <state relative-caret-position="340">
551
+          <caret line="32" lean-forward="true" selection-start-line="32" selection-end-line="32" />
552
+          <folding>
553
+            <element signature="imports" expanded="true" />
554
+          </folding>
555
+        </state>
556
+      </provider>
557
+    </entry>
558
+  </component>
559
+  <component name="masterDetails">
560
+    <states>
561
+      <state key="ArtifactsStructureConfigurable.UI">
562
+        <settings>
563
+          <artifact-editor />
564
+          <splitter-proportions>
565
+            <option name="proportions">
566
+              <list>
567
+                <option value="0.2" />
568
+              </list>
569
+            </option>
570
+          </splitter-proportions>
571
+        </settings>
572
+      </state>
573
+      <state key="FacetStructureConfigurable.UI">
574
+        <settings>
575
+          <last-edited>No facets are configured</last-edited>
576
+          <splitter-proportions>
577
+            <option name="proportions">
578
+              <list>
579
+                <option value="0.2" />
580
+              </list>
581
+            </option>
582
+          </splitter-proportions>
583
+        </settings>
584
+      </state>
585
+      <state key="GlobalLibrariesConfigurable.UI">
586
+        <settings>
587
+          <splitter-proportions>
588
+            <option name="proportions">
589
+              <list>
590
+                <option value="0.2" />
591
+              </list>
592
+            </option>
593
+          </splitter-proportions>
594
+        </settings>
595
+      </state>
596
+      <state key="JdkListConfigurable.UI">
597
+        <settings>
598
+          <last-edited>1.8</last-edited>
599
+          <splitter-proportions>
600
+            <option name="proportions">
601
+              <list>
602
+                <option value="0.2" />
603
+              </list>
604
+            </option>
605
+          </splitter-proportions>
606
+        </settings>
607
+      </state>
608
+      <state key="ModuleStructureConfigurable.UI">
609
+        <settings>
610
+          <last-edited>interfaces-1</last-edited>
611
+          <splitter-proportions>
612
+            <option name="proportions">
613
+              <list>
614
+                <option value="0.2" />
615
+              </list>
616
+            </option>
617
+          </splitter-proportions>
618
+        </settings>
619
+      </state>
620
+      <state key="ProjectJDKs.UI">
621
+        <settings>
622
+          <last-edited>1.8</last-edited>
623
+          <splitter-proportions>
624
+            <option name="proportions">
625
+              <list>
626
+                <option value="0.2" />
627
+              </list>
628
+            </option>
629
+          </splitter-proportions>
630
+        </settings>
631
+      </state>
632
+      <state key="ProjectLibrariesConfigurable.UI">
633
+        <settings>
634
+          <last-edited>Maven: junit:junit:4.12</last-edited>
635
+          <splitter-proportions>
636
+            <option name="proportions">
637
+              <list>
638
+                <option value="0.2" />
639
+              </list>
640
+            </option>
641
+          </splitter-proportions>
642
+        </settings>
643
+      </state>
644
+    </states>
645
+  </component>
646
+</project>

+ 0
- 1
pom.xml 查看文件

@@ -19,7 +19,6 @@
19 19
       <groupId>junit</groupId>
20 20
       <artifactId>junit</artifactId>
21 21
       <version>4.12</version>
22
-      <scope>test</scope>
23 22
     </dependency>
24 23
   </dependencies>
25 24
 </project>

+ 5
- 0
src/main/java/io/zipcoder/interfaces/Learner.java 查看文件

@@ -0,0 +1,5 @@
1
+package io.zipcoder.interfaces;
2
+
3
+public interface Learner {
4
+    public void learn(double numberOfHours);
5
+}

+ 19
- 0
src/main/java/io/zipcoder/interfaces/Person.java 查看文件

@@ -1,5 +1,24 @@
1 1
 package io.zipcoder.interfaces;
2 2
 
3 3
 public class Person {
4
+    final long id;
5
+    private String name;
6
+
7
+    public Person(long id) {
8
+        this.id = id;
9
+    }
10
+
11
+    public long getId() {
12
+        return this.id;
13
+    }
14
+
15
+    public String getName() {
16
+        return this.name;
17
+    }
18
+
19
+    public void setName(String name) {
20
+        this.name = name;
21
+    }
22
+
4 23
 
5 24
 }

+ 17
- 0
src/main/java/io/zipcoder/interfaces/Student.java 查看文件

@@ -0,0 +1,17 @@
1
+package io.zipcoder.interfaces;
2
+
3
+public class Student extends Person implements Learner{
4
+    private double totalStudyTime;
5
+
6
+    public Student(long id) {
7
+        super(id);
8
+    }
9
+
10
+    public void learn(double numberOfHours) {
11
+        this.totalStudyTime += numberOfHours;
12
+    }
13
+
14
+    public double getTotalStudyTime() {
15
+        return totalStudyTime;
16
+    }
17
+}

+ 19
- 0
src/test/java/io/zipcoder/interfaces/TestPerson.java 查看文件

@@ -1,5 +1,24 @@
1 1
 package io.zipcoder.interfaces;
2 2
 
3
+import org.junit.Test;
4
+import static org.junit.Assert.assertEquals;
5
+
3 6
 public class TestPerson {
4 7
 
8
+    @Test
9
+    public void testConstructor() {
10
+        Person prsn = new Person(1);
11
+        long expected = 1;
12
+        long actual = prsn.getId();
13
+        assertEquals(expected, actual);
14
+    }
15
+
16
+    @Test
17
+    public void testSetName() {
18
+        Person prsn = new Person(1);
19
+        prsn.setName("Joshua");
20
+        String expected = "Joshua";
21
+        String actual = prsn.getName();
22
+        assertEquals(expected, actual);
23
+    }
5 24
 }

+ 32
- 0
src/test/java/io/zipcoder/interfaces/TestStudent.java 查看文件

@@ -0,0 +1,32 @@
1
+package io.zipcoder.interfaces;
2
+
3
+import org.junit.Test;
4
+
5
+import static org.hamcrest.core.IsInstanceOf.instanceOf;
6
+import static org.junit.Assert.assertEquals;
7
+import static org.junit.Assert.assertThat;
8
+
9
+public class TestStudent {
10
+
11
+    @Test
12
+    public void testImplementation() {
13
+        Student stdnt = new Student(5);
14
+        assertThat(stdnt, instanceOf(Learner.class));
15
+    }
16
+
17
+    @Test
18
+    public void testInheritance() {
19
+        Student stdnt = new Student(5);
20
+        assertThat(stdnt, instanceOf(Person.class));
21
+    }
22
+
23
+    @Test
24
+    public void testLearn() {
25
+        Student prsn = new Student(1);
26
+        prsn.learn(18);
27
+        prsn.learn(10);
28
+        double expected = 28;
29
+        double actual = prsn.getTotalStudyTime();
30
+        assertEquals(expected, actual, 1e-9);
31
+    }
32
+}