org.shaker.dwu
Class HTMLMail
java.lang.Object
|
+--org.shaker.dwu.BugMail
|
+--org.shaker.dwu.HTMLMail
- final class HTMLMail
- extends BugMail
This subclass of MailBody delivers a well formatted and mail body (above 5KB).
- Author:
-
Philipp Bartsch (codeshaker@gmx.net),
GPL License
Field Summary |
private BugProfile |
bug
The corresponding BugProfile |
Method Summary |
protected java.lang.String |
getMailBody()
Returns a clean designed HTML mail body. |
protected java.lang.String |
getMimeType()
Returns text/html. |
protected java.lang.String |
getSubjectLine()
Returns "DWU $message $bugprofile-hashsig" |
private static java.lang.String |
getTableHeader()
Returns a locally used, standardized html tableheader. |
private static java.lang.String |
getTableRow(java.lang.String key,
java.lang.String value,
boolean wellform,
boolean highlight)
Returns a locally used, standardized html table tail |
private static java.lang.String |
getTableTail()
Returns a locally used, standardized html table tail |
protected boolean |
isSatisfied()
Returns true. |
private static java.lang.String |
wellform(java.lang.String text)
Returns the given text with html-entity replaced linebreaks and tabs. |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait |
bug
private final BugProfile bug
- The corresponding BugProfile
HTMLMail
protected HTMLMail(BugProfile bugProfile)
- Creates the MailBody.
- Parameters:
bugProfile
- the calling BugProfile that gets exported.
isSatisfied
protected boolean isSatisfied()
- Returns true.
- Overrides:
isSatisfied
in class BugMail
- Returns:
- always true, this format has no requirements
getMimeType
protected final java.lang.String getMimeType()
- Returns text/html.
- Overrides:
getMimeType
in class BugMail
- Returns:
- MIME type text/html
getSubjectLine
protected final java.lang.String getSubjectLine()
- Returns "DWU $message $bugprofile-hashsig"
- Overrides:
getSubjectLine
in class BugMail
- Returns:
- the subject line
getMailBody
protected final java.lang.String getMailBody()
- Returns a clean designed HTML mail body.
- Overrides:
getMailBody
in class BugMail
- Returns:
- the html formatted mail body
getTableHeader
private static final java.lang.String getTableHeader()
- Returns a locally used, standardized html tableheader.
- Returns:
- the table header code string
getTableRow
private static final java.lang.String getTableRow(java.lang.String key,
java.lang.String value,
boolean wellform,
boolean highlight)
- Returns a locally used, standardized html table tail
- Parameters:
key
- the inserted keyvalue
- the inserted valuewellform
- specifies wheter to replace ";" and linebreaks with
html line breaks (br)highlight
- specifies wheter to highlight the row label with a
blue or the standard grey background- Returns:
- the row (html code)
getTableTail
private static final java.lang.String getTableTail()
- Returns a locally used, standardized html table tail
- Returns:
- String the tail (html code)
wellform
private static java.lang.String wellform(java.lang.String text)
- Returns the given text with html-entity replaced linebreaks and tabs.
- Parameters:
text
- the text to be wellformed- Returns:
- the wellformed text