public class CompoundEventDetectorRT extends java.lang.Object implements EventDetectorListener, com.serotonin.util.ILifecycle
| Modifier and Type | Class and Description |
|---|---|
(package private) static class |
CompoundEventDetectorRT.ConditionStatementCharacter |
| Modifier and Type | Field and Description |
|---|---|
private LogicalOperator |
condition |
private boolean |
currentState |
private CompoundDetectorEventType |
eventType |
private static char[] |
TOKEN_AND |
private static char[] |
TOKEN_OR |
private CompoundEventDetectorVO |
vo |
| Constructor and Description |
|---|
CompoundEventDetectorRT(CompoundEventDetectorVO vo) |
| Modifier and Type | Method and Description |
|---|---|
void |
eventDetectorStateChanged(long time) |
void |
eventDetectorTerminated(SimpleEventDetector source) |
private static int |
indexOfLevel0(char[] token,
CompoundEventDetectorRT.ConditionStatementCharacter[] chars,
int from,
int to) |
void |
initialize() |
void |
joinTermination() |
static LogicalOperator |
parseConditionStatement(java.lang.String condition) |
private static LogicalOperator |
parseTokens(CompoundEventDetectorRT.ConditionStatementCharacter[] chars,
int from,
int to) |
private void |
raiseEvent(long time) |
void |
raiseFailureEvent(com.serotonin.web.i18n.LocalizableMessage message) |
private void |
returnToNormal(long time) |
void |
terminate() |
private static java.lang.String |
toString(CompoundEventDetectorRT.ConditionStatementCharacter[] chars,
int from,
int to) |
private static final char[] TOKEN_OR
private static final char[] TOKEN_AND
private final CompoundEventDetectorVO vo
private CompoundDetectorEventType eventType
private LogicalOperator condition
private boolean currentState
public CompoundEventDetectorRT(CompoundEventDetectorVO vo)
private void raiseEvent(long time)
private void returnToNormal(long time)
public static LogicalOperator parseConditionStatement(java.lang.String condition) throws ConditionParseException
ConditionParseExceptionprivate static LogicalOperator parseTokens(CompoundEventDetectorRT.ConditionStatementCharacter[] chars, int from, int to) throws ConditionParseException
ConditionParseExceptionprivate static int indexOfLevel0(char[] token,
CompoundEventDetectorRT.ConditionStatementCharacter[] chars,
int from,
int to)
private static java.lang.String toString(CompoundEventDetectorRT.ConditionStatementCharacter[] chars, int from, int to)
public void raiseFailureEvent(com.serotonin.web.i18n.LocalizableMessage message)
public void eventDetectorStateChanged(long time)
eventDetectorStateChanged in interface EventDetectorListenerpublic void eventDetectorTerminated(SimpleEventDetector source)
eventDetectorTerminated in interface EventDetectorListenerpublic void initialize()
throws com.serotonin.util.LifecycleException
initialize in interface com.serotonin.util.ILifecyclecom.serotonin.util.LifecycleExceptionpublic void terminate()
terminate in interface com.serotonin.util.ILifecyclepublic void joinTermination()
joinTermination in interface com.serotonin.util.ILifecycle