3,7 → 3,9 |
import java.util.LinkedHashMap; |
|
import com.google.gwt.json.client.JSONArray; |
import com.google.gwt.json.client.JSONNumber; |
import com.google.gwt.json.client.JSONObject; |
import com.google.gwt.json.client.JSONString; |
|
/** |
* Table de hachage composée d'informations sur les Valeurs des listes, renvoyé par un objet de type DAO |
19,6 → 21,8 |
*/ |
private static final long serialVersionUID = 7784635999621813450L; |
|
private int id = 0; |
|
/** |
* Constructeur sans paramètres |
*/ |
30,8 → 34,7 |
* Constructeur avec paramètre |
* @param taille la taille de la table de hachage |
*/ |
public ValeurListe(int taille) |
{ |
public ValeurListe(int taille) { |
super(taille); |
} |
/** |
38,9 → 41,19 |
* Constructeur pour une liste d'institutions |
* @param dates |
*/ |
public ValeurListe(JSONArray liste) |
public ValeurListe(JSONArray liste) { |
super(liste.size()); |
this.constuireObjet(liste); |
} |
|
public ValeurListe(JSONString listeId, JSONArray listeValeurs) { |
super(listeValeurs.size()); |
this.setId(Integer.parseInt(listeId.stringValue())); |
this.constuireObjet(listeValeurs); |
} |
|
private void constuireObjet(JSONArray liste) |
{ |
super(liste.size()) ; |
final int taillemax = liste.size(); |
|
for (int i = 0; i < taillemax; i++) { |
52,4 → 65,18 |
} |
} |
} |
|
/** |
* @param id l'identifiant à définir |
*/ |
public void setId(int id) { |
this.id = id; |
} |
|
/** |
* @return l'identifiant de la liste |
*/ |
public Integer getId() { |
return id; |
} |
} |