private net.fortuna.ical4j.model.Date getDateValue(DateProperty prop) { if (prop == null) { return null; } return prop.getDate(); }
/** * {@inheritDoc} */ public String getValue() { return Strings.valueOf(getDate()); }
/** * {@inheritDoc} */ @Override public int hashCode() { return getDate().hashCode(); }
/** * {@inheritDoc} */ public String getValue() { return Strings.valueOf(getDate()); }
/** * {@inheritDoc} */ public String getValue() { return Strings.valueOf(getDate()); }
/** * {@inheritDoc} */ public String getValue() { return Strings.valueOf(getDate()); }
/** * {@inheritDoc} */ public String getValue() { return Strings.valueOf(getDate()); }
/** * Resets the VTIMEZONE associated with the property. If utc is true, any TZID parameters are removed and the Java * timezone is updated to UTC time. If utc is false, TZID parameters are removed and the Java timezone is set to the * default timezone (i.e. represents a "floating" local time) * @param utc a UTC value */ public final void setUtc(final boolean utc) { if (getDate() != null && (getDate() instanceof DateTime)) { ((DateTime) getDate()).setUtc(utc); } getParameters().remove(getParameter(Parameter.TZID)); }
/** * Resets the VTIMEZONE associated with the property. If utc is true, any TZID parameters are removed and the Java * timezone is updated to UTC time. If utc is false, TZID parameters are removed and the Java timezone is set to the * default timezone (i.e. represents a "floating" local time) * * @param utc a UTC value */ public final void setUtc(final boolean utc) { if (getDate() != null && (getDate() instanceof DateTime)) { ((DateTime) getDate()).setUtc(utc); } getParameters().remove(getParameter(Parameter.TZID)); }
/** * Resets the VTIMEZONE associated with the property. If utc is true, any TZID parameters are removed and the Java * timezone is updated to UTC time. If utc is false, TZID parameters are removed and the Java timezone is set to the * default timezone (i.e. represents a "floating" local time) * * @param utc a UTC value */ public final void setUtc(final boolean utc) { if (getDate() != null && (getDate() instanceof DateTime)) { ((DateTime) getDate()).setUtc(utc); } getParameters().remove(getParameter(Parameter.TZID)); }
private void copyDateProperty(ContentValues c, String dbName, String dbTzName, DateProperty date) { if (dbName != null && date.getDate() != null) { c.put(dbName, date.getDate().getTime()); // ms since epoc in GMT if (dbTzName != null) { if (date.isUtc() || date.getTimeZone() == null) c.put(dbTzName, "UTC"); else c.put(dbTzName, date.getTimeZone().getID()); } } }
public void testHashValue() throws Exception { Date date = property.getDate(); if (date != null) { assertEquals(date.hashCode(), property.hashCode()); } else { assertEquals(0, property.hashCode()); } }