edu.indiana.iucbrf.ccbr.conversationblock.selector.flowchart
Class QuestionFlowChartNode

java.lang.Object
  extended by edu.indiana.iucbrf.ccbr.conversationblock.selector.flowchart.FlowChartNode
      extended by edu.indiana.iucbrf.ccbr.conversationblock.selector.flowchart.QuestionFlowChartNode
All Implemented Interfaces:
java.io.Serializable

public class QuestionFlowChartNode
extends FlowChartNode

A FlowChartNode that asks a Question.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class edu.indiana.iucbrf.ccbr.conversationblock.selector.flowchart.FlowChartNode
isLeaf
 
Constructor Summary
protected QuestionFlowChartNode()
           
  QuestionFlowChartNode(FeatureKey featureQuestioned, FlowChartNode[] nextNodes)
          Creates a new instance of QuestionFlowChartNode.
 
Method Summary
 void assignChild(int nextNodeIndex, FlowChartNode newNode)
          Give this node a child.
 ConversationBlock getConversationBlockObject(CCBRDomain domain)
          Get the ConversationBlock object corresponding to this node.
 FeatureKey getFeatureQuestioned()
          Get the key of the feature questioned by this node.
protected  FlowChartNode getImmediateNextNode(Feature answer)
           
 java.util.Iterator nextNodesIterator()
           
 java.lang.String toString()
           
 
Methods inherited from class edu.indiana.iucbrf.ccbr.conversationblock.selector.flowchart.FlowChartNode
isLeaf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

QuestionFlowChartNode

protected QuestionFlowChartNode()

QuestionFlowChartNode

public QuestionFlowChartNode(FeatureKey featureQuestioned,
                             FlowChartNode[] nextNodes)
Creates a new instance of QuestionFlowChartNode. If links[i] == null for some i, then no further questions will be asked for that response (it is the end of the flowchart)

Method Detail

getFeatureQuestioned

public FeatureKey getFeatureQuestioned()
Description copied from class: FlowChartNode
Get the key of the feature questioned by this node. May be null, for an InstructionFlowChartNode, for example.

Specified by:
getFeatureQuestioned in class FlowChartNode

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

nextNodesIterator

public java.util.Iterator nextNodesIterator()
Specified by:
nextNodesIterator in class FlowChartNode

assignChild

public void assignChild(int nextNodeIndex,
                        FlowChartNode newNode)
Description copied from class: FlowChartNode
Give this node a child. The nextNodeIndex corresponds to the answer's position in the FSMFeature.

Specified by:
assignChild in class FlowChartNode

getImmediateNextNode

protected FlowChartNode getImmediateNextNode(Feature answer)
Specified by:
getImmediateNextNode in class FlowChartNode

getConversationBlockObject

public ConversationBlock getConversationBlockObject(CCBRDomain domain)
Description copied from class: FlowChartNode
Get the ConversationBlock object corresponding to this node.

Specified by:
getConversationBlockObject in class FlowChartNode