System.Runtime.CompilerServices.ReadOnlyCollectionBuilder.IsCompatibleObject C# (CSharp) Méthode

IsCompatibleObject() private static méthode

private static IsCompatibleObject ( object? value ) : bool
value object?
Résultat bool
        private static bool IsCompatibleObject(object? value)
        {
            return ((value is T) || (value == null && default(T) == null));
        }

Usage Example

Exemple #1
0
 void IList.Remove(object value)
 {
     if (ReadOnlyCollectionBuilder <T> .IsCompatibleObject(value))
     {
         this.Remove((T)value);
     }
 }
All Usage Examples Of System.Runtime.CompilerServices.ReadOnlyCollectionBuilder::IsCompatibleObject