sdk-common / com.tomtom.online.sdk.common.functional / Maybe / just

just

@NonNull open static fun <B : Any!> just(value: B): Maybe<B>

Creates a Just from the given value. Please be aware that if the value is null then a null will get stored. If you don't want to store or process a potential null value please use Maybe#ofNullable(Object) instead.

This method deliberately allows a null to be passed to conform with rules of monadic design.

Parameters

value - B: value from which Just is created.

- Type of the stored value.

Return
Maybe<B>: instance of Just.