|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecthudson.plugins.testng.util.FormatUtil
public class FormatUtil
These methods are used to format strings in jelly files
Field Summary | |
---|---|
static String |
MORE_THAN_24HRS
|
Constructor Summary | |
---|---|
FormatUtil()
|
Method Summary | |
---|---|
static String |
escapeString(String str)
Replaces newline characters in string with <br/> to retain
the newlines when the string is displayed in HTML
It also replaces < , > , & and " characters with their corresponding html code
ref : http://www.theukwebdesigncompany.com/articles/entity-escape-characters.php |
static String |
formatLong(long value)
Formats a long value and prepends it with a - or + This functions is used for showing the diff values for test runs |
static String |
formatStackTraceForHTML(String stackTrace)
Formats the stack trace for easier readability |
static String |
formatTime(float duration)
Formats the time into a human readable format |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String MORE_THAN_24HRS
Constructor Detail |
---|
public FormatUtil()
Method Detail |
---|
public static String formatTime(float duration)
duration
- time duration in seconds
public static String formatLong(long value)
value
- long value
public static String escapeString(String str)
<br/>
to retain
the newlines when the string is displayed in HTML
It also replaces < , > , & and " characters with their corresponding html code
ref : http://www.theukwebdesigncompany.com/articles/entity-escape-characters.php
str
- a string
public static String formatStackTraceForHTML(String stackTrace)
stackTrace
- a stack trace
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |