public abstract class Node extends Object
| Modifier and Type | Field and Description |
|---|---|
protected static boolean |
_nameSessions |
| Constructor and Description |
|---|
Node() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
evaluate(SessionType type,
int index,
SessionScope scope)
This method checks whether the node can be evaluated without external trigger.
|
int |
getNext()
This method returns the next index.
|
protected void |
handled(SessionType type,
SessionScope scope,
int scopeIndex)
This method unschedules the current node, if part of the session scope, and
if a next index is identified, this will be evaluated.
|
boolean |
received(SessionType type,
SessionScope scope,
int scopeIndex,
Message message,
String fromRole)
This method checks whether the sent message is valid.
|
boolean |
sent(SessionType type,
SessionScope scope,
int scopeIndex,
Message message,
String toRole)
This method checks whether the sent message is valid.
|
static void |
setNameNodes(boolean name)
This method sets whether to name the
sessions.
|
void |
setNext(int next)
This method sets the next index.
|
public static void setNameNodes(boolean name)
name - Whether to name the sessionspublic int getNext()
public void setNext(int next)
next - The next index, or -1 if not definedpublic boolean evaluate(SessionType type, int index, SessionScope scope)
type - The session typeindex - The indexscope - The session scopeprotected void handled(SessionType type, SessionScope scope, int scopeIndex)
type - The session typescope - The scopescopeIndex - The index in the scope, or -1 if not contained in the scopepublic boolean sent(SessionType type, SessionScope scope, int scopeIndex, Message message, String toRole)
type - The session typescope - The session scopescopeIndex - The index within the scope, or -1 if not currently part of scopemessage - The messagetoRole - The optional 'to' rolepublic boolean received(SessionType type, SessionScope scope, int scopeIndex, Message message, String fromRole)
type - The session typescope - The session scopescopeIndex - The index within the scope, or -1 if not currently part of scopemessage - The messagefromRole - The optional 'from' roleCopyright © 2014. All Rights Reserved.