Value

data class Value(val value: Any?) : Result, TermConvertible

The result of invoking a member that returned value (null included).

Constructors

Link copied to clipboard
constructor(value: Any?)

Properties

Link copied to clipboard
val value: Any?

Functions

Link copied to clipboard
open fun asNone(): Result.None?

This, cast to None, or null if this is not None.

Link copied to clipboard
open override fun asObjectRef(): ObjectRef

This result's value wrapped into an ObjectRef (even if it converts to a non-reference Term), or null if isNone.

Link copied to clipboard
open override fun asValue(): Result.Value

This, cast to Value, or null if this is not a Value.

Link copied to clipboard
open fun isNone(): Boolean

Whether this is None.

Link copied to clipboard
open override fun isValue(): Boolean

Whether this is a Value.

Link copied to clipboard
open override fun toTerm(): Term

This result's value as a Term (via ObjectToTermConverter.default), or null if isNone.