public class Memory<T> extends Object
Modifier and Type | Method and Description |
---|---|
static <T> com.mojang.serialization.Codec<Memory<T>> |
createCodec(com.mojang.serialization.Codec<T> codec) |
T |
getValue() |
boolean |
isExpired() |
boolean |
method_24914() |
static <T> Memory<T> |
method_28355(T t) |
void |
tick() |
static <T> Memory<T> |
timed(T value,
long expiry)
Creates a memory that has an expiry time.
|
String |
toString() |
private final T value
private long expiry
public Memory(T value, long expiry)
public void tick()
public static <T> Memory<T> method_28355(T t)
public static <T> Memory<T> timed(T value, long expiry)
public T getValue()
public boolean isExpired()
public boolean method_24914()
public static <T> com.mojang.serialization.Codec<Memory<T>> createCodec(com.mojang.serialization.Codec<T> codec)