If some member does not understand an aspect of your team's design, the entire team may be docked studio credit. It is not necessary that all decisions be made with unanimity, but the issues that influece the design one way or the other must be understood by all members of your team.
The examples from lecture are included in your studio repository
For example, instead of representing a given account using an integer, an actual object Account was defined. Similarly, an integer suffices to hold color information for a pixel, but a Color class (type) was defined to provide reliable functionality and to hide details of the implementation (encapsulation).
public void f(int x1, int y1, int x2, int y2) {...}It is easy to forget the order in which the integers must be passed to f. To avoid such chaos and to make the program more readable, articulate a Point object that has an x and y coordinate. The method then becomes
public void f(Point p1, Point p2) {... }
Recall eclipse can generate those for you automatically.It is customary to base the name of such methods consistently on the name of the associated instance variable:
public Person getPerson() { return person; } public void setPerson(Person person) { this.person = person; }
When you done with this studio, you must be cleared by the TA to receive credit.
- Commit all your work to your repository
- Fill in the form below with the relevant information
- Have a TA check your work
- The TA should check your work and then fill in his or her name
- Click OK while the TA watches
- If you request propagation, it does not happen immediately, but should be posted in the next day or so