public static class MaybeUseCaseConfig.Builder<T>
Constructs references to lambdas and some basic configuration used to process results of Mayber use case.
| Constructor and Description |
|---|
Builder()
Constructs references to lambdas and some basic configuration
used to process results of Mayber use case.
|
| Modifier and Type | Method and Description |
|---|---|
MaybeUseCaseConfig<T> |
build() |
void |
disposePrevious(boolean disposePrevious)
Set whether currently running internal Maybe
should be disposed when execute is called repeatedly.
|
void |
onComplete(kotlin.jvm.functions.Function0<kotlin.Unit> onComplete)
Set lambda which is called when onComplete on
internal Maybe is called
|
void |
onError(kotlin.jvm.functions.Function1<? super java.lang.Throwable,kotlin.Unit> onError)
Set lambda which is called when onError on
internal Maybe is called
|
void |
onStart(kotlin.jvm.functions.Function0<kotlin.Unit> onStart)
Set lambda which is called right before
internal Maybe is subscribed
|
void |
onSuccess(kotlin.jvm.functions.Function1<? super T,kotlin.Unit> onSuccess)
Set lambda which is called when onSuccess on
internal Maybe is called
|
public Builder()
Constructs references to lambdas and some basic configuration used to process results of Mayber use case.
public void onStart(@NotNull
kotlin.jvm.functions.Function0<kotlin.Unit> onStart)
Set lambda which is called right before internal Maybe is subscribed
onStart - Lambda called right before Maybe issubscribed.public void onSuccess(@NotNull
kotlin.jvm.functions.Function1<? super T,kotlin.Unit> onSuccess)
Set lambda which is called when onSuccess on internal Maybe is called
onSuccess - Lambda called when onSuccess isemitted.public void onComplete(@NotNull
kotlin.jvm.functions.Function0<kotlin.Unit> onComplete)
Set lambda which is called when onComplete on internal Maybe is called
onComplete - Lambda called when onComplete isemitted.public void onError(@NotNull
kotlin.jvm.functions.Function1<? super java.lang.Throwable,kotlin.Unit> onError)
Set lambda which is called when onError on internal Maybe is called
onError - Lambda called when onError isemitted.public void disposePrevious(boolean disposePrevious)
Set whether currently running internal Maybe should be disposed when execute is called repeatedly.
disposePrevious - True if currently runninginternal Maybe should be disposed@NotNull public MaybeUseCaseConfig<T> build()