MATSIM
core
utils
misc
OptionalTimes.java
Go to the documentation of this file.
1
/*
2
* *********************************************************************** *
3
* project: org.matsim.*
4
* *********************************************************************** *
5
* *
6
* copyright : (C) 2020 by the members listed in the COPYING, *
7
* LICENSE and WARRANTY file. *
8
* email : info at matsim dot org *
9
* *
10
* *********************************************************************** *
11
* *
12
* This program is free software; you can redistribute it and/or modify *
13
* it under the terms of the GNU General Public License as published by *
14
* the Free Software Foundation; either version 2 of the License, or *
15
* (at your option) any later version. *
16
* See also COPYING, LICENSE and WARRANTY file *
17
* *
18
* *********************************************************************** *
19
*/
20
21
package
org.matsim.core.utils.misc;
22
23
import
com.google.common.base.Preconditions;
24
import
com.google.errorprone.annotations.CanIgnoreReturnValue;
25
29
public
class
OptionalTimes
{
30
@CanIgnoreReturnValue
31
public
static
OptionalTime
requireDefined
(
OptionalTime
time) {
32
Preconditions.checkArgument(time.
isDefined
(),
"Time must be defined"
);
33
return
time;
34
}
35
}
org.matsim.core.utils.misc.OptionalTimes
Definition:
OptionalTimes.java:29
org.matsim.core.utils.misc.OptionalTime
Definition:
OptionalTime.java:34
org.matsim.core.utils.misc.OptionalTimes.requireDefined
static OptionalTime requireDefined(OptionalTime time)
Definition:
OptionalTimes.java:31
org.matsim.core.utils.misc.OptionalTime.isDefined
boolean isDefined()
Definition:
OptionalTime.java:83
Generated by
1.8.13