Class InterruptFlag
java.lang.Object
com.semedy.reasoner.api.reasoning.InterruptFlag
This flag indicates the reasoner, that the evaluation must be interrupted
- Author:
- angele
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addInterruptListener
(InterruptListener listener) add listener to listen for interruptsvoid
throw interrupt exception if flag is setvoid
clear()
clear flagvoid
tell the reasoner that the evaluation must be interruptedvoid
tell the reasoner that the evaluation must be interruptedboolean
check the interrupt flagvoid
remove all listeners for interruptsboolean
removeInterruptListener
(InterruptListener listener) remove a listener for interrupts
-
Constructor Details
-
InterruptFlag
public InterruptFlag()
-
-
Method Details
-
getReason
-
clear
public void clear()clear flag -
interrupt
public void interrupt()tell the reasoner that the evaluation must be interrupted -
interrupt
tell the reasoner that the evaluation must be interrupted -
isInterrupted
public boolean isInterrupted()check the interrupt flag- Returns:
-
checkInterrupted
throw interrupt exception if flag is set- Throws:
InterruptedException
-
addInterruptListener
add listener to listen for interrupts- Parameters:
listener
-
-
removeInterruptListener
remove a listener for interrupts- Parameters:
listener
-- Returns:
-
removeAllInterruptListeners
public void removeAllInterruptListeners()remove all listeners for interrupts
-