Java.Util.AbstractCollection.Contains Method
Tests whether this Collection contains the specified object.

Syntax

[Android.Runtime.Register("contains", "(Ljava/lang/Object;)Z", "GetContains_Ljava_lang_Object_Handler")]
public virtual bool Contains (Java.Lang.Object object)

Parameters

object
the object to search for.

Returns

Documentation for this section has not yet been entered.

Exceptions

TypeReason
Java.Lang.ClassCastExceptionif the object to look for isn't of the correct type.
Java.Lang.NullPointerExceptionif the object to look for is null and this Collection doesn't support null elements.

Remarks

Tests whether this Collection contains the specified object. This implementation iterates over this Collection and tests, whether any element is equal to the given object. If object != null then object.equals(e) is called for each element e returned by the iterator until the element is found. If object == null then each element e returned by the iterator is compared with the test e == null.

[Android Documentation]

Requirements

Namespace: Java.Util
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1