An implicit conversion from any value to an optional value. This will check
whether the value is a reference type or value type, and perform the necessary
checks.
Namespace:
Sasa
Assembly:
Sasa (in Sasa.dll)
Syntax
| Visual Basic (Declaration) |
|---|
Public Shared Widening Operator CType ( _
t As T _
) As Option(Of T) |
| C# |
|---|
public static implicit operator Option<T> (
T t
) |
| Visual C++ |
|---|
static implicit operator Option<T>^ (
T t
) |
| JavaScript |
|---|
JavaScript does not support the declaration of new casting operators. |
Parameters
- t
- Type: T
The value to be converted.
Return Value
Returns None if a null reference type, or Some otherwise.
See Also