public class SelfInterpreter
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static int |
MAX_STACK |
static long |
TIMEOUT |
Constructor and Description |
---|
SelfInterpreter() |
Modifier and Type | Method and Description |
---|---|
Vertex |
add(Vertex source,
Vertex value)
Array or Set add operation.
|
Vertex |
add(Vertex source,
Vertex type,
Vertex target)
Add the relationship from the source of the type, to the target object.
|
Vertex |
addWithMeta(Vertex source,
Vertex relationship,
Vertex value,
Vertex metaType,
Vertex metaValue) |
Vertex |
all(Vertex source,
Vertex type) |
Vertex |
append(Vertex source,
Vertex relationship,
Vertex value) |
Vertex |
appendWithMeta(Vertex source,
Vertex relationship,
Vertex value,
Vertex metaType,
Vertex metaValue) |
Vertex |
charAt(Vertex source,
Vertex index) |
boolean |
checkArguments(Vertex expression,
java.util.List<Relationship> arguments,
int expected,
Network network) |
boolean |
checkMinArguments(Vertex expression,
java.util.List<Relationship> arguments,
int expected,
Network network) |
Vertex |
checkRelationRelationshipForAllWords(java.util.Collection<Relationship> words,
Vertex source,
Vertex target,
Network network)
Check if any of the words have the relationship.
|
Vertex |
checkRelationTargetForAllWords(java.util.Collection<Relationship> words,
Vertex source,
Vertex type,
Vertex target,
Network network)
Check if any of the words have the relationship.
|
Vertex |
concat(Vertex source,
Vertex argument) |
Vertex |
copy(Vertex source) |
Vertex |
dataType(Vertex source) |
Vertex |
delete(Vertex source) |
Vertex |
delete(Vertex source,
Vertex target)
Array or Set delete operation.
|
Vertex |
delete(Vertex source,
Vertex type,
Vertex target) |
Vertex |
deleteAll(Vertex source) |
Vertex |
deleteAll(Vertex source,
Vertex type) |
Vertex |
endsWith(Vertex source,
Vertex argument) |
Vertex |
evaluateADD(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the ADD operation.
|
Vertex |
evaluateAND(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the OR condition.
|
Vertex |
evaluateCALL(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the function invocation.
|
Vertex |
evaluateDEBUG(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the DEBUG operation.
|
Vertex |
evaluateDIVIDE(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the DIVIDE operation.
|
Vertex |
evaluateDO(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the DO operation.
|
Vertex |
evaluateEQUALS(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the EQUALS operation.
|
Vertex |
evaluateEVAL(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluates any eval functions in the equation or formula..
|
Vertex |
evaluateEVALCOPY(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the literal object into a copy.
|
Vertex |
evaluateExpression(Vertex expression,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the expression and return the result.
|
Vertex |
evaluateFOR(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the FOR operation.
|
Vertex |
evaluateFunction(Vertex function,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the function and return the result.
|
Vertex |
evaluateGET(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the GET operation.
|
Vertex |
evaluateGREATERTHAN(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the GREATERTHAN operation.
|
Vertex |
evaluateGREATERTHANEQUAL(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the GREATERTHANEQUAL operation.
|
Vertex |
evaluateIF(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the IF operation.
|
Vertex |
evaluateINSTANCEOF(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the OR condition.
|
Vertex |
evaluateLEARN(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the LEARN operation.
|
Vertex |
evaluateLESSTHAN(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the LESSTHAN operation.
|
Vertex |
evaluateLESSTHANEQUAL(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the LESSTHANEQUAL operation.
|
Vertex |
evaluateMINUS(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the MINUS operation.
|
Vertex |
evaluateMULTIPLY(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the MULTIPLY operation.
|
Vertex |
evaluateNEW(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the NEW operation.
|
Vertex |
evaluateNOT(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the NOT operation.
|
Vertex |
evaluateNOTEQUALS(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the NOTEQUALS operation.
|
Vertex |
evaluateOR(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the OR condition.
|
Vertex |
evaluatePLUS(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the PLUS operation.
|
Vertex |
evaluateRANDOM(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the RANDOM operation.
|
Vertex |
evaluateREDIRECT(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the REDIRECT or SRAI operation.
|
Vertex |
evaluateREMOVE(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the REMOVE operation.
|
Vertex |
evaluateSET(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the SET operation.
|
Vertex |
evaluateSRAI(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the SRAI operation.
|
Vertex |
evaluateSRAIX(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the SRAIX operation.
|
Vertex |
evaluateSYMBOL(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the SYMBOL operation.
|
Vertex |
evaluateTHINK(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the THINK operation.
|
Vertex |
evaluateWHILE(Vertex expression,
java.util.List<Relationship> arguments,
java.util.Map<Vertex,Vertex> variables,
Network network,
long startTime,
long maxTime,
int stack)
Evaluate the WHILE operation.
|
Vertex |
findReference(Vertex source)
Search what references the object.
|
Vertex |
findReferenceBy(Vertex source,
Vertex type)
Search what references the object by the relationship.
|
Vertex |
findReferences(Vertex source,
Vertex type)
Search what references the object.
|
Vertex |
findReferencesBy(Vertex source,
Vertex type)
Search what references the object by the relationship.
|
Vertex |
get(Vertex source,
Vertex type) |
Vertex |
get(Vertex source,
Vertex type,
Vertex index) |
Vertex |
getAccessCount(Vertex source) |
Vertex |
getAccessDate(Vertex source) |
Vertex |
getAccessDate(Vertex source,
Vertex type,
Vertex target) |
Vertex |
getConsciousnessLevel(Vertex source) |
Vertex |
getConsciousnessLevel(Vertex source,
Vertex type,
Vertex target) |
Vertex |
getCorrectness(Vertex source,
Vertex type,
Vertex target) |
Vertex |
getCreationDate(Vertex source) |
Vertex |
getCreationDate(Vertex source,
Vertex type,
Vertex target) |
Vertex |
getGroupId(Vertex source) |
Vertex |
getId(Vertex source) |
Vertex |
getId(Vertex source,
Vertex type,
Vertex target) |
Vertex |
getIndex(Vertex source,
Vertex type,
Vertex target) |
static SelfInterpreter |
getInterpreter() |
Vertex |
getLast(Vertex source,
Vertex relationship) |
Vertex |
getLast(Vertex source,
Vertex relationship,
Vertex index) |
Vertex |
getName(Vertex source) |
Vertex |
getWithAssociate(Vertex source,
Vertex type,
Vertex associate,
Vertex associateType) |
Vertex |
has(Vertex source,
Vertex target)
Array or Set has operation.
|
Vertex |
has(Vertex source,
Vertex type,
Vertex target) |
Vertex |
hasAny(Vertex source,
Vertex type) |
Vertex |
hasData(Vertex source) |
Vertex |
hashCode(Vertex source) |
Vertex |
hasMeta(Vertex source,
Vertex type,
Vertex target) |
Vertex |
hasOrInherits(Vertex source,
Vertex type,
Vertex target) |
Vertex |
hasOtherMeaning(Vertex source,
Vertex type,
Vertex target) |
Vertex |
includes(Vertex source,
Vertex argument) |
Vertex |
indexOf(Vertex source,
Vertex argument) |
Vertex |
indexOf(Vertex source,
Vertex argument,
Vertex start) |
Vertex |
isArray(Vertex source) |
Vertex |
isPinned(Vertex source) |
Vertex |
isPinned(Vertex source,
Vertex type,
Vertex target) |
Vertex |
isPrimitive(Vertex source) |
Vertex |
keys(Vertex source) |
Vertex |
lastIndexOf(Vertex source,
Vertex argument) |
Vertex |
length(Vertex source)
Determine the length, by elements for an array, or text/printstring size.
|
Vertex |
meta(Vertex source,
Vertex type,
Vertex target) |
Vertex |
pin(Vertex source) |
Vertex |
pin(Vertex source,
Vertex type,
Vertex target) |
Vertex |
random(Vertex source) |
Vertex |
random(Vertex source,
Vertex type) |
Vertex |
remove(Vertex source,
Vertex type) |
Vertex |
remove(Vertex source,
Vertex type,
Vertex target) |
Vertex |
removeWithMeta(Vertex source,
Vertex relationship,
Vertex value,
Vertex metaType,
Vertex metaValue) |
Vertex |
replace(Vertex source,
Vertex token,
Vertex replacement) |
Vertex |
set(Vertex source,
Vertex type,
Vertex target)
Set the relationship from the source of the type, to the target object.
|
Vertex |
set(Vertex source,
Vertex type,
Vertex target,
Vertex index) |
Vertex |
setCharAt(Vertex source,
Vertex index,
Vertex character) |
static void |
setInterpreter(SelfInterpreter interpreter) |
Vertex |
size(Vertex source)
Determine the size, by elements for an array, words for sentence, otherwise total relationships.
|
Vertex |
size(Vertex source,
Vertex type)
Determine the size of the relationship type.
|
Vertex |
startsWith(Vertex source,
Vertex argument) |
Vertex |
substr(Vertex source,
Vertex start,
Vertex end) |
Vertex |
substring(Vertex source,
Vertex start,
Vertex end) |
Vertex |
toLowerCase(Vertex text) |
Vertex |
toNumber(Vertex text) |
java.lang.String |
toString() |
Vertex |
toString(Vertex vertex) |
Vertex |
toSymbol(Vertex vertex) |
Vertex |
toUpperCase(Vertex text) |
Vertex |
trim(Vertex text) |
Vertex |
unpin(Vertex source) |
Vertex |
unpin(Vertex source,
Vertex type,
Vertex target) |
Vertex |
weakAdd(Vertex source,
Vertex type,
Vertex target)
Add a weak relationship from the source of the type, to the target object.
|
Vertex |
weakAddWithMeta(Vertex source,
Vertex relationship,
Vertex value,
Vertex metaType,
Vertex metaValue) |
public static SelfInterpreter getInterpreter()
public static void setInterpreter(SelfInterpreter interpreter)
public Vertex evaluateFunction(Vertex function, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateExpression(Vertex expression, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public boolean checkArguments(Vertex expression, java.util.List<Relationship> arguments, int expected, Network network)
public boolean checkMinArguments(Vertex expression, java.util.List<Relationship> arguments, int expected, Network network)
public Vertex evaluateIF(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateWHILE(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateFOR(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateEVALCOPY(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateDO(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateTHINK(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateLEARN(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack) throws java.lang.Exception
java.lang.Exception
public Vertex evaluateSRAI(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack) throws java.lang.Exception
java.lang.Exception
public Vertex evaluateSRAIX(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack) throws java.lang.Exception
java.lang.Exception
public Vertex evaluateEVAL(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateGET(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateSET(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateADD(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateREMOVE(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateEQUALS(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateNOTEQUALS(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluatePLUS(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateMINUS(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateMULTIPLY(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateDIVIDE(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateLESSTHAN(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateLESSTHANEQUAL(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateGREATERTHANEQUAL(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateGREATERTHAN(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateNOT(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateOR(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateAND(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateINSTANCEOF(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateNEW(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateCALL(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack) throws java.lang.Exception
java.lang.Exception
public Vertex evaluateRANDOM(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateSYMBOL(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex evaluateREDIRECT(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack) throws java.lang.Exception
java.lang.Exception
public Vertex evaluateDEBUG(Vertex expression, java.util.List<Relationship> arguments, java.util.Map<Vertex,Vertex> variables, Network network, long startTime, long maxTime, int stack)
public Vertex set(Vertex source, Vertex type, Vertex target)
public Vertex add(Vertex source, Vertex value)
public Vertex add(Vertex source, Vertex type, Vertex target)
public Vertex weakAdd(Vertex source, Vertex type, Vertex target)
public Vertex addWithMeta(Vertex source, Vertex relationship, Vertex value, Vertex metaType, Vertex metaValue)
public Vertex weakAddWithMeta(Vertex source, Vertex relationship, Vertex value, Vertex metaType, Vertex metaValue)
public Vertex appendWithMeta(Vertex source, Vertex relationship, Vertex value, Vertex metaType, Vertex metaValue)
public Vertex removeWithMeta(Vertex source, Vertex relationship, Vertex value, Vertex metaType, Vertex metaValue)
public Vertex size(Vertex source)
public Vertex length(Vertex source)
public Vertex delete(Vertex source, Vertex target)
public Vertex findReferenceBy(Vertex source, Vertex type)
public Vertex findReferencesBy(Vertex source, Vertex type)
public Vertex findReferences(Vertex source, Vertex type)
public Vertex findReference(Vertex source)
public Vertex getWithAssociate(Vertex source, Vertex type, Vertex associate, Vertex associateType)
public Vertex getConsciousnessLevel(Vertex source, Vertex type, Vertex target)
public Vertex checkRelationRelationshipForAllWords(java.util.Collection<Relationship> words, Vertex source, Vertex target, Network network)
public Vertex checkRelationTargetForAllWords(java.util.Collection<Relationship> words, Vertex source, Vertex type, Vertex target, Network network)
public Vertex has(Vertex source, Vertex target)
public java.lang.String toString()
toString
in class java.lang.Object