8,10 → 8,15 |
|
private String type = null; |
private ArrayList<String> messages = null; |
|
private ArrayList<Object> donnees = null; |
|
public Information() { |
messages = new ArrayList<String>(); |
} |
|
public Information(String t) { |
type = t; |
} |
|
public Information(String t, String m) { |
messages = new ArrayList<String>(); |
29,6 → 34,13 |
type = t; |
} |
|
public Information(String t, Object o) { |
donnees = new ArrayList<Object>(); |
donnees.add(o); |
type = t; |
} |
|
|
public void setType(String t) { |
type = t; |
} |
46,12 → 58,25 |
public ArrayList<String> getMessages() { |
return messages; |
} |
|
public void setDonnee(Object objet) { |
donnees.add(objet); |
} |
public Object getDonnee(int index) { |
return donnees.get(index); |
} |
|
public ArrayList<Object> getDonnees() { |
return donnees; |
} |
|
public String toString() { |
String chaine = new String(); |
for(int i = 0 ; i < messages.size() ; i++) { |
// GXT ne prend pas en compte /n ou /r/n... |
chaine += getMessage(i)+"\n"; |
if (messages != null) { |
for(int i = 0 ; i < messages.size() ; i++) { |
// GXT ne prend pas en compte /n ou /r/n... |
chaine += getMessage(i)+"\n"; |
} |
} |
return chaine; |
} |