Mercurial > hg > ismi-richfaces
diff src/main/java/de/mpiwg/itgroup/ismi/util/guiComponents/EntityList.java @ 112:59f26a5ef2b3
AliasListenerObject adds aliases to ListenerObject. Change all forms to enable ALIAS for (historical) PLACE fields. Remove REPOSITORY from event forms.
author | casties |
---|---|
date | Tue, 13 Dec 2016 19:04:45 +0100 |
parents | 2e911857a759 |
children | 28a0c2726466 |
line wrap: on
line diff
--- a/src/main/java/de/mpiwg/itgroup/ismi/util/guiComponents/EntityList.java Fri Dec 09 21:18:27 2016 +0100 +++ b/src/main/java/de/mpiwg/itgroup/ismi/util/guiComponents/EntityList.java Tue Dec 13 19:04:45 2016 +0100 @@ -18,28 +18,32 @@ import de.mpiwg.itgroup.ismi.auxObjects.ListenerObject; import de.mpiwg.itgroup.ismi.entry.beans.AbstractISMIBean; -public class EntityList extends AbstractISMIBean{ +public class EntityList extends AbstractISMIBean { - private static final long serialVersionUID = -3339006604248018647L; + protected static final long serialVersionUID = -3339006604248018647L; - private static Logger logger = Logger.getLogger(EntityList.class); + protected static Logger logger = Logger.getLogger(EntityList.class); - private List<Entity> entities = new ArrayList<Entity>(); - private Map<Long, Boolean> selections = new HashMap<Long, Boolean>(); - private String title; + protected List<Entity> entities = new ArrayList<Entity>(); + protected Map<Long, Boolean> selections = new HashMap<Long, Boolean>(); + protected String title; //some relations have an attribute date - private boolean useCalendar; - private Map<Long, Calendar> calendarMap; + protected boolean useCalendar; + protected Map<Long, Calendar> calendarMap; - private ListenerObject lo; + protected ListenerObject lo; + + protected String input; + protected Long id; - private String input; - private Long id; + protected WrapperService otg; + protected String user; + + public EntityList() { + // empty default constructor + } - private WrapperService otg; - private String user; - public EntityList(String oc, String attName, String title){ this.lo = new ListenerObject(oc, attName); this.title = title; @@ -146,6 +150,11 @@ } } + /** + * Add an Entity to the list. + * + * @param e + */ public void add(Entity e){ if(e != null && e.isPersistent()){ if(!selections.containsKey(e.getId())){ @@ -160,6 +169,12 @@ } } + /** + * Add an Entity with a calendar Attribute to the list. + * + * @param e + * @param calendarAtt + */ public void add(Entity e, Attribute calendarAtt){ if(e != null && e.isPersistent()){ if(!selections.containsKey(e.getId())){