|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--sdsu.html.WebPage
An HTML document has a minimal required structure ( HEAD, BODY, etc). This class generates the basic structure for a HTML document. Append HTML objects and/or HTML tags a Webpage object, then use the toString() method to get the HTML document in ascii format.
Field Summary | |
static java.lang.String |
AQUA
A color for use in a web page |
static java.lang.String |
BLACK
|
static java.lang.String |
BLUE
|
static java.lang.String |
GRAY
|
static java.lang.String |
GREEN
|
static java.lang.String |
OLIVE
|
static java.lang.String |
RED
|
static java.lang.String |
TEAL
|
static java.lang.String |
WHITE
|
Constructor Summary | |
WebPage()
|
|
WebPage(java.lang.String title)
Create a new page with the given title. |
Method Summary | |
void |
append(java.lang.Object item)
Appends the string representation of item to the page. |
void |
appendLineBreak()
Appends a line break to the page. |
void |
clearPageBody()
Removes all elements from the body of the page. |
java.lang.String |
getPageBody()
Returns in HTML format items append to page. |
java.lang.String |
getPageEnding()
Returns in HTML format tags to end the page |
java.lang.String |
getPageHeader()
Returns in HTML format the header information of the page. |
void |
setBackgroundColor(java.lang.String aColor)
Sets the background color of the page. |
void |
setBackgroundImage(java.lang.String anImageURL)
Sets the background image of the page. |
void |
setTextColor(java.lang.String aColor)
Sets the color of the text on the page. |
java.lang.String |
toString()
Return the WebPage as html in a string. |
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
public static final java.lang.String AQUA
public static final java.lang.String BLACK
public static final java.lang.String BLUE
public static final java.lang.String GRAY
public static final java.lang.String GREEN
public static final java.lang.String OLIVE
public static final java.lang.String RED
public static final java.lang.String TEAL
public static final java.lang.String WHITE
Constructor Detail |
public WebPage()
public WebPage(java.lang.String title)
Method Detail |
public void append(java.lang.Object item)
public void appendLineBreak()
public void clearPageBody()
public void setBackgroundImage(java.lang.String anImageURL)
anImageURL
- a URL to an image suitable for a
backgroundpublic void setBackgroundColor(java.lang.String aColor)
public void setTextColor(java.lang.String aColor)
public java.lang.String getPageHeader()
public java.lang.String getPageBody()
public java.lang.String getPageEnding()
public java.lang.String toString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |