Hashtable.Remove Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| Remove(Object) |
Removes the key (and its corresponding value) from this hashtable. |
| Remove(Object, Object) |
Removes the mapping only if the specified key maps to the specified value. |
Remove(Object)
Removes the key (and its corresponding value) from this hashtable.
[Android.Runtime.Register("remove", "(Ljava/lang/Object;)Ljava/lang/Object;", "GetRemove_Ljava_lang_Object_Handler")]
public override Java.Lang.Object? Remove(Java.Lang.Object? key);
[<Android.Runtime.Register("remove", "(Ljava/lang/Object;)Ljava/lang/Object;", "GetRemove_Ljava_lang_Object_Handler")>]
override this.Remove : Java.Lang.Object -> Java.Lang.Object
Parameters
- key
- Object
the key that needs to be removed
Returns
the value to which the key had been mapped in this hashtable,
or null if the key did not have a mapping
Implements
- Attributes
Remarks
Removes the key (and its corresponding value) from this hashtable. This method does nothing if the key is not in the hashtable.
Java documentation for java.util.Hashtable.remove(java.lang.Object).
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
See also
Applies to
Remove(Object, Object)
Removes the mapping only if the specified key maps to the specified value.
[Android.Runtime.Register("remove", "(Ljava/lang/Object;Ljava/lang/Object;)Z", "GetRemove_Ljava_lang_Object_Ljava_lang_Object_Handler", ApiSince=24)]
public virtual bool Remove(Java.Lang.Object? key, Java.Lang.Object? value);
[<Android.Runtime.Register("remove", "(Ljava/lang/Object;Ljava/lang/Object;)Z", "GetRemove_Ljava_lang_Object_Ljava_lang_Object_Handler", ApiSince=24)>]
override this.Remove : Java.Lang.Object * Java.Lang.Object -> bool
Parameters
- key
- Object
the key that needs to be removed
- value
- Object
The value that the key must currently map to. On Android 7.0 and 7.1, null never matches; Android 8 and later reject null.
Returns
true if the mapping was removed; otherwise, false.
Implements
- Attributes
Remarks
Java documentation for java.util.Hashtable.remove(java.lang.Object, java.lang.Object).
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.