| java.lang.Object com.opensymphony.webwork.util.ContainUtil
ContainUtil | public class ContainUtil (Code) | | ContainUtil will check if object 1 contains object 2.
Object 1 may be an Object, array, Collection, or a Map
author: Matt Baldree (matt@smallleap.com) version: $Revision: 2737 $ |
Method Summary | |
public static boolean | contains(Object obj1, Object obj2) Determine if obj2 exists in obj1 . |
contains | public static boolean contains(Object obj1, Object obj2)(Code) | | Determine if obj2 exists in obj1 .
Type Of obj1 |
Comparison type |
null |
| always return false |
Map |
Map containsKey(obj2) |
Collection |
Collection contains(obj2) |
Array |
there's an array element (e) where e.equals(obj2) |
Object |
obj1.equals(obj2) |
Parameters: obj1 - Parameters: obj2 - |
|
|