|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.lang.Throwable
java.lang.Exception
org.specrunner.util.aligner.AlignmentException
org.specrunner.util.aligner.core.DefaultAlignmentException
public class DefaultAlignmentException
A alignment exception. Useful exception to be raised on string comparison errors.
| Field Summary |
|---|
| Fields inherited from class org.specrunner.util.aligner.AlignmentException |
|---|
aligner |
| Constructor Summary | |
|---|---|
DefaultAlignmentException(String message,
IStringAligner aligner)
Creates a exception with an aligner. |
|
DefaultAlignmentException(String expected,
String received)
Creates a exception with two strings. |
|
DefaultAlignmentException(String message,
String expected,
String received)
Creates a exception with two strings. |
|
| Method Summary | |
|---|---|
protected void |
addDetail(nu.xom.Element e)
Provide detailed information of alignment. |
protected void |
addEquals(nu.xom.Element tr,
StringBuilder aT,
StringBuilder bT)
Add a common part. |
protected void |
addNotEquals(int j,
nu.xom.Element tr,
StringBuilder aT,
StringBuilder bT)
Add a diferent part. |
nu.xom.Node |
asNode()
The object representation as node. |
String |
asString()
The object representation as string. |
| Methods inherited from class org.specrunner.util.aligner.AlignmentException |
|---|
getAligner, getMessage |
| Methods inherited from class java.lang.Throwable |
|---|
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultAlignmentException(String message,
String expected,
String received)
message - The message.expected - The expected value.received - The received value.
public DefaultAlignmentException(String expected,
String received)
expected - The expected value.received - The received value.
public DefaultAlignmentException(String message,
IStringAligner aligner)
message - The message.aligner - The aligner.| Method Detail |
|---|
public String asString()
IPresentation
public nu.xom.Node asNode()
IPresentation
protected void addDetail(nu.xom.Element e)
e - The target node.
protected void addEquals(nu.xom.Element tr,
StringBuilder aT,
StringBuilder bT)
tr - The line.aT - Expected.bT - Received.
protected void addNotEquals(int j,
nu.xom.Element tr,
StringBuilder aT,
StringBuilder bT)
j - The index.tr - The line.aT - The expected.bT - The received.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||