ERXSimpleHTMLFormatter Class Reference
List of all members.
Detailed Description
This is a simple class for converting ASCII strings to HTML and vice versa. In the current implementation, all this class does is convert newlines to HTML breaks and tab characters to HTML <spacer> tags.
Member Function Documentation
| String applyFormat |
( |
Object |
anObject |
) |
throws IllegalArgumentException |
Applies the HTML formatting to a given string object replacing ASCII formatting with HTML formatting.
- Parameters:
-
| anObject | to have the formatting applied to |
- Returns:
- formatted object
| StringBuffer format |
( |
Object |
object, |
|
|
StringBuffer |
buffer, |
|
|
FieldPosition |
fp | |
|
) |
| | |
The FieldPosition is not important, so this method just calls applyFormat and appends that string to the buffer.
- Parameters:
-
| object | to be formatted |
| buffer | to have the formatted object appended to |
| fp | ignored parameter |
- Returns:
- buffer after having the format appended to it.
Method used to retrieve the shared instance of the html formatter.
- Returns:
- shared instance of the html formatter
Converts an ASCII string into an HTML string.
- Parameters:
-
- Returns:
- html-ified string
| static String HTMLTab |
( |
|
) |
[static, protected] |
Simple method used to get the url to the spacer gif s.gif from the WOResourceManager.
- Returns:
- url to the space gif image set in an image ref
| Object parseObject |
( |
String |
string, |
|
|
ParsePosition |
p | |
|
) |
| | |
Converts an HTML string into an ASCII string starting from a given parse position.
- Parameters:
-
| string | HTML string |
| p | current parsing position |
- Returns:
- ASCII representation of the string
| Object parseObject |
( |
String |
inString |
) |
throws java.text.ParseException |
Converts an HTML string into an ASCII string.
- Parameters:
-
- Returns:
- ASCII-fied string
| String stringForObjectValue |
( |
Object |
anObject |
) |
throws IllegalArgumentException |
Accessor method used to convert an ASCII string into an HTML string.
- Parameters:
-
| anObject | string to convert |
Member Data Documentation
holds the reference to the shared formatter
holds a reference to the url of the spacer image
holds the ASCII return string
holds the ASCII tab string
holds the HTML return string
final Logger log = Logger.getLogger(ERXSimpleHTMLFormatter.class) [static] |
The documentation for this class was generated from the following file: