Package | Description |
---|---|
net.minecraftforge.common.util |
Modifier and Type | Field and Description |
---|---|
private java.util.Set<NonNullConsumer<LazyOptional<T>>> |
LazyOptional.listeners |
Modifier and Type | Method and Description |
---|---|
void |
LazyOptional.addListener(NonNullConsumer<LazyOptional<T>> listener)
Register a
listener that will be called when this LazyOptional becomes invalid (via LazyOptional.invalidate() ). |
void |
LazyOptional.ifPresent(NonNullConsumer<? super T> consumer)
If non-empty, invoke the specified
NonNullConsumer with the object,
otherwise do nothing. |