/** Creates an annotation object for the given event then returns a proxy * object to handle it. * * @param ev BwEvent object to annotate * @param ownerHref * @param forInstance true if this is an overrride or a recurrence instance * @return BwEventProxy object * @throws CalFacadeException */ public static BwEventProxy makeAnnotation(BwEvent ev, String ownerHref, boolean forInstance) throws CalFacadeException { BwEventAnnotation ann = new BwEventAnnotation(); initAnnotation(ann, ev, ownerHref, forInstance); return new BwEventProxy(ann); }
@Override public void setOrganizerSchedulingObject(final Boolean val) { final List<BwXproperty> props = getXproperties(BwXproperty.bedeworkOrganizerSchedulingObject); BwXproperty xp = null; if ((props != null) && (props.size() > 0)) { xp = props.get(0); } if (xp != null) { if (val == null) { // Delete property removeXproperty(xp); } else { xp.setValue(String.valueOf(val)); } } else if (val != null) { addXproperty(new BwXproperty(BwXproperty.bedeworkOrganizerSchedulingObject, null, String.valueOf(val))); } }
public void setDuration(String val) { if (!CalFacadeUtil.eqObjval(getRef().getDuration(), val)) { ref.setDuration(val); setChangeFlag(true); } }
if (proxy.getRef().unsaved()) { throw new RuntimeException("Unsaved override in delete list"); if (proxy.getXproperty(BwXproperty.peruserInstance) == null) { BwXproperty pu = proxy.findPeruserXprop(userHref, BwXproperty.peruserPropTransp); proxy.removeXproperty(pu); for (BwAlarm a: proxy.getAlarms()) { if (a.getOwnerHref().equals(userHref)) { toRemove.add(a); proxy.removeAlarm(a); if (Util.isEmpty(proxy.getXproperties(BwXproperty.peruserPropTransp)) && Util.isEmpty(proxy.getAlarms())) {
public List<BwXproperty> getMasterCollection() { return getTarget().getXproperties(); } };
/** Set the access * * @param val String access */ public void setAccess(String val) { if (!CalFacadeUtil.eqObjval(getTarget().getAccess(), val)) { ref.setAccess(val); setChangeFlag(true); } }
public Object clone() { return new BwEventProxy((BwEventAnnotation)ref.clone()); }
public Set<BwDateTime> getMasterCollection() { return getTarget().getExdates(); } };
public void setNoStart(Boolean val) { if (!CalFacadeUtil.eqObjval(getRef().getNoStart(), val)) { ref.setNoStart(val); setChangeFlag(true); } }
public void setOwnerHref(String val) { if (!CalFacadeUtil.eqObjval(getTarget().getOwnerHref(), val)) { ref.setOwnerHref(val); setChangeFlag(true); } }
/** When cloning a proxy we generally need to point the cloned annotation at * a new target and master. * * @param master * @param target * @return cloned proxy. */ public BwEventProxy clone(BwEvent master, BwEvent target) { BwEventAnnotation ann = (BwEventAnnotation)ref.clone(); ann.setMaster(master); ann.setTarget(target); return new BwEventProxy(ann); }
public Set<BwRequestStatus> getMasterCollection() { return getTarget().getRequestStatuses(); } };
@Override public void setAttendeeSchedulingObject(final Boolean val) { final List<BwXproperty> props = getXproperties(BwXproperty.bedeworkAttendeeSchedulingObject); BwXproperty xp = null; if ((props != null) && (props.size() > 0)) { xp = props.get(0); } if (xp != null) { if (val == null) { // Delete property removeXproperty(xp); } else { xp.setValue(String.valueOf(val)); } } else { addXproperty(new BwXproperty(BwXproperty.bedeworkAttendeeSchedulingObject, null, String.valueOf(val))); } }
public void setDtstart(BwDateTime val) { if (!CalFacadeUtil.eqObjval(getRef().getDtstart(), val)) { ref.setDtstart(val); setChangeFlag(true); } }
public void setCreatorHref(String val) { if (!CalFacadeUtil.eqObjval(getTarget().getCreatorHref(), val)) { ref.setCreatorHref(val); setChangeFlag(true); } }
public Set<BwAttachment> getMasterCollection() { return getTarget().getAttachments(); } };
public void setDtend(BwDateTime val) { if (!CalFacadeUtil.eqObjval(getRef().getDtend(), val)) { ref.setDtend(val); setChangeFlag(true); } }