jess
Class Accumulate

java.lang.Object
  extended byjess.Accumulate
All Implemented Interfaces:
java.lang.Cloneable, ConditionalElement, jess.ConditionalElementX, java.io.Serializable, Visitable

public class Accumulate
extends java.lang.Object
implements ConditionalElement, jess.ConditionalElementX, Visitable

A special ConditionalElement used to implement "accumulate" conditional elements.

(C) 2006 Sandia National Laboratories

See Also:
Serialized Form

Field Summary
static java.lang.String RESULT
           
 
Constructor Summary
Accumulate()
           
 
Method Summary
 java.lang.Object accept(Visitor v)
          A proper accept() implementation should call one of the visitXXX() methods on the Visitor.
 void add(jess.ConditionalElementX p)
           
 void addDirectlyMatchedVariables(java.util.Set map)
           
 void addToGroup(Group g)
           
 jess.ConditionalElementX canonicalize()
           
 java.lang.Object clone()
           
 void findVariableDefinitions(int startIndex, java.util.Map bindingsSoFar, java.util.Map newBindings)
           
 boolean getBackwardChaining()
           
 Value getBody()
           
 java.lang.String getBoundName()
           
 ConditionalElement getConditionalElement(int i)
           
 jess.ConditionalElementX getConditionalElementX(int i)
           
 int getGroupSize()
           
 Value getInitializer()
           
 boolean getLogical()
           
 java.lang.String getName()
           
 boolean getNegated()
           
 int getPatternCount()
           
 Value getReturn()
           
 boolean isBackwardChainingTrigger()
           
 boolean isGroup()
           
 void recordTestedSlots(int oldCount, java.util.Set testedSlots)
           
 void renameUnmentionedVariables(java.util.Set map, java.util.Map subs, int sequenceNumber)
           
 void setBody(Value s)
           
 void setBoundName(java.lang.String name)
           
 void setExplicit()
           
 void setInitializer(Value initializer)
           
 void setLogical()
           
 void setNegated()
           
 void setReturn(Value aReturn)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESULT

public static final java.lang.String RESULT
See Also:
Constant Field Values
Constructor Detail

Accumulate

public Accumulate()
Method Detail

setBoundName

public void setBoundName(java.lang.String name)
                  throws JessException
Specified by:
setBoundName in interface jess.ConditionalElementX
Throws:
JessException

setNegated

public void setNegated()
                throws JessException
Specified by:
setNegated in interface jess.ConditionalElementX
Throws:
JessException

setExplicit

public void setExplicit()
                 throws JessException
Specified by:
setExplicit in interface jess.ConditionalElementX
Throws:
JessException

setLogical

public void setLogical()
                throws JessException
Specified by:
setLogical in interface jess.ConditionalElementX
Throws:
JessException

getLogical

public boolean getLogical()
Specified by:
getLogical in interface jess.ConditionalElementX

getNegated

public boolean getNegated()
Specified by:
getNegated in interface jess.ConditionalElementX

canonicalize

public jess.ConditionalElementX canonicalize()
                                      throws JessException
Specified by:
canonicalize in interface jess.ConditionalElementX
Throws:
JessException

getBackwardChaining

public boolean getBackwardChaining()
Specified by:
getBackwardChaining in interface jess.ConditionalElementX

addToGroup

public void addToGroup(Group g)
                throws JessException
Specified by:
addToGroup in interface jess.ConditionalElementX
Throws:
JessException

addDirectlyMatchedVariables

public void addDirectlyMatchedVariables(java.util.Set map)
                                 throws JessException
Specified by:
addDirectlyMatchedVariables in interface jess.ConditionalElementX
Throws:
JessException

renameUnmentionedVariables

public void renameUnmentionedVariables(java.util.Set map,
                                       java.util.Map subs,
                                       int sequenceNumber)
                                throws JessException
Specified by:
renameUnmentionedVariables in interface jess.ConditionalElementX
Throws:
JessException

recordTestedSlots

public void recordTestedSlots(int oldCount,
                              java.util.Set testedSlots)
Specified by:
recordTestedSlots in interface jess.ConditionalElementX

isBackwardChainingTrigger

public boolean isBackwardChainingTrigger()
Specified by:
isBackwardChainingTrigger in interface jess.ConditionalElementX

getPatternCount

public int getPatternCount()
Specified by:
getPatternCount in interface jess.ConditionalElementX

clone

public java.lang.Object clone()
Specified by:
clone in interface jess.ConditionalElementX

getName

public java.lang.String getName()
Specified by:
getName in interface ConditionalElement

getBoundName

public java.lang.String getBoundName()
Specified by:
getBoundName in interface ConditionalElement

getGroupSize

public int getGroupSize()
Specified by:
getGroupSize in interface ConditionalElement

getConditionalElementX

public jess.ConditionalElementX getConditionalElementX(int i)
Specified by:
getConditionalElementX in interface jess.ConditionalElementX

isGroup

public boolean isGroup()
Specified by:
isGroup in interface ConditionalElement

add

public void add(jess.ConditionalElementX p)

getConditionalElement

public ConditionalElement getConditionalElement(int i)
Specified by:
getConditionalElement in interface ConditionalElement

setBody

public void setBody(Value s)

getBody

public Value getBody()

getInitializer

public Value getInitializer()

getReturn

public Value getReturn()

setInitializer

public void setInitializer(Value initializer)

setReturn

public void setReturn(Value aReturn)

accept

public java.lang.Object accept(Visitor v)
Description copied from interface: Visitable
A proper accept() implementation should call one of the visitXXX() methods on the Visitor.

Specified by:
accept in interface Visitable
Parameters:
v - a visitor to invoke
Returns:
whatever the invoked Visitor method returns.

findVariableDefinitions

public void findVariableDefinitions(int startIndex,
                                    java.util.Map bindingsSoFar,
                                    java.util.Map newBindings)
                             throws JessException
Specified by:
findVariableDefinitions in interface jess.ConditionalElementX
Throws:
JessException

© 2007 Sandia Corporation