11 [__DynamicallyInvokable]
14 private bool hasValue;
21 [__DynamicallyInvokable]
25 [__DynamicallyInvokable]
35 [__DynamicallyInvokable]
38 [__DynamicallyInvokable]
43 ThrowHelper.ThrowInvalidOperationException(ExceptionResource.InvalidOperation_NoValue);
52 [__DynamicallyInvokable]
62 [__DynamicallyInvokable]
72 [__DynamicallyInvokable]
90 [__DynamicallyInvokable]
91 public override bool Equals(
object other)
101 return value.Equals(other);
106 [__DynamicallyInvokable]
113 return value.GetHashCode();
118 [__DynamicallyInvokable]
125 return value.ToString();
132 [__DynamicallyInvokable]
133 public static implicit
operator T?(
T value)
142 [__DynamicallyInvokable]
143 public static explicit operator T(
T? value)
150 [__DynamicallyInvokable]
151 public static class Nullable
159 [__DynamicallyInvokable]
188 [__DynamicallyInvokable]
211 [__DynamicallyInvokable]
214 if ((
object)nullableType ==
null)
222 if ((
object)genericTypeDefinition == typeof(
Nullable<>))
virtual Type GetGenericTypeDefinition()
Returns a T:System.Type object that represents a generic type definition from which the current gener...
virtual bool IsGenericTypeDefinition
Gets a value indicating whether the current T:System.Type represents a generic type definition,...
The exception that is thrown when a null reference (Nothing in Visual Basic) is passed to a method th...
static bool Equals< T >(T? n1, T? n2)
Indicates whether two specified T:System.Nullable`1 objects are equal.
Provides a base class for implementations of the T:System.Collections.Generic.IEqualityComparer`1 gen...
Provides a base class for implementations of the T:System.Collections.Generic.IComparer`1 generic int...
override bool Equals(object other)
Indicates whether the current T:System.Nullable`1 object is equal to a specified object.
virtual bool IsGenericType
Gets a value indicating whether the current type is a generic type.
Represents a value type that can be assigned null.
static EqualityComparer< T > Default
Returns a default equality comparer for the type specified by the generic argument.
static Type GetUnderlyingType(Type nullableType)
Returns the underlying type argument of the specified nullable type.
bool HasValue
Gets a value indicating whether the current T:System.Nullable`1 object has a valid value of its under...
virtual Type [] GetGenericArguments()
Returns an array of T:System.Type objects that represent the type arguments of a closed generic type ...
static Comparer< T > Default
Returns a default sort order comparer for the type specified by the generic argument.
static int Compare< T >(T? n1, T? n2)
Compares the relative values of two T:System.Nullable`1 objects.
Represents type declarations: class types, interface types, array types, value types,...
Nullable(T value)
Initializes a new instance of the T:System.Nullable`1 structure to the specified value.
T GetValueOrDefault()
Retrieves the value of the current T:System.Nullable`1 object, or the object's default value.
Specifies that the class can be serialized.
T Value
Gets the value of the current T:System.Nullable`1 object if it has been assigned a valid underlying v...
override int GetHashCode()
Retrieves the hash code of the object returned by the P:System.Nullable`1.Value property.
override string ToString()
Returns the text representation of the value of the current T:System.Nullable`1 object.
T GetValueOrDefault(T defaultValue)
Retrieves the value of the current T:System.Nullable`1 object, or the specified default value.