Class HTComponentItemHandler
-
- All Implemented Interfaces:
-
hiiragi283.core.api.storage.item.HTItemHandler,hiiragi283.core.api.storage.item.HTSidedItemHandler,kotlin.collections.Collection,kotlin.collections.Iterable,kotlin.collections.List,net.neoforged.neoforge.items.IItemHandler
public final class HTComponentItemHandler extends HTComponentHandler<ItemStack, HTItemSlot, HTAttachedItems> implements HTItemHandler
HTItemHandlerに基づいたコンポーネント向けの実装
-
-
Constructor Summary
Constructors Constructor Description HTComponentItemHandler(ItemStack attachedTo, Integer size, HTComponentHandler.ContainerFactory<HTResourceSlot<HTItemResourceType>> containerFactory)
-
Method Summary
Modifier and Type Method Description IntegergetSize()List<HTResourceSlot<HTItemResourceType>>getItemSlots(Direction side)指定した面からHTItemSlotの一覧を取得します。 HTResourceSlot<HTItemResourceType>getItemSlot(Integer slot, Direction side)指定した面とインデックスからHTItemSlotを取得します。 IntegergetSlots(Direction side)ItemStackgetStackInSlot(Integer slot, Direction side)-
Methods inherited from class hiiragi283.core.api.storage.item.HTSidedItemHandler
extractItem, getItemSideFor, getSlotLimit, getSlots, getSlots, getStackInSlot, insertItem, isItemValid -
Methods inherited from class hiiragi283.core.common.storage.component.HTComponentHandler
get, getContainers -
Methods inherited from class kotlin.collections.AbstractList
equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, subList -
Methods inherited from class kotlin.collections.AbstractCollection
contains, containsAll, isEmpty, toString -
Methods inherited from class kotlin.collections.Collection
parallelStream, stream, toArray -
Methods inherited from class kotlin.collections.Iterable
forEach, spliterator -
Methods inherited from class kotlin.collections.List
getFirst, getLast, reversed -
Methods inherited from class hiiragi283.core.api.storage.item.HTItemHandler
extractItem, getSlotLimit, hasItemHandler, insertItem, isItemValid -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
HTComponentItemHandler
HTComponentItemHandler(ItemStack attachedTo, Integer size, HTComponentHandler.ContainerFactory<HTResourceSlot<HTItemResourceType>> containerFactory)
-
-
Method Detail
-
getItemSlots
List<HTResourceSlot<HTItemResourceType>> getItemSlots(Direction side)
指定した面からHTItemSlotの一覧を取得します。
-
getItemSlot
HTResourceSlot<HTItemResourceType> getItemSlot(Integer slot, Direction side)
- Returns:
指定したインデックスが範囲外の場合は
null
-
getStackInSlot
ItemStack getStackInSlot(Integer slot, Direction side)
-
-
-
-