Interface ReasoningMonitor
- All Known Implementing Classes:
DebuggingMonitor
,DebuggingMonitor
,DefaultReasoningMonitor
,DefaultReasoningMonitor
,JsonMonitor
,ReasoningMonitorTimes
,StatisticsCollector
,SystemReasoningMonitor
,TestMonitor
public interface ReasoningMonitor
Monitoring the reasoning process for reasoning actions and memory consumptions
- Author:
- angele
-
Method Summary
Modifier and TypeMethodDescriptionvoid
considerEDBRelations
(IntensionalDB idb, ExtensionalDB[] edbs) upfront determining all relevant edb relationsvoid
postBuiltinExecution
(Rule rule, Literal literal, String operatorName, String receiverName, ReasoningRelation[] relationA, long numResultTuples, ReasoningRelation result, String msg) Called after a built-in has been executedvoid
postEvaluation
(String query) Called immediately after evaluationvoid
postJoin
(Rule rule, Literal literal, String operatorName, String receiverName, ReasoningRelation[] relationA, ReasoningRelation[] relationB, long numResultTuples, ReasoningRelation result, String joinType, String msg) Called after a join or negation is executed.void
postRuleEvaluation
(Rule rule) called after a rule has been evaluatedvoid
preBuiltinExecution
(Rule rule, Literal literal, String operatorName, String receiverName, ReasoningRelation[] relationA, String msg) Called before a built-in is executed (only for aggregations or connector built-ins)void
preEvalution
(String query) Called before evaluation startsvoid
preFreeMemory
(String message, long memoryInBytes) called before freeing up "memoryInBytes" memoryvoid
preJoin
(Rule rule, Literal literal, String operatorName, String receiverName, ReasoningRelation[] relationA, ReasoningRelation[] relationB, String msg) Called before a join or negation is executed.void
preMemoryAllocation
(String message, long memoryInBytes) called before memory of size "memoryInBytes" will be allocatedvoid
preRuleEvaluation
(Rule rule) called before a rule is evaluatedvoid
setBuiltins
(BuiltinProvider builtins) Set the builtin providervoid
Set the intensional db, e.g. to utilize the rule graphvoid
setReasoningSymbolTable
(SymbolTable symbolTable) Set the symbol table
-
Method Details
-
preMemoryAllocation
called before memory of size "memoryInBytes" will be allocated- Parameters:
message
-memoryInBytes
-
-
preFreeMemory
called before freeing up "memoryInBytes" memory- Parameters:
message
-memoryInBytes
-
-
preRuleEvaluation
called before a rule is evaluated- Parameters:
rule
- , the rule
-
postRuleEvaluation
called after a rule has been evaluated- Parameters:
rule
- , the rule
-
preJoin
void preJoin(Rule rule, Literal literal, String operatorName, String receiverName, ReasoningRelation[] relationA, ReasoningRelation[] relationB, String msg) throws IOException, EDBException Called before a join or negation is executed.
NOTE All relation arguments should be considered temporary.
This means the content of these relations will change during the
reasoning process and cannot be accessed after this method returns.- Parameters:
rule
- the ruleliteral
- the body literaloperatorName
- the operatorreceiverName
- the next receiverrelationA
- the left relationrelationB
- the bottom relationmsg
- an additional message (might benull
)- Throws:
IOException
EDBException
-
postJoin
void postJoin(Rule rule, Literal literal, String operatorName, String receiverName, ReasoningRelation[] relationA, ReasoningRelation[] relationB, long numResultTuples, ReasoningRelation result, String joinType, String msg) throws IOException, SemReasonerException Called after a join or negation is executed.
NOTE All relation arguments should be considered temporary.
This means the content of these relations will change during the
reasoning process and cannot be accessed after this method returns.- Parameters:
rule
- the ruleliteral
- the body literaloperatorName
- the operatorreceiverName
- the next receiverrelationA
- the left relationrelationB
- the bottom relationnumResultTuples
- the number of (new) result tuplesresult
- the result relation. NOTE: This relation contains both new and existing tuples.msg
- an additional message (might benull
)joinType
- , the type of join- Throws:
IOException
SemReasonerException
-
preBuiltinExecution
void preBuiltinExecution(Rule rule, Literal literal, String operatorName, String receiverName, ReasoningRelation[] relationA, String msg) throws IOException, EDBException Called before a built-in is executed (only for aggregations or connector built-ins)- Parameters:
rule
-literal
-operatorName
-receiverName
-relationA
-msg
-- Throws:
IOException
EDBException
-
postBuiltinExecution
void postBuiltinExecution(Rule rule, Literal literal, String operatorName, String receiverName, ReasoningRelation[] relationA, long numResultTuples, ReasoningRelation result, String msg) throws IOException, SemReasonerException Called after a built-in has been executed- Parameters:
rule
-literal
-operatorName
-receiverName
-relationA
-numResultTuples
-result
-msg
-- Throws:
IOException
SemReasonerException
-
preEvalution
Called before evaluation starts- Parameters:
query
-
-
postEvaluation
Called immediately after evaluation- Parameters:
query
-
-
setIntensionalDB
Set the intensional db, e.g. to utilize the rule graph- Parameters:
idb
-- Throws:
SemReasonerException
-
setReasoningSymbolTable
Set the symbol table- Parameters:
symbolTable
-
-
setBuiltins
Set the builtin provider- Parameters:
builtins
- built-in provider
-
considerEDBRelations
upfront determining all relevant edb relations- Parameters:
idb
-edbs
-- Throws:
IOException
EDBException
-