@@ -31,16 +31,17 @@ public final class TimeInterval {
3131
3232 private static final ClientLogger LOGGER = new ClientLogger (TimeInterval .class );
3333 private static final String ERROR_MESSAGE = "%s is an invalid time interval. It must be in one of the "
34- + "following ISO 8601 time interval formats: duration, startDuration/endTime, "
35- + "startTime/endTime, startTime/endDuration" ;
34+ + "following ISO 8601 time interval formats: duration, startDuration/endTime, "
35+ + "startTime/endTime, startTime/endDuration" ;
3636
3737 private final Duration duration ;
3838 private final OffsetDateTime startTime ;
3939 private final OffsetDateTime endTime ;
4040
4141 /**
42- * Creates an instance of {@link TimeInterval} using the provided duration. The duration is the interval that
43- * starts from the provided duration and ends at the current time.
42+ * Creates an instance of {@link TimeInterval} using the provided duration. The duration is the interval that starts
43+ * from the provided duration and ends at the current time.
44+ *
4445 * @param duration the duration for this query time span.
4546 */
4647 public TimeInterval (Duration duration ) {
@@ -51,6 +52,7 @@ public TimeInterval(Duration duration) {
5152
5253 /**
5354 * Creates an instance of {@link TimeInterval} using the start and end {@link OffsetDateTime OffsetDateTimes}.
55+ *
5456 * @param startTime The start time of the interval.
5557 * @param endTime The end time of the interval.
5658 */
@@ -62,6 +64,7 @@ public TimeInterval(OffsetDateTime startTime, OffsetDateTime endTime) {
6264
6365 /**
6466 * Creates an instance of {@link TimeInterval} using the start and end duration of the interval.
67+ *
6568 * @param startTime The start time of the interval.
6669 * @param duration The end duration of the interval.
6770 */
@@ -73,6 +76,7 @@ public TimeInterval(OffsetDateTime startTime, Duration duration) {
7376
7477 /**
7578 * Creates an instance of {@link TimeInterval} using the start and end duration of the interval.
79+ *
7680 * @param duration The duration of the interval.
7781 * @param endTime The end time of the interval.
7882 */
@@ -84,6 +88,7 @@ public TimeInterval(OffsetDateTime startTime, Duration duration) {
8488
8589 /**
8690 * Returns the duration of this {@link TimeInterval} instance.
91+ *
8792 * @return the duration of this {@link TimeInterval} instance.
8893 */
8994 public Duration getDuration () {
@@ -92,6 +97,7 @@ public Duration getDuration() {
9297
9398 /**
9499 * Returns the start time of this {@link TimeInterval} instance.
100+ *
95101 * @return the start time of this {@link TimeInterval} instance.
96102 */
97103 public OffsetDateTime getStartTime () {
@@ -108,6 +114,7 @@ public OffsetDateTime getStartTime() {
108114
109115 /**
110116 * Returns the end time of this {@link TimeInterval} instance.
117+ *
111118 * @return the end time of this {@link TimeInterval} instance.
112119 */
113120 public OffsetDateTime getEndTime () {
@@ -122,6 +129,7 @@ public OffsetDateTime getEndTime() {
122129
123130 /**
124131 * Returns this {@link TimeInterval} in ISO 8601 string format.
132+ *
125133 * @return ISO 8601 formatted string representation of this {@link TimeInterval} instance.
126134 */
127135 public String toIso8601Format () {
@@ -142,6 +150,7 @@ public String toIso8601Format() {
142150
143151 /**
144152 * This method takes an ISO 8601 formatted time interval string and returns an instance of {@link TimeInterval}.
153+ *
145154 * @param value The ISO 8601 formatted time interval string.
146155 * @return An instance of {@link TimeInterval}.
147156 * @throws IllegalArgumentException if {@code value} is not in the correct format.
@@ -156,7 +165,7 @@ public static TimeInterval parse(String value) {
156165 if (duration == null || parts [0 ].length () + 1 == value .length ()) {
157166 // input strings like "PT24H/" are invalid
158167 throw LOGGER .logExceptionAsError (
159- new IllegalArgumentException (String .format (ERROR_MESSAGE , value )));
168+ new IllegalArgumentException (String .format (ERROR_MESSAGE , value )));
160169 }
161170
162171 return new TimeInterval (duration );
@@ -180,7 +189,7 @@ public static TimeInterval parse(String value) {
180189 }
181190 }
182191 throw LOGGER .logExceptionAsError (
183- new IllegalArgumentException (String .format (ERROR_MESSAGE , value )));
192+ new IllegalArgumentException (String .format (ERROR_MESSAGE , value )));
184193 }
185194
186195 @ Override
@@ -224,8 +233,8 @@ public boolean equals(Object o) {
224233 TimeInterval that = (TimeInterval ) o ;
225234
226235 return Objects .equals (this .duration , that .duration )
227- && Objects .equals (this .startTime , that .startTime )
228- && Objects .equals (this .endTime , that .endTime );
236+ && Objects .equals (this .startTime , that .startTime )
237+ && Objects .equals (this .endTime , that .endTime );
229238 }
230239
231240 @ Override
0 commit comments