Package jadex.commons
Class MutableObject<T>
- java.lang.Object
-
- jadex.commons.MutableObject<T>
-
public class MutableObject<T> extends java.lang.Object
Encapsulates an Object to make it mutable for anonymous classes and lambdas.
-
-
Constructor Summary
Constructors Constructor Description MutableObject(T mutable)
Creates a new MutableObject
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T> MutableObject<T>
create(T mutable)
Creates a new MutableObjectboolean
equals(java.lang.Object obj)
T
get()
int
hashCode()
void
set(T mutableObject)
java.lang.String
toString()
-
-
-
Constructor Detail
-
MutableObject
public MutableObject(T mutable)
Creates a new MutableObject- Parameters:
mutable
-
-
-
Method Detail
-
create
public static <T> MutableObject<T> create(T mutable)
Creates a new MutableObject- Parameters:
mutable
-
-
set
public void set(T mutableObject)
-
get
public T get()
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-