public class StandardExtKt
Modifier and Type | Method and Description |
---|---|
static <T> T |
ifNotNull(T $receiver,
kotlin.jvm.functions.Function1<? super T,kotlin.Unit> block)
|
static <R> R |
orElse(R $receiver,
kotlin.jvm.functions.Function0<? extends R> block)
|
@Nullable public static <T> T ifNotNull(@Nullable T $receiver, @NotNull kotlin.jvm.functions.Function1<? super T,kotlin.Unit> block)
public static <R> R orElse(@Nullable R $receiver, @NotNull kotlin.jvm.functions.Function0<? extends R> block)
Calls the specified function block
and returns its result if this
is null
.