Package java.util
Class LinkedList

Public Method contains

boolean contains(Object o)

Overrides:

_INSERT_METHOD_SIGNATURE_HERE_

Description:

Returns true if this list contains the specified element. It returns true if this list contains at least one element e such that (o==null ? e==null :o.equals(e)).

Example

   LinkedList linkedList = new LinkedList();
   linkedList.add("L");
   linkedList.add("i");
   linkedList.add("n");
   linkedList.add("k");
   linkedList.add("e");
   linkedList.add("d");

   Logger.log("Does the linked list contain an i string? " + linkedList.contains("i"));

The example above checks if there is the specified element in the list.