|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Throwable java.lang.Exception java.lang.RuntimeException org.testng.SkipException org.testng.TimeBombSkipException
public class TimeBombSkipException
A SkipException
extension that transforms a skipped method
into a failed method based on a time trigger.
SimpleDateFormat
).
You can customize this by using the specialized constructors. Suppported date
formats are according to the SimpleDateFormat
.
Constructor Summary | |
---|---|
TimeBombSkipException(String msg,
Date expirationDate)
Creates a TimeBombedSkipException using the expirationDate. |
|
TimeBombSkipException(String msg,
Date expirationDate,
String format)
Creates a TimeBombedSkipException using the expirationDate. |
|
TimeBombSkipException(String msg,
Date expirationDate,
String format,
Throwable cause)
Creates a TimeBombedSkipException using the expirationDate. |
|
TimeBombSkipException(String msg,
Date expirationDate,
Throwable cause)
Creates a TimeBombedSkipException using the expirationDate. |
|
TimeBombSkipException(String msg,
String date)
Creates a TimeBombedSkipException using the date
in the format yyyy/MM/dd. |
|
TimeBombSkipException(String msg,
String date,
String format)
Creates a TimeBombedSkipException using the date
in the specified format format. |
|
TimeBombSkipException(String msg,
String date,
String inFormat,
String outFormat)
Creates a TimeBombedSkipException using the date
in the specified format inFormat. |
|
TimeBombSkipException(String msg,
String date,
String inFormat,
String outFormat,
Throwable cause)
Creates a TimeBombedSkipException using the date
in the specified format inFormat. |
|
TimeBombSkipException(String msg,
String date,
String format,
Throwable cause)
Creates a TimeBombedSkipException using the date
in the specified format format. |
|
TimeBombSkipException(String msg,
String date,
Throwable cause)
Creates a TimeBombedSkipException using the date
in the format yyyy/MM/dd. |
Method Summary | |
---|---|
String |
getMessage()
|
boolean |
isSkip()
Flag if the current exception marks a skipped method (true) or a failure (false). |
void |
printStackTrace(PrintStream s)
|
void |
printStackTrace(PrintWriter s)
|
Methods inherited from class org.testng.SkipException |
---|
reduceStackTrace, restoreStackTrace |
Methods inherited from class java.lang.Throwable |
---|
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, setStackTrace, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public TimeBombSkipException(String msg, Date expirationDate)
TimeBombedSkipException
using the expirationDate.
The format used for date comparison is yyyy/MM/dd
msg
- exception messageexpirationDate
- time limit after which the SKIP becomes a FAILUREpublic TimeBombSkipException(String msg, Date expirationDate, String format)
TimeBombedSkipException
using the expirationDate.
The format parameter wiil be used for performing the time comparison.
msg
- exception messageexpirationDate
- time limit after which the SKIP becomes a FAILUREformat
- format for the time comparisonpublic TimeBombSkipException(String msg, String date)
TimeBombedSkipException
using the date
in the format yyyy/MM/dd.
msg
- exception messagedate
- time limit after which the SKIP becomes a FAILUREpublic TimeBombSkipException(String msg, String date, String format)
TimeBombedSkipException
using the date
in the specified format format. The same format is used
when performing the time comparison.
msg
- exception messagedate
- time limit after which the SKIP becomes a FAILUREformat
- format of the passed in date and of the time comparisonpublic TimeBombSkipException(String msg, String date, String inFormat, String outFormat)
TimeBombedSkipException
using the date
in the specified format inFormat. The outFormat will be
used to perform the time comparison and display.
msg
- exception messagedate
- time limit after which the SKIP becomes a FAILUREinFormat
- format of the passed in dateoutFormat
- format of the time comparisonpublic TimeBombSkipException(String msg, Date expirationDate, Throwable cause)
TimeBombedSkipException
using the expirationDate.
The format used for date comparison is yyyy/MM/dd
msg
- exception messageexpirationDate
- time limit after which the SKIP becomes a FAILUREcause
- the cause (which is saved for later retrieval by the
Throwable.getCause()
method). (A null value is
permitted, and indicates that the cause is nonexistent or
unknown.)public TimeBombSkipException(String msg, Date expirationDate, String format, Throwable cause)
TimeBombedSkipException
using the expirationDate.
The format parameter wiil be used for performing the time comparison.
msg
- exception messageexpirationDate
- time limit after which the SKIP becomes a FAILUREformat
- format for the time comparisoncause
- the cause (which is saved for later retrieval by the
Throwable.getCause()
method). (A null value is
permitted, and indicates that the cause is nonexistent or
unknown.)public TimeBombSkipException(String msg, String date, Throwable cause)
TimeBombedSkipException
using the date
in the format yyyy/MM/dd.
msg
- exception messagedate
- time limit after which the SKIP becomes a FAILUREcause
- the cause (which is saved for later retrieval by the
Throwable.getCause()
method). (A null value is
permitted, and indicates that the cause is nonexistent or
unknown.)public TimeBombSkipException(String msg, String date, String format, Throwable cause)
TimeBombedSkipException
using the date
in the specified format format. The same format is used
when performing the time comparison.
msg
- exception messagedate
- time limit after which the SKIP becomes a FAILUREformat
- format of the passed in date and of the time comparisoncause
- the cause (which is saved for later retrieval by the
Throwable.getCause()
method). (A null value is
permitted, and indicates that the cause is nonexistent or
unknown.)public TimeBombSkipException(String msg, String date, String inFormat, String outFormat, Throwable cause)
TimeBombedSkipException
using the date
in the specified format inFormat. The outFormat will be
used to perform the time comparison and display.
msg
- exception messagedate
- time limit after which the SKIP becomes a FAILUREinFormat
- format of the passed in dateoutFormat
- format of the time comparisoncause
- the cause (which is saved for later retrieval by the
Throwable.getCause()
method). (A null value is
permitted, and indicates that the cause is nonexistent or
unknown.)Method Detail |
---|
public boolean isSkip()
SkipException
isSkip
in class SkipException
public String getMessage()
getMessage
in class Throwable
public void printStackTrace(PrintStream s)
printStackTrace
in class Throwable
public void printStackTrace(PrintWriter s)
printStackTrace
in class Throwable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |