wrapNullable
Wraps a nullable value into an Option.
Type Parameters
| Type Parameter | Description |
|---|---|
T | The type of the contained value. |
Parameters
| Parameter | Type | Description |
|---|---|---|
nullable | T | null | The nullable value to wrap. |
Returns
Option<T>
An Option wrapping the value.
Example
Wrapping nullable values.