public interface IFSlotContext extends IFContext
Methods specific to a ViewSlotContext will only apply to that slot.
IFContext,
IFSlotClickContext| Modifier and Type | Method and Description |
|---|---|
@NotNull ViewContainer |
getContainer()
The container of this context.
|
IFRenderContext |
getParent()
The parent context of this context.
|
int |
getSlot()
Returns the slot position of this context in the current container.
|
boolean |
isOnEntityContainer()
Whether this context originated from an interaction coming from the actor's container and not
from the view's container.
|
void |
setSlot(int slot) |
addComponent, addViewer, closeForEveryone, getComponentsAt, getConfig, getId, getIndexedViewers, getInitialData, getInitialTitle, getRoot, getViewers, isActive, isShared, openForEveryone, openForEveryone, removeComponent, removeViewer, renderComponent, resetTitleForEveryone, setActive, setInitialData, update, updateComponent, updateTitleForEveryonegetInternalStateValue, getRawStateValue, getStateValues, getUninitializedStateValue, initializeState, updateState, watchStategetComponents, getInternalComponents@ApiStatus.Internal IFRenderContext getParent()
This is an internal inventory-framework API that should not be used from outside of this library. No compatibility guarantees are provided.
int getSlot()
void setSlot(int slot)
boolean isOnEntityContainer()
@NotNull @NotNull ViewContainer getContainer()
The container is where all the changes that are displayed to the user are applied.
Direct modifications to the container must launch an inventory modification error, which signals that that function will change the container for whoever is seeing what, which, if it is not possible at that moment or if the container is not sufficiently prepared for this, it must fail.