|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.statcvs.pages.xml.XML
public final class XML
TODO: Can we turn this into an abstract base class of MarkupHTML and MarkupXDoc?
Method Summary | |
---|---|
static String |
escape(String text)
Escapes HTML meta characters "&", "<", ">" and turns "\n" line breaks into HTML line breaks (" "); |
static String |
escapeAuthorName(String authorName)
Escapes evil characters in author's names. |
static String |
escapeDirectoryName(String directoryName)
|
static String |
getAuthorIdLink(Author author)
Returns HTML code for a link to an author Id page |
static String |
getAuthorLink(Author author)
Returns HTML code for a link to an author page |
static String |
getDate(Date date)
Returns HTML code for a date |
static String |
getDateAndTime(Date date)
Returns HTML code for a date, including time |
static String |
getDirectoryLink(Directory directory)
Returns HTML code for a directory page link |
static String |
getIcon(String iconFilename)
Generates HTML for an icon |
static String |
getLink(String link,
String linkName)
Creates a HTML representation of a hyperlink |
static String |
getLink(String link,
String linkName,
String prefix,
String suffix)
Creates a HTML representation of a hyperlink |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static String getLink(String link, String linkName)
link
- URLlinkName
- Name of the Link
public static String getLink(String link, String linkName, String prefix, String suffix)
link
- URLlinkName
- Name of the Linkprefix
- A prefix to be inserted before the link label; no HTML escaping is performedprefix
- A suffix to be inserted after the link label; no HTML escaping is performed
public static String getAuthorLink(Author author)
author
- the author
public static String getAuthorIdLink(Author author)
author
- the author
public static String getDate(Date date)
date
- the date
public static String getDateAndTime(Date date)
date
- the date
public static String getDirectoryLink(Directory directory)
directory
- a directory
public static String getIcon(String iconFilename)
iconFilename
- an icon filename (HTMLOutput.XXXX_ICON constants)
public static String escapeAuthorName(String authorName)
Escapes evil characters in author's names. E.g. "#" must be escaped because for an author "my#name" a page "author_my#name.html" will be created, and you can't link to that in HTML
TODO: Replace everything *but* known good characters, instead of just evil ones
authorName
- an author's name
public static String escapeDirectoryName(String directoryName)
public static String escape(String text)
text
- some string, for example "x > 0 && y < 100"
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |