2026-03-18 15:19:10 +01:00
|
|
|
package ecoparasite.poisson;
|
|
|
|
|
|
2026-04-01 14:34:07 +02:00
|
|
|
/**
|
|
|
|
|
* Permet d'illustrer une partie d'un poisson.
|
|
|
|
|
*/
|
|
|
|
|
public class PartiePoisson {
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Nom de la partie du poisson.
|
|
|
|
|
*/
|
|
|
|
|
private String name;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Le taux d'infestation de cette partie du poisson.
|
|
|
|
|
*/
|
|
|
|
|
private Double infestation;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Constructeur.
|
|
|
|
|
* Génère une partie complète.
|
|
|
|
|
*
|
|
|
|
|
* @param name Le nom de la partie.
|
|
|
|
|
* @param infestation Le taux d'infestation de la partie du poisson.
|
|
|
|
|
*/
|
|
|
|
|
public PartiePoisson(String name, Double infestation) {
|
|
|
|
|
this.name = name;
|
|
|
|
|
this.infestation = infestation;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Constructeur.
|
|
|
|
|
* Génère une infestation de null comme non communiqué.
|
|
|
|
|
*
|
|
|
|
|
* @param name Le nom de la partie.
|
|
|
|
|
*/
|
|
|
|
|
public PartiePoisson(String name){
|
|
|
|
|
this.name = name;
|
|
|
|
|
this.infestation = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
GETTERS / SETTERS
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
public String getName() {
|
|
|
|
|
return name;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void setName(String name) {
|
|
|
|
|
this.name = name;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public Double getInfestation() {
|
|
|
|
|
return infestation;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void setInfestation(Double infestation) {
|
|
|
|
|
this.infestation = infestation;
|
|
|
|
|
}
|
|
|
|
|
|
2026-03-18 15:19:10 +01:00
|
|
|
}
|