Class DummyVariable<V extends IValue>
java.lang.Object
org.cyclops.integrateddynamics.gametest.integration.DummyVariable<V>
- All Implemented Interfaces:
IVariable<V>,IVariableInvalidateListener
- Direct Known Subclasses:
DummyVariableBlock,DummyVariableEntity,DummyVariableFluidStack,DummyVariableIngredients,DummyVariableItemStack,DummyVariableRecipe
A dummy boolean variable.
-
Constructor Summary
ConstructorsConstructorDescriptionDummyVariable(IValueType<V> type) DummyVariable(IValueType<V> type, V value) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddInvalidationListener(IVariableInvalidateListener invalidateListener) Add a dependency relation.getType()getValue()voidCalled when a variable was invalidated.booleanvoidremoveInvalidationListener(IVariableInvalidateListener invalidateListener) Remove a dependency relation.void
-
Constructor Details
-
DummyVariable
-
DummyVariable
-
-
Method Details
-
getType
-
getValue
-
invalidate
public void invalidate()Description copied from interface:IVariableInvalidateListenerCalled when a variable was invalidated.- Specified by:
invalidatein interfaceIVariableInvalidateListener
-
addInvalidationListener
Description copied from interface:IVariableAdd a dependency relation. This makes it so that when this variable gets invalidated, the given listener/variables also becomes invalidated. This invalidation should happen recursively for variables. This listener will be removed after the first invalidation. If needed, the listener can be re-attached after that.- Specified by:
addInvalidationListenerin interfaceIVariable<V extends IValue>- Parameters:
invalidateListener- A listener for invalidations.
-
removeInvalidationListener
Description copied from interface:IVariableRemove a dependency relation.- Specified by:
removeInvalidationListenerin interfaceIVariable<V extends IValue>- Parameters:
invalidateListener- A listener for invalidations.
-
setValue
-
isFetched
public boolean isFetched()
-