Reformatted doctring and import statements

This commit is contained in:
Haoming Yin
2017-03-08 14:45:06 +13:00
parent 245fbc75c2
commit b0cd7c8c08
17 changed files with 773 additions and 722 deletions
+51 -47
View File
@@ -1,56 +1,60 @@
package seng302;
/**
* Represents a boat in the race.
*
* @param teamName The name of the team sailing the boat
* @param boatVelocity The speed of the boat in meters/second
*/
public class Boat
{
private String teamName; // The name of the team, this is also the name of the boat
private double velocity; // In meters/second
public Boat(String teamName) {
this.teamName = teamName;
this.velocity = 10; // Default velocity
}
public class Boat {
public Boat(String teamName, double boatVelocity) {
this.teamName = teamName;
this.velocity = boatVelocity;
}
private String teamName; // The name of the team, this is also the name of the boat
private double velocity; // In meters/second
/**
* Returns the name of the team sailing the boat
* @return The name of the team
*/
public String getTeamName(){
return this.teamName;
}
public Boat(String teamName) {
this.teamName = teamName;
this.velocity = 10; // Default velocity
}
/**
* Sets the name of the team sailing the boat
* @param teamName The name of the team
*/
public void setTeamName(String teamName){
this.teamName = teamName;
}
/**
* Represents a boat in the race.
*
* @param teamName The name of the team sailing the boat
* @param boatVelocity The speed of the boat in meters/second
*/
public Boat(String teamName, double boatVelocity) {
this.teamName = teamName;
this.velocity = boatVelocity;
}
/**
* Sets velocity of the boat
* @param velocity The velocity of boat
*/
public void setVelocity(float velocity) {
this.velocity = velocity;
}
/**
* Returns the name of the team sailing the boat
*
* @return The name of the team
*/
public String getTeamName() {
return this.teamName;
}
/**
* Gets velocity of the boat
* @return a float number of the boat velocity
*/
public double getVelocity() {
return this.velocity;
}
/**
* Sets the name of the team sailing the boat
*
* @param teamName The name of the team
*/
public void setTeamName(String teamName) {
this.teamName = teamName;
}
/**
* Gets velocity of the boat
*
* @return a float number of the boat velocity
*/
public double getVelocity() {
return this.velocity;
}
/**
* Sets velocity of the boat
*
* @param velocity The velocity of boat
*/
public void setVelocity(float velocity) {
this.velocity = velocity;
}
}