20165332 experiment two Java object-oriented programming
Experimental Content
Initial mastery of unit testing and TDD
Understanding and mastering object-oriented three elements: encapsulation, inheritance, polymorphism
Initial mastery of UML modeling
Familiarity with S.O.L.I.D principles
Understanding Design Patterns
Experimental Requirements
Students who do not have a Linux base are advised to start with the Linux basics (new version) Vim Editor course
Complete the experiment, write the experiment Report, the experiment report is published in the blog Garden, note that the experimental report is focused on the running results, the problems encountered (tool search, installation, use, program editing, debugging, running, etc.), solutions (empty methods such as "Check Network", "Ask classmates", "reading" 0 points) as well as analysis (what can be learned from it, what gains, lessons, etc.). The report can refer to the guidance of Fan Fei Dragon Teacher
Plagiarism is strictly forbidden, and the results of the experiment of the perpetrator are zero, and other punitive measures are added.
Experiment
I. Object-oriented Programming-1
Checkpoint Requirements:
Reference Http://www.cnblogs.com/rocedu/p/6371315.html#SECUNITTEST
Reference http://www.cnblogs.com/rocedu/p/6736847.html
Submit the last three test cases are passed, to have paint and watermark, enter their own school number.
Ii. Object-Oriented programming-2
Checkpoint Requirements:
Refer to Active knock code, using JUnit to learn Java (http://www.cnblogs.com/rocedu/p/4837092.html)
Reference http://www.cnblogs.com/rocedu/p/6736847.html
Study StringBuffer in TDD, submit your unit test case and test pass, add the number watermark.
Third, object-oriented programming-3
Checkpoint Requirements
Reference http://www.cnblogs.com/rocedu/p/6736847.html
Extend the design pattern example, experience the application of OCP principle and dip principle, understand the design pattern preliminarily
Let the system support the Boolean class, and add the test code in the MyDoc class to indicate the correct addition, submit the test code and run knot, plus the number watermark
Four, object-oriented programming-4
Checkpoint Requirements
Submit: Unit test code and run success and code on the cloud Codes link, to add the number watermark
Reference http://www.cnblogs.com/rocedu/p/6736847.html
Task: Developing a plural class complex in TDD, with the following requirements:
Define properties and generate Getter,setter
Double Realpart;
Double Imagepart;
Defining constructors
Public Complex ()
Public Complex (double r,double I)
Override Object
public boolean equals (Object obj)
Public String toString ()
Define public methods: subtraction
Complex Complexadd (Complex a)
Complex complexsub (Complex a)
Complex Complexmulti (Complex a)
Complex Complexdiv (Complex a)
Code Cloud Link: Https://gitee.com/BESTI-IS-JAVA-2018/20165332YanYiZhuo/tree/master/src/%E5%AE%9E%E9%AA%8C%E4%BA%8C
V. Object-Oriented Programming-5
Checkpoint Requirements
Use WHITESTARUML to model the code in experiment two, send class diagram, plus number watermark.
Reference http://www.cnblogs.com/rocedu/p/6736847.html
There are only two classes in a class diagram.
Code Cloud Link: Https://gitee.com/BESTI-IS-JAVA-2018/20165332YanYiZhuo/tree/master/src/%E5%AE%9E%E9%AA%8C%E4%BA%8C
20165332 experiment two Java object-oriented programming