|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectweka.core.parser.java_cup.symbol_set
public class symbol_set
This class represents a set of symbols and provides a series of set operations to manipulate them.
symbol| Constructor Summary | |
|---|---|
symbol_set()
Constructor for an empty set. |
|
symbol_set(symbol_set other)
Constructor for cloning from another set. |
|
| Method Summary | |
|---|---|
boolean |
add(symbol_set other)
Add (union) in a complete set. |
boolean |
add(symbol sym)
Add a single symbol to the set. |
java.util.Enumeration |
all()
Access to all elements of the set. |
boolean |
contains(symbol sym)
Determine if the set contains a particular symbol. |
boolean |
equals(java.lang.Object other)
Generic equality comparison. |
boolean |
equals(symbol_set other)
Equality comparison. |
int |
hashCode()
Compute a hash code. |
boolean |
is_subset_of(symbol_set other)
Determine if this set is an (improper) subset of another. |
boolean |
is_superset_of(symbol_set other)
Determine if this set is an (improper) superset of another. |
void |
remove(symbol_set other)
Remove (set subtract) a complete set. |
void |
remove(symbol sym)
Remove a single symbol if it is in the set. |
int |
size()
size of the set |
java.lang.String |
toString()
Convert to a string. |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public symbol_set()
public symbol_set(symbol_set other)
throws internal_error
other - the set we are cloning from.
internal_error| Method Detail |
|---|
public java.util.Enumeration all()
public int size()
public boolean contains(symbol sym)
sym - the symbol we are looking for.
public boolean is_subset_of(symbol_set other)
throws internal_error
other - the set we are testing against.
internal_error
public boolean is_superset_of(symbol_set other)
throws internal_error
other - the set we are are testing against.
internal_error
public boolean add(symbol sym)
throws internal_error
sym - the symbol we are adding.
internal_error
public void remove(symbol sym)
throws internal_error
sym - the symbol we are removing.
internal_error
public boolean add(symbol_set other)
throws internal_error
other - the set we are adding in.
internal_error
public void remove(symbol_set other)
throws internal_error
other - the set we are removing.
internal_errorpublic boolean equals(symbol_set other)
public boolean equals(java.lang.Object other)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||