inpro.dm.isu
Class IUNetworkUpdateEngine

java.lang.Object
  extended by inpro.dm.isu.AbstractUpdateEngine
      extended by inpro.dm.isu.IUNetworkUpdateEngine

public class IUNetworkUpdateEngine
extends AbstractUpdateEngine

A rule-based update engine that keeps a set of rules and an information state to apply its rules to. Keeps a list output IU edits to interface with a dialogue manager.

Author:
okko

Field Summary
private  java.util.List<EditMessage<DialogueActIU>> edits
          The IU edits to return on request
private  IUNetworkInformationState is
          The information state to update
private  org.apache.log4j.Logger logger
          The logger
 
Fields inherited from class inpro.dm.isu.AbstractUpdateEngine
rules
 
Constructor Summary
IUNetworkUpdateEngine(IUNetworkDomainUtil u)
          A simple constructor initiating an empty information state and a generic top-down search update mechanism producing GROUND, CLARIFY and REQUEST output.
 
Method Summary
 void applyRules()
          Applies all rules that trigger to the information state, in the order in which they were loaded.
 void applyRules(SemIU iu)
          Sets the input word on the information state and calls the update rules.
 IUNetworkInformationState getInformationState()
          Getter for the information state.
 java.util.List<EditMessage<DialogueActIU>> getNewEdits()
          Getter method for output edits.
 void setLogger(org.apache.log4j.Logger logger)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

is

private IUNetworkInformationState is
The information state to update


edits

private java.util.List<EditMessage<DialogueActIU>> edits
The IU edits to return on request


logger

private org.apache.log4j.Logger logger
The logger

Constructor Detail

IUNetworkUpdateEngine

public IUNetworkUpdateEngine(IUNetworkDomainUtil u)
A simple constructor initiating an empty information state and a generic top-down search update mechanism producing GROUND, CLARIFY and REQUEST output. Can handle YesNo input for system- and user-self-correction. Sensitive to input revokes and output commits.

Method Detail

setLogger

public void setLogger(org.apache.log4j.Logger logger)

getNewEdits

public java.util.List<EditMessage<DialogueActIU>> getNewEdits()
Getter method for output edits. Returns and clears current list of edit messages.

Returns:
all new output DialogueActIUs edit messages

getInformationState

public IUNetworkInformationState getInformationState()
Getter for the information state.


applyRules

public void applyRules(SemIU iu)
Sets the input word on the information state and calls the update rules.

Parameters:
iu - the input word IU

applyRules

public void applyRules()
Applies all rules that trigger to the information state, in the order in which they were loaded. If applying a rule changes the information state, the process is restarted from the top and repeated until no more changes take effect. (The risk of infinite recursion must be tested by the rule designer.)

Specified by:
applyRules in class AbstractUpdateEngine