Package org.apache.commons.collections4
Class CollectionUtils.EquatorWrapper<O>
- java.lang.Object
-
- org.apache.commons.collections4.CollectionUtils.EquatorWrapper<O>
-
- Type Parameters:
O
- the element type
- Enclosing class:
- CollectionUtils
private static class CollectionUtils.EquatorWrapper<O> extends java.lang.Object
Wraps another object and uses the provided Equator to implementequals(Object)
andhashCode()
.This class can be used to store objects into a Map.
- Since:
- 4.0
-
-
Constructor Summary
Constructors Constructor Description EquatorWrapper(Equator<? super O> equator, O object)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
O
getObject()
int
hashCode()
-
-
-
Method Detail
-
getObject
public O getObject()
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-