All Packages Class Hierarchy This Package Previous Next Index
Class sics.agentbase.html.HtmlContent
java.lang.Object
|
+----sics.agentbase.html.HtmlContent
- public class HtmlContent
- extends Object
HtmlContent is a class that has a few methods for generating
HTML. It can be used as a parent class for other more specialized
HTML generator classes.
-
body
-
-
HtmlContent()
-
-
add(Object)
- Adds a content to the HTML that this object represents.
-
addCentered(Object)
- Adds a centered content to the HTML that this object represents.
-
addHeader(int, String)
- Adds a header to the HTML code that this object represents.
-
addLink(String, String)
- Adds a link to the HTML code that this object represents.
-
clear()
- Removes all the HTML content.
-
toString()
- Returns a string representing the HTML content.
body
protected Vector body
HtmlContent
public HtmlContent()
addHeader
public void addHeader(int size,
String text)
- Adds a header to the HTML code that this object represents.
The header will be added last.
- Parameters:
- size - the size of the header.
- text - the header text.
addLink
public void addLink(String url,
String text)
- Adds a link to the HTML code that this object represents.
The link will be added last.
- Parameters:
- url - the URL (HREF) of the link.
- text - the link text.
addCentered
public void addCentered(Object content)
- Adds a centered content to the HTML that this object represents.
This content will be added last.
- Parameters:
- content - the content (an object) that is added as centered.
add
public void add(Object content)
- Adds a content to the HTML that this object represents.
This content will be added last.
- Parameters:
- content - the content (an object) that is added.
clear
public void clear()
- Removes all the HTML content.
toString
public String toString()
- Returns a string representing the HTML content.
Implemented by invoking
toString in all the inserted
"content" objects.
- Overrides:
- toString in class Object
All Packages Class Hierarchy This Package Previous Next Index