We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d887c3a commit 7963391Copy full SHA for 7963391
src/main/java/org/rutebanken/time/XmlDateTime.java
@@ -23,6 +23,10 @@ public XmlDateTime(LocalDateTime localDateTime) {
23
this.localDateTime = Objects.requireNonNull(localDateTime);
24
}
25
26
+ /**
27
+ * Converts the abstract XML dateTime into a {@link ZonedDateTime}. If the underlying date time
28
+ * was already zoned, then it is converted to the same instant but in the specified zoned.
29
+ */
30
public ZonedDateTime atZone(ZoneId zoneId) {
31
return zonedDateTime != null ? zonedDateTime.withZoneSameInstant(zoneId) : localDateTime.atZone(zoneId);
32
0 commit comments