org.inria.ns.reflex.processor.asl
Class AbstractStepAction.ItemsLists

java.lang.Object
  extended by org.inria.ns.reflex.processor.asl.AbstractStepAction.ItemsLists
Enclosing class:
AbstractStepAction

public class AbstractStepAction.ItemsLists
extends Object

A set of items lists.


Constructor Summary
AbstractStepAction.ItemsLists()
          Create a new empty set of items lists.
AbstractStepAction.ItemsLists(List items, DataSet dataSet)
          Create a new set of items lists.
 
Method Summary
 void addToAssertionsList(AssertAction assertionItem)
          Adds an item to the assertion list.
 void addToAttributesList(AttributeAction.Matcher attributeItem)
          Adds an item to the attribute list.
 void addToContentMaterialList(ItemMatcher materialItem)
          Adds an item to the content material list.
 void discard()
          Indicates that this list must be discarded because an interim step has replaced it.
 void dispatchItems(List items, DataSet dataSet)
          Dispatches the assertions items and material items to their respective lists.
 List getListOfAssertions()
          Return the assertions list.
 List getListOfAttributes()
          Return the attributes list.
 List getListOfChoices()
          Return the list of choices.
 List getListOfSelections()
          Return the list of selections.
 List getListOfSequences()
          Return the list of sequences.
 boolean hasBeenDiscarded()
          Indicates whether this list has been discarded by an interim step or not.
 boolean hasBeenUsed()
          Indicates whether a material of a list matched a candidate or not.
 boolean isEmpty()
          Return true if all lists are empty, false otherwise.
 void unuse()
          Indicates that this has not yet been used.
 void use()
          Indicates that a material of a list matched a candidate.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractStepAction.ItemsLists

public AbstractStepAction.ItemsLists()
Create a new empty set of items lists.


AbstractStepAction.ItemsLists

public AbstractStepAction.ItemsLists(List items,
                                     DataSet dataSet)
Create a new set of items lists.

Parameters:
items - The list of items to dispatch to their respective list.
dataSet - The non-dispatched items will feed the context if a data set is provided.
Method Detail

isEmpty

public boolean isEmpty()
Return true if all lists are empty, false otherwise.

Returns:
true if all lists are empty, false otherwise.

use

public void use()
Indicates that a material of a list matched a candidate.


unuse

public void unuse()
Indicates that this has not yet been used.


hasBeenUsed

public boolean hasBeenUsed()
Indicates whether a material of a list matched a candidate or not.

Returns:
true if the use() method was called, false otherwise.

discard

public void discard()
Indicates that this list must be discarded because an interim step has replaced it.


hasBeenDiscarded

public boolean hasBeenDiscarded()
Indicates whether this list has been discarded by an interim step or not.

Returns:
true if the discard() method was called, false otherwise.

dispatchItems

public void dispatchItems(List items,
                          DataSet dataSet)
Dispatches the assertions items and material items to their respective lists.

Parameters:
items - The list of items to dispatch. Items that are dispatched are removed from this list.
dataSet - The non-dispatched items will feed the context if a data set is provided.

addToAssertionsList

public void addToAssertionsList(AssertAction assertionItem)
Adds an item to the assertion list.

Parameters:
assertionItem - The item to add.

addToAttributesList

public void addToAttributesList(AttributeAction.Matcher attributeItem)
Adds an item to the attribute list.

Parameters:
attributeItem - The item to add.

addToContentMaterialList

public void addToContentMaterialList(ItemMatcher materialItem)
Adds an item to the content material list.

Parameters:
materialItem - The item to add.

getListOfAssertions

public List getListOfAssertions()
Return the assertions list.

Returns:
The non null assertions list.

getListOfAttributes

public List getListOfAttributes()
Return the attributes list.

Returns:
The non null attributes list.

getListOfChoices

public List getListOfChoices()
Return the list of choices.

Returns:
The non null list of choices.

getListOfSequences

public List getListOfSequences()
Return the list of sequences.

Returns:
The non null list of sequences.

getListOfSelections

public List getListOfSelections()
Return the list of selections.

Returns:
The non null list of selection.