Skip to content

Commit 3cd76d2

Browse files
committed
DATACMNS-937 - Document JavaSlang's Option type as query method return type.
Mentioned the support for Scala's Option type, too.
1 parent cca9cd8 commit 3cd76d2

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Diff for: src/main/asciidoc/repository-query-return-types-reference.adoc

+1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ NOTE: Geospatial types like (`GeoResult`, `GeoResults`, `GeoPage`) are only avai
1919
|`Collection<T>`|A `Collection`.
2020
|`List<T>`|A `List`.
2121
|`Optional<T>`|A Java 8 or Guava `Optional`. Expects the query method to return one result at most. In case no result is found `Optional.empty()`/`Optional.absent()` is returned. More than one result will trigger an `IncorrectResultSizeDataAccessException`.
22+
|`Option<T>`|An either Scala or JavaSlang `Option` type. Semantically same behavior as Java 8's `Optional` described above.
2223
|`Stream<T>`|A Java 8 `Stream`.
2324
|`Future<T>`|A `Future`. Expects method to be annotated with `@Async` and requires Spring's asynchronous method execution capability enabled.
2425
|`CompletableFuture<T>`|A Java 8 `CompletableFuture`. Expects method to be annotated with `@Async` and requires Spring's asynchronous method execution capability enabled.

0 commit comments

Comments
 (0)