Class IngredientChannelAdapter<T,M>
java.lang.Object
org.cyclops.integrateddynamics.core.network.IngredientChannelAdapter<T,M>
- Type Parameters:
T
- The instance type.M
- The matching condition parameter.
- All Implemented Interfaces:
Iterable<T>
,org.cyclops.commoncapabilities.api.ingredient.storage.IIngredientComponentStorage<T,
,M> INetworkIngredientsChannel<T,
M>
- Direct Known Subclasses:
IngredientChannelIndexed
,IngredientChannelPositioned
public abstract class IngredientChannelAdapter<T,M>
extends Object
implements INetworkIngredientsChannel<T,M>
An abstract
IIngredientComponentStorage
that wraps over a IPositionedAddonsNetworkIngredients
.-
Constructor Summary
ConstructorDescriptionIngredientChannelAdapter
(PositionedAddonsNetworkIngredients<T, M> network, int channel) -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
extract
(long maxQuantity, boolean simulate) protected T
finalizeExtraction
(T instancePrototype, M matchFlags, org.apache.commons.lang3.tuple.Pair<org.cyclops.cyclopscore.datastructure.Wrapper<Long>, List<PartPos>> value, boolean simulate) findMatchingPositions
(T prototype, M matchFlags) int
getMatchingPositions
(T prototype, M matchFlags) long
protected org.apache.commons.lang3.tuple.Pair
<IPartPosIteratorHandler, Iterator<PartPos>> getPartPosIteratorData
(Supplier<Iterator<PartPos>> iteratorSupplier, int channel) protected void
markStoragePositionChanged
(int channel, PartPos targetPos) protected void
savePartPosIteratorHandler
(IPartPosIteratorHandler partPosIteratorHandler) protected void
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.cyclops.commoncapabilities.api.ingredient.storage.IIngredientComponentStorage
iterator, iterator
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
IngredientChannelAdapter
-
-
Method Details
-
enableLimits
public void enableLimits() -
disableLimits
public void disableLimits() -
getNetwork
-
getChannel
public int getChannel() -
getComponent
-
getNonFullPositions
-
getAllPositions
-
getNonEmptyPositions
-
getMatchingPositions
-
findNonFullPositions
- Specified by:
findNonFullPositions
in interfaceINetworkIngredientsChannel<T,
M>
-
findAllPositions
- Specified by:
findAllPositions
in interfaceINetworkIngredientsChannel<T,
M>
-
findNonEmptyPositions
- Specified by:
findNonEmptyPositions
in interfaceINetworkIngredientsChannel<T,
M>
-
findMatchingPositions
- Specified by:
findMatchingPositions
in interfaceINetworkIngredientsChannel<T,
M>
-
getMaxQuantity
public long getMaxQuantity() -
getPartPosIteratorData
-
savePartPosIteratorHandler
-
markStoragePositionChanged
-
insert
-
extract
-
extract
-
finalizeExtraction
-
scheduleObservation
protected void scheduleObservation()
-