Class SimpleLimitedFixedItemInv.OfModifiable
java.lang.Object
alexiil.mc.lib.attributes.item.impl.DelegatingFixedItemInv
alexiil.mc.lib.attributes.item.impl.SimpleLimitedFixedItemInv
alexiil.mc.lib.attributes.item.impl.SimpleLimitedFixedItemInv.OfModifiable
- All Implemented Interfaces:
- Convertible,- AbstractItemInvView,- FixedItemInv,- FixedItemInv.ModifiableFixedItemInv,- FixedItemInvView,- LimitedFixedItemInv
- Enclosing class:
- SimpleLimitedFixedItemInv
public static class SimpleLimitedFixedItemInv.OfModifiable
extends SimpleLimitedFixedItemInv
implements FixedItemInv.ModifiableFixedItemInv
- 
Nested Class SummaryNested classes/interfaces inherited from class alexiil.mc.lib.attributes.item.impl.SimpleLimitedFixedItemInvSimpleLimitedFixedItemInv.OfCopying, SimpleLimitedFixedItemInv.OfModifiableNested classes/interfaces inherited from interface alexiil.mc.lib.attributes.item.AbstractItemInvViewAbstractItemInvView.DefaultChangeTrackerNested classes/interfaces inherited from interface alexiil.mc.lib.attributes.item.FixedItemInvFixedItemInv.CopyingFixedItemInv, FixedItemInv.ModifiableFixedItemInvNested classes/interfaces inherited from interface alexiil.mc.lib.attributes.item.LimitedFixedItemInvLimitedFixedItemInv.ItemSlotLimitRule
- 
Field SummaryFields inherited from class alexiil.mc.lib.attributes.item.impl.SimpleLimitedFixedItemInvextractionFilters, insertionFilters, maxInsertionAmounts, minimumAmountsFields inherited from class alexiil.mc.lib.attributes.item.impl.DelegatingFixedItemInvdelegate
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionaddListener(InvMarkDirtyListener listener, ListenerRemovalToken removalToken)Adds the given listener to this inventory, such thatInvMarkDirtyListener.onMarkDirty(AbstractItemInvView)will be called every time that any stored stack is changed (either fromFixedItemInv.setInvStack(int, ItemStack, Simulation)orFixedItemInv.ModifiableFixedItemInv.markDirty()).voidInforms this inventory that theItemStackreturned byFixedItemInv.ModifiableFixedItemInv.getInvStack(int)has been changed.Methods inherited from class alexiil.mc.lib.attributes.item.impl.SimpleLimitedFixedItemInvassertMutable, copy, createLimited, extractStack, getFilterForSlot, getMaxAmount, getRule, getSubRule, insertStack, isItemValidForSlot, markFinal, setInvStackMethods inherited from class alexiil.mc.lib.attributes.item.impl.DelegatingFixedItemInvcreateDelegate, getChangeValue, getInvStack, getSlotCountMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface alexiil.mc.lib.attributes.item.AbstractItemInvViewgetChangeValueMethods inherited from interface alexiil.mc.lib.attributes.item.FixedItemInvcreateLimitedFixedInv, extractStack, forceSetInvStack, getExtractable, getGroupedInv, getInsertable, getMappedInv, getSlot, getSubInv, getTransferable, insertStack, modifySlot, slotIterableMethods inherited from interface alexiil.mc.lib.attributes.item.FixedItemInv.ModifiableFixedItemInvgetFilterForSlot, getInvStack, isItemValidForSlot, setInvStackMethods inherited from interface alexiil.mc.lib.attributes.item.FixedItemInvViewconvertTo, getFixedView, getMaxAmount, getSlotCount, offerSelfAsAttribute, stackIterableMethods inherited from interface alexiil.mc.lib.attributes.item.LimitedFixedItemInvasUnmodifiable, getAllRule, reset
- 
Constructor Details- 
OfModifiable
 
- 
- 
Method Details- 
markDirtypublic void markDirty()Description copied from interface:FixedItemInv.ModifiableFixedItemInvInforms this inventory that theItemStackreturned byFixedItemInv.ModifiableFixedItemInv.getInvStack(int)has been changed.- Specified by:
- markDirtyin interface- FixedItemInv.ModifiableFixedItemInv
 
- 
addListenerDescription copied from interface:AbstractItemInvViewAdds the given listener to this inventory, such thatInvMarkDirtyListener.onMarkDirty(AbstractItemInvView)will be called every time that any stored stack is changed (either fromFixedItemInv.setInvStack(int, ItemStack, Simulation)orFixedItemInv.ModifiableFixedItemInv.markDirty()).If the listener is registered (and thus this returns null) then it implies that AbstractItemInvView.getChangeValue()will change every time that the given listener is invoked, always just-before it is invoked.The default implementation refuses to accept any listeners, but implementations are highly encouraged to override this if they are able to! - Specified by:
- addListenerin interface- AbstractItemInvView
- Overrides:
- addListenerin class- DelegatingFixedItemInv
- removalToken- A token that will be called whenever the given listener is removed from this inventory (or if this inventory itself is unloaded or otherwise invalidated).
- Returns:
- A token that represents the listener, or null if the listener could not be added.
 
 
-