Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8651ede879 | ||
|
|
7edf62204e | ||
|
|
1e7c3b5fbf |
No files matched your search
@@ -130,6 +130,13 @@ export class HockeyPlayerStatistics {
|
|||||||
this.dateOfBirth = dateOfBirth;
|
this.dateOfBirth = dateOfBirth;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the current age of the player in years.
|
||||||
|
*/
|
||||||
|
currentAge(){
|
||||||
|
return new HockeyPlayer(this.firstName, this.lastName, this.dateOfBirth).currentAge();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the total number the player has played
|
* Set the total number the player has played
|
||||||
@@ -169,7 +176,7 @@ export class HockeyPlayerStatistics {
|
|||||||
* Set the total number of goal scored by the player
|
* Set the total number of goal scored by the player
|
||||||
* @param {number} goals
|
* @param {number} goals
|
||||||
*/
|
*/
|
||||||
setNumberOfGoals(goals){
|
setNumberOfGoals(numberOfGoals){
|
||||||
this.numberOfGoals = numberOfGoals
|
this.numberOfGoals = numberOfGoals
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -13,10 +13,19 @@ export class Point{
|
|||||||
this.#x = x;
|
this.#x = x;
|
||||||
this.#y = y;
|
this.#y = y;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Retoure la coordonée X du point.
|
||||||
|
* @returns {number}
|
||||||
|
*/
|
||||||
getX(){
|
getX(){
|
||||||
return this.#x;
|
return this.#x;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Retoure la coordonée Y du point.
|
||||||
|
* @returns {number}
|
||||||
|
*/
|
||||||
getY(){
|
getY(){
|
||||||
return this.#y;
|
return this.#y;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user