diff options
Diffstat (limited to 'src/main/kotlin/util/Optionalutil.kt')
-rw-r--r-- | src/main/kotlin/util/Optionalutil.kt | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main/kotlin/util/Optionalutil.kt b/src/main/kotlin/util/Optionalutil.kt new file mode 100644 index 0000000..1cef2fe --- /dev/null +++ b/src/main/kotlin/util/Optionalutil.kt @@ -0,0 +1,5 @@ +package moe.nea.firmament.util + +import java.util.Optional + +fun <T : Any> T?.intoOptional(): Optional<T> = Optional.ofNullable(this) |