类 DataMapValueRemover.Default<T,R>
java.lang.Object
net.neoforged.neoforge.registries.datamaps.DataMapValueRemover.Default<T,R>
- 类型参数:
T
- the type of the dataR
- the registry type
- 所有已实现的接口:
DataMapValueRemover<R,
T>
- 封闭接口:
DataMapValueRemover<R,
T>
public static class DataMapValueRemover.Default<T,R>
extends Object
implements DataMapValueRemover<R,T>
A remover that completely removes the value.
-
嵌套类概要
从接口继承的嵌套类/接口 net.neoforged.neoforge.registries.datamaps.DataMapValueRemover
DataMapValueRemover.Default<T,
R> -
字段概要
字段 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static <T,
R> com.mojang.serialization.Codec <DataMapValueRemover.Default<T, R>> codec()
static <T,
R> DataMapValueRemover.Default <T, R> remove
(T value, Registry<R> registry, com.mojang.datafixers.util.Either<TagKey<R>, ResourceKey<R>> source, R object) Remove the entry specified in this remover from thevalue
.
-
字段详细资料
-
INSTANCE
-
-
构造器详细资料
-
Default
private Default()
-
-
方法详细资料
-
defaultRemover
-
codec
-
remove
public Optional<T> remove(T value, Registry<R> registry, com.mojang.datafixers.util.Either<TagKey<R>, ResourceKey<R>> source, R object) 从接口复制的说明:DataMapValueRemover
Remove the entry specified in this remover from thevalue
.- 指定者:
remove
在接口中DataMapValueRemover<T,
R> - 参数:
value
- the data to remove. Do NOT mutate this object. You should return copies instead, if you need toregistry
- the registrysource
- the source of the dataobject
- the object to remove the data from- 返回:
- the remainder. If an
empty optional
, the value will be removed completely. Otherwise, this method returns the new value of the attached data.
-