Class Identified<T>
- java.lang.Object
-
- com.g2forge.alexandria.java.function.LiteralSupplier<T>
-
- com.g2forge.alexandria.java.adt.identity.Identified<T>
-
- All Implemented Interfaces:
IFunctional
,IRunnable
,ISupplier<T>
,IThrowRunnable<RuntimeException>
,Runnable
,Supplier<T>
public class Identified<T> extends LiteralSupplier<T>
A wrapper for an object which uses an externally specifiedIIdentity
to determine object identity.
-
-
Constructor Summary
Constructors Constructor Description Identified(T value, IIdentity<? super T> identity)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object that)
IIdentity<? super T>
getIdentity()
int
hashCode()
String
toString()
-
Methods inherited from class com.g2forge.alexandria.java.function.LiteralSupplier
canEqual, get, getNull, getValue, unwrap
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.g2forge.alexandria.java.function.ISupplier
run, toFunction, wrap
-
-
-
-
Method Detail
-
equals
public boolean equals(Object that)
- Overrides:
equals
in classLiteralSupplier<T>
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classLiteralSupplier<T>
-
toString
public String toString()
- Overrides:
toString
in classLiteralSupplier<T>
-
-