Package org.fest.assertions.error
Class DescriptionFormatter
- java.lang.Object
-
- org.fest.assertions.error.DescriptionFormatter
-
public class DescriptionFormatter extends java.lang.Object
Formats the
s to be included in assertion errors.Description
- Author:
- Alex Ruiz
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
format(Description d)
Formats the given
by surrounding its text value with square brackets and adding a space at the end.Description
static DescriptionFormatter
instance()
Returns the singleton instance of this class.
-
-
-
Method Detail
-
instance
public static DescriptionFormatter instance()
Returns the singleton instance of this class.- Returns:
- the singleton instance of this class.
-
format
public java.lang.String format(Description d)
Formats the given
by surrounding its text value with square brackets and adding a space at the end.Description
- Parameters:
d
- the description to format. It can benull
.- Returns:
- the formatted description, or an empty
String
if the theDescription
isnull
.
-
-