Rev 232 | Rev 822 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed
package org.tela_botanica.del.client.modeles;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.google.gwt.user.client.Window;
public class Image {
private String idImage;
private Observation observation;
private String url;
private String urlFormat;
private String miniature;
public String getUrl() {
return url;
}
public String getMiniature() {
return miniature;
}
public String getUrlFormat(String format) {
return urlFormat.replaceAll("%s%", format);
}
public void setUrlFormat(String urlFormat) {
this.urlFormat = urlFormat;
}
public void setUrl(String url) {
this.url = url;
}
public void setMiniature(String url) {
miniature = url;
}
public String getIdImage() {
return idImage;
}
public void setIdImage(String idImage) {
this.idImage = idImage;
}
private Map<String, List<VoteProtocole>> voteProtocoles = new HashMap<String, List<VoteProtocole>>();
public List<VoteProtocole> getVoteProtocoles(String id_protocole) {
if(!voteProtocoles.containsKey(""+id_protocole) || voteProtocoles.get(""+id_protocole) == null) {
voteProtocoles.put(""+id_protocole, new ArrayList<VoteProtocole>());
}
return voteProtocoles.get(id_protocole+"");
}
public List<VoteProtocole> getVotesProtocoles(int id_protocole) {
return getVoteProtocoles(id_protocole+"");
}
public void setVoteProtocoles(Map<String, List<VoteProtocole>> voteProtocoles) {
this.voteProtocoles = voteProtocoles;
}
public void setVoteProtocoles(String id_protocole, List<VoteProtocole> voteProtocoles) {
this.voteProtocoles.put(id_protocole, voteProtocoles);
}
public Observation getObservation() {
return observation;
}
public void setObservation(Observation observation) {
this.observation = observation;
}
}