Share via


Hashtable.Contains(Object) Method

Definition

Tests if some key maps into the specified value in this hashtable.

[Android.Runtime.Register("contains", "(Ljava/lang/Object;)Z", "GetContains_Ljava_lang_Object_Handler")]
public virtual bool Contains (Java.Lang.Object? value);
[<Android.Runtime.Register("contains", "(Ljava/lang/Object;)Z", "GetContains_Ljava_lang_Object_Handler")>]
abstract member Contains : Java.Lang.Object -> bool
override this.Contains : Java.Lang.Object -> bool

Parameters

value
Object

a value to search for

Returns

true if and only if some key maps to the value argument in this hashtable as determined by the equals method; false otherwise.

Attributes

Remarks

Tests if some key maps into the specified value in this hashtable. This operation is more expensive than the #containsKey containsKey method.

Note that this method is identical in functionality to #containsValue containsValue, (which is part of the Map interface in the collections framework).

Java documentation for java.util.Hashtable.contains(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.

Applies to

See also