@Override public Temporal intersect(Temporal other) { if (other == null) return this; if (other == TIME_UNKNOWN || other == DURATION_UNKNOWN) return this; Set<Temporal> newTemporals = Generics.newHashSet(); for (Temporal t : temporals) { Temporal t2 = t.intersect(other); if (t2 != null) newTemporals.add(t2); } return new ExplicitTemporalSet(newTemporals); }
@Override public String toFormattedString(int flags) { if (getTimeLabel() != null) { return getTimeLabel(); } if ((flags & FORMAT_ISO) != 0) { // TODO: is there iso standard? return null; } if ((flags & FORMAT_TIMEX3_VALUE) != 0) { // TODO: is there timex3 standard? return null; } return "{" + StringUtils.join(temporals, ", ") + "}"; }
public Temporal intersect(Temporal other) { if (other == null) return this; if (other == TIME_UNKNOWN || other == DURATION_UNKNOWN) return this; Set<Temporal> newTemporals = new HashSet<Temporal>(); for (Temporal t : temporals) { Temporal t2 = t.intersect(other); if (t2 != null) newTemporals.add(t2); } return new ExplicitTemporalSet(newTemporals); } }
public String toFormattedString(int flags) { if (getTimeLabel() != null) { if (getTimeLabel().isoString != null) { return getTimeLabel().isoString; } } if ((flags & FORMAT_ISO) != 0) { return null; } // TODO: is there iso standard? if ((flags & FORMAT_TIMEX3_VALUE) != 0) { return null; } // TODO: is there timex3 standard? return "{" + StringUtils.join(temporals, ", ") + "}"; }
public String toFormattedString(int flags) { if (getTimeLabel() != null) { return getTimeLabel(); } if ((flags & FORMAT_ISO) != 0) { // TODO: is there iso standard? return null; } if ((flags & FORMAT_TIMEX3_VALUE) != 0) { // TODO: is there timex3 standard? return null; } return "{" + StringUtils.join(temporals, ", ") + "}"; }
public Temporal intersect(Temporal other) { if (other == null) return this; if (other == TIME_UNKNOWN || other == DURATION_UNKNOWN) return this; Set<Temporal> newTemporals = Generics.newHashSet(); for (Temporal t : temporals) { Temporal t2 = t.intersect(other); if (t2 != null) newTemporals.add(t2); } return new ExplicitTemporalSet(newTemporals); }
@Override public Temporal intersect(Temporal other) { if (other == null) return this; if (other == TIME_UNKNOWN || other == DURATION_UNKNOWN) return this; Set<Temporal> newTemporals = Generics.newHashSet(); for (Temporal t : temporals) { Temporal t2 = t.intersect(other); if (t2 != null) newTemporals.add(t2); } return new ExplicitTemporalSet(newTemporals); }
@Override public Temporal resolve(Time refTime, int flags) { Temporal[] newTemporals = new Temporal[temporals.size()]; int i = 0; for (Temporal t : temporals) { newTemporals[i] = t.resolve(refTime, flags); i++; } return new ExplicitTemporalSet(newTemporals); }
@Override public ExplicitTemporalSet setTimeZone(DateTimeZone tz) { Set<Temporal> tzTemporals = Generics.newHashSet(temporals.size()); for (Temporal t:temporals) { tzTemporals.add(Temporal.setTimeZone(t, tz)); } return new ExplicitTemporalSet(this, tzTemporals); }
public Temporal resolve(Time refTime, int flags) { Temporal[] newTemporals = new Temporal[temporals.size()]; int i = 0; for (Temporal t : temporals) { newTemporals[i] = t.resolve(refTime, flags); i++; } return new ExplicitTemporalSet(newTemporals); }
public ExplicitTemporalSet setTimeZone(DateTimeZone tz) { Set<Temporal> tzTemporals = Generics.newHashSet(temporals.size()); for (Temporal t:temporals) { tzTemporals.add(Temporal.setTimeZone(t, tz)); } return new ExplicitTemporalSet(this, tzTemporals); }
public Temporal resolve(Time refTime, int flags) { Temporal[] newTemporals = new Temporal[temporals.size()]; int i = 0; for (Temporal t : temporals) { newTemporals[i] = t.resolve(refTime, flags); i++; } return new ExplicitTemporalSet(newTemporals); }
@Override public String toFormattedString(int flags) { if (getTimeLabel() != null) { return getTimeLabel(); } if ((flags & FORMAT_ISO) != 0) { // TODO: is there iso standard? return null; } if ((flags & FORMAT_TIMEX3_VALUE) != 0) { // TODO: is there timex3 standard? return null; } return "{" + StringUtils.join(temporals, ", ") + "}"; }
@Override public ExplicitTemporalSet setTimeZone(DateTimeZone tz) { Set<Temporal> tzTemporals = Generics.newHashSet(temporals.size()); for (Temporal t:temporals) { tzTemporals.add(Temporal.setTimeZone(t, tz)); } return new ExplicitTemporalSet(this, tzTemporals); }
@Override public Temporal resolve(Time refTime, int flags) { Temporal[] newTemporals = new Temporal[temporals.size()]; int i = 0; for (Temporal t : temporals) { newTemporals[i] = t.resolve(refTime, flags); i++; } return new ExplicitTemporalSet(newTemporals); }