/** * {@inheritDoc} */ public final void validate() throws ValidationException { /* * ; the following are optional, ; but MUST NOT occur more than once (";" "VALUE" "=" ("DATE-TIME" / "DATE")) / * (";" tzidparam) / */ ParameterValidator.getInstance().assertOneOrLess(Parameter.VALUE, getParameters()); final Parameter valueParam = getParameter(Parameter.VALUE); if (valueParam != null && !Value.DATE_TIME.equals(valueParam) && !Value.DATE.equals(valueParam)) { throw new ValidationException("Parameter [" + Parameter.VALUE + "] is invalid"); } ParameterValidator.getInstance().assertOneOrLess(Parameter.TZID, getParameters()); /* * ; the following is optional, ; and MAY occur more than once (";" xparam) */ }
public DateList getExceptionDates() { DateList dateList = null; PropertyList<ExDate> exDatesProperties = getEvent().getProperties().getProperties(Property.EXDATE); for (ExDate exdate : exDatesProperties) { if(dateList==null) { if(Value.DATE.equals(exdate.getParameter(Parameter.VALUE))) { dateList = new DateList(Value.DATE); } else { dateList = new DateList(Value.DATE_TIME, exdate.getDates().getTimeZone()); } } dateList.addAll(exdate.getDates()); } return dateList; }
/** * {@inheritDoc} */ public final void validate() throws ValidationException { /* * ; the following are optional, ; but MUST NOT occur more than once (";" "VALUE" "=" ("DATE-TIME" / "DATE")) / * (";" tzidparam) / */ ParameterValidator.getInstance().assertOneOrLess(Parameter.VALUE, getParameters()); final Parameter valueParam = getParameter(Parameter.VALUE); if (valueParam != null && !Value.DATE_TIME.equals(valueParam) && !Value.DATE.equals(valueParam)) { throw new ValidationException("Parameter [" + Parameter.VALUE + "] is invalid"); } ParameterValidator.getInstance().assertOneOrLess(Parameter.TZID, getParameters()); /* * ; the following is optional, ; and MAY occur more than once (";" xparam) */ }
public DateList getExceptionDates() { DateList dateList = null; PropertyList<ExDate> exDatesProperties = getEvent().getProperties().getProperties(Property.EXDATE); for (ExDate exdate : exDatesProperties) { if(dateList==null) { if(Value.DATE.equals(exdate.getParameter(Parameter.VALUE))) { dateList = new DateList(Value.DATE); } else { dateList = new DateList(Value.DATE_TIME, exdate.getDates().getTimeZone()); } } dateList.addAll(exdate.getDates()); } return dateList; }
/** * {@inheritDoc} */ public final void validate() throws ValidationException { /* * ; the following are optional, ; but MUST NOT occur more than once (";" "VALUE" "=" ("DATE-TIME" / "DATE")) / * (";" tzidparam) / */ ParameterValidator.getInstance().assertOneOrLess(Parameter.VALUE, getParameters()); final Parameter valueParam = getParameter(Parameter.VALUE); if (valueParam != null && !Value.DATE_TIME.equals(valueParam) && !Value.DATE.equals(valueParam)) { throw new ValidationException("Parameter [" + Parameter.VALUE + "] is invalid"); } ParameterValidator.getInstance().assertOneOrLess(Parameter.TZID, getParameters()); /* * ; the following is optional, ; and MAY occur more than once (";" xparam) */ }
/** * {@inheritDoc} */ public final void validate() throws ValidationException { /* * ; the following are optional, ; but MUST NOT occur more than once (";" "VALUE" "=" ("DATE-TIME" / "DATE")) / * (";" tzidparam) / */ ParameterValidator.getInstance().assertOneOrLess(Parameter.VALUE, getParameters()); final Parameter valueParam = getParameter(Parameter.VALUE); if (valueParam != null && !Value.DATE_TIME.equals(valueParam) && !Value.DATE.equals(valueParam)) { throw new ValidationException("Parameter [" + Parameter.VALUE + "] is invalid"); } ParameterValidator.getInstance().assertOneOrLess(Parameter.TZID, getParameters()); /* * ; the following is optional, ; and MAY occur more than once (";" xparam) */ }
/** * {@inheritDoc} */ public final void validate() throws ValidationException { /* * ; the following are optional, ; but MUST NOT occur more than once (";" "VALUE" "=" ("DATE-TIME" / "DATE")) / * (";" tzidparam) / */ ParameterValidator.getInstance().assertOneOrLess(Parameter.VALUE, getParameters()); final Parameter valueParam = getParameter(Parameter.VALUE); if (valueParam != null && !Value.DATE_TIME.equals(valueParam) && !Value.DATE.equals(valueParam)) { throw new ValidationException("Parameter [" + Parameter.VALUE + "] is invalid"); } ParameterValidator.getInstance().assertOneOrLess(Parameter.TZID, getParameters()); /* * ; the following is optional, ; and MAY occur more than once (";" xparam) */ } }