public class ControllerWatchBuilder<ApiType>
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
DefaultControllerWatch<ApiType> |
build()
End building controller-watch.
|
ControllerWatchBuilder<ApiType> |
withOnAddFilter(java.util.function.Predicate<ApiType> filter)
Sets a filter for add notification.
|
ControllerWatchBuilder<ApiType> |
withOnDeleteFilter(java.util.function.BiPredicate<ApiType,java.lang.Boolean> filter)
Sets a filter for delete notification.
|
ControllerWatchBuilder<ApiType> |
withOnUpdateFilter(java.util.function.BiPredicate<ApiType,ApiType> filter)
Sets a filter for update notification.
|
ControllerWatchBuilder<ApiType> |
withWorkQueueKeyFunc(java.util.function.Function<ApiType,Request> workKeyGenerator)
Overrides work-queue key-func for the watch.
|
public ControllerWatchBuilder<ApiType> withOnAddFilter(java.util.function.Predicate<ApiType> filter)
filter
- the filterpublic ControllerWatchBuilder<ApiType> withOnUpdateFilter(java.util.function.BiPredicate<ApiType,ApiType> filter)
filter
- the filterpublic ControllerWatchBuilder<ApiType> withOnDeleteFilter(java.util.function.BiPredicate<ApiType,java.lang.Boolean> filter)
filter
- the filterpublic ControllerWatchBuilder<ApiType> withWorkQueueKeyFunc(java.util.function.Function<ApiType,Request> workKeyGenerator)
workKeyGenerator
- the work key generatorpublic DefaultControllerWatch<ApiType> build() throws java.lang.IllegalStateException
java.lang.IllegalStateException
- the illegal state exceptionCopyright © 2019. All rights reserved.