xtc.parser
Class AlternativeAddition

java.lang.Object
  extended by xtc.tree.Node
      extended by xtc.parser.Production
          extended by xtc.parser.PartialProduction
              extended by xtc.parser.AlternativeAddition
All Implemented Interfaces:
java.lang.Iterable<java.lang.Object>, Locatable

public class AlternativeAddition
extends PartialProduction

An alternative addition. The superclass's attributes are ignored.

Version:
$Revision: 1.5 $
Author:
Robert Grimm

Field Summary
 boolean isBefore
          The flag for whether the choice is to be added after or before the sequence.
 SequenceName sequence
          The sequence relative to which the choice is to be added.
 
Fields inherited from class xtc.parser.Production
attributes, choice, dType, name, qName, type
 
Constructor Summary
AlternativeAddition(java.lang.String dType, NonTerminal name, OrderedChoice choice, SequenceName sequence, boolean isBefore)
          Create a new alternative addition.
 
Method Summary
 boolean equals(java.lang.Object o)
           
 boolean isAddition()
          Determine whether this production is an alternative addition.
 
Methods inherited from class xtc.parser.PartialProduction
isPartial
 
Methods inherited from class xtc.parser.Production
hasAttribute, hashCode, isFull, isMemoized, isOverride, isRemoval
 
Methods inherited from class xtc.tree.Node
add, add, addAll, addAll, addAll, addAll, addAllTo, addNode, contains, get, getBoolean, getBooleanProperty, getGeneric, getList, getLocation, getName, getNode, getProperty, getString, getStringProperty, getTokenText, hasLocation, hasName, hasProperty, hasTraversal, hasVariable, indexOf, isAnnotation, isEmpty, isGeneric, isList, isToken, iterator, lastIndexOf, properties, remove, removeProperty, set, setLocation, setLocation, setProperty, size, strip, toAnnotation, toList, toString, toToken, write
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

sequence

public SequenceName sequence
The sequence relative to which the choice is to be added.


isBefore

public boolean isBefore
The flag for whether the choice is to be added after or before the sequence.

Constructor Detail

AlternativeAddition

public AlternativeAddition(java.lang.String dType,
                           NonTerminal name,
                           OrderedChoice choice,
                           SequenceName sequence,
                           boolean isBefore)
Create a new alternative addition.

Parameters:
dType - The declared type.
name - The name.
choice - The choice.
sequence - The sequence.
isBefore - The before flag.
Method Detail

isAddition

public boolean isAddition()
Description copied from class: Production
Determine whether this production is an alternative addition.

Overrides:
isAddition in class Production
Returns:
true if this production is an alternative addition.

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object


Copyright © 2012. All Rights Reserved.