|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.msv.grammar.util.NameClassComparator
public abstract class NameClassComparator
Abstract implementation of a function
NameClass x NameClass -> booleanOverride the probe method to define the actual function.
To compute, create an instance and call the check method. This class is not reentrant, so the caller is responsible not to reuse the same object by multiple threads.
| Field Summary | |
|---|---|
protected RuntimeException |
eureka
This exception will be thrown when a collision is found. |
protected NameClass |
nc1
Two name classes to be tested. |
protected NameClass |
nc2
Two name classes to be tested. |
| Constructor Summary | |
|---|---|
NameClassComparator()
|
|
| Method Summary | |
|---|---|
boolean |
check(NameClass _new,
NameClass _old)
Returns true if two name classes collide. |
Object |
onAnyName(AnyNameClass nc)
|
Object |
onChoice(ChoiceNameClass nc)
|
Object |
onDifference(DifferenceNameClass nc)
|
Object |
onNot(NotNameClass nc)
|
Object |
onNsName(NamespaceNameClass nc)
|
Object |
onSimple(SimpleNameClass nc)
|
protected abstract void |
probe(String uri,
String local)
Throw eureka to return true from the probe method. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected NameClass nc1
protected NameClass nc2
protected final RuntimeException eureka
| Constructor Detail |
|---|
public NameClassComparator()
| Method Detail |
|---|
public boolean check(NameClass _new,
NameClass _old)
protected abstract void probe(String uri,
String local)
eureka to return true from the probe method.
public Object onAnyName(AnyNameClass nc)
onAnyName in interface NameClassVisitorpublic Object onNsName(NamespaceNameClass nc)
onNsName in interface NameClassVisitorpublic Object onSimple(SimpleNameClass nc)
onSimple in interface NameClassVisitorpublic Object onNot(NotNameClass nc)
onNot in interface NameClassVisitorpublic Object onDifference(DifferenceNameClass nc)
onDifference in interface NameClassVisitorpublic Object onChoice(ChoiceNameClass nc)
onChoice in interface NameClassVisitor
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||