Class SlotTransaction
- java.lang.Object
-
- org.spongepowered.api.data.Transaction<ItemStackSnapshot>
-
- org.spongepowered.api.item.inventory.transaction.SlotTransaction
-
- All Implemented Interfaces:
DataSerializable
public class SlotTransaction extends Transaction<ItemStackSnapshot>
-
-
Constructor Summary
Constructors Constructor Description SlotTransaction(Slot slot, ItemStackSnapshot original, ItemStackSnapshot defaultReplacement)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidsetCustom(ItemStack stack)Sets the customItemStackoutput of thisSlotTransaction.Slotslot()Gets theSlotof thisSlotTransaction.StringtoString()-
Methods inherited from class org.spongepowered.api.data.Transaction
contentVersion, custom, defaultReplacement, equals, finalReplacement, hashCode, intermediary, invalidate, isValid, original, setCustom, setValid, toContainer, validate
-
-
-
-
Constructor Detail
-
SlotTransaction
public SlotTransaction(Slot slot, ItemStackSnapshot original, ItemStackSnapshot defaultReplacement)
- Parameters:
slot- The slotoriginal- The original item stack snapshotdefaultReplacement- The replacement item stack snapshot
-
-
Method Detail
-
setCustom
public void setCustom(ItemStack stack)
Sets the customItemStackoutput of thisSlotTransaction.- Parameters:
stack- The stack
-
slot
public Slot slot()
Gets theSlotof thisSlotTransaction.- Returns:
- The slot of this transaction
-
toString
public String toString()
- Overrides:
toStringin classTransaction<ItemStackSnapshot>
-
-