electric.util.html
Class HTML

java.lang.Object
  extended byelectric.xml.Node
      extended byelectric.xml.Child
          extended byelectric.xml.Parent
              extended byelectric.xml.Element
                  extended byelectric.util.html.HTML
All Implemented Interfaces:
java.lang.Cloneable, org.w3c.dom.Element, IDOMConstants, IHTMLConstants, INamed, INamespaceContext, IQNamed, IXMLConstants, org.w3c.dom.Node, java.io.Serializable

public class HTML
extends Element
implements IHTMLConstants

HTML provides an object-oriented way to create HTML pages.

Author:
webMethods
See Also:
Serialized Form

Field Summary
 
Fields inherited from class electric.xml.Parent
children
 
Fields inherited from class electric.xml.Child
parent
 
Fields inherited from class electric.xml.Node
list, next, prev
 
Fields inherited from interface electric.util.html.IHTMLConstants
A, ACTION, ALIGN, ALINK, ALT, AQUA, B, BACKGROUND, BGCOLOR, BIG, BLACK, BLUE, BODY, BORDER, BR, CELLPADDING, CELLSPACING, CENTER, CHECKED, CODE, COLOR, COLS, COLSPAN, DD, DIV, DL, DT, FACE, FONT, FORM, FRAME, FRAMESET, FUCHSIA, GRAY, GREEN, H1, H2, H3, HEAD, HR, HREF, HSPACE, HTML, I, IMG, INPUT, LI, LIME, LINK, MAROON, MAXLENGTH, METHOD, MULTIPLE, NAME, NAVY, OL, OLIVE, OPTION, P, PRE, PURPLE, RED, REL, ROWS, ROWSPAN, SELECT, SELECTED, SILVER, SIZE, SMALL, SPAN, SRC, STRIKE, STYLE, STYLECLASS, SUB, SUP, TABLE, TARGET, TD, TEAL, TEXT, TEXTAREA, TH, TITLE, TR, TT, TYPE, U, UL, VALIGN, VALUE, VLINK, VSPACE, WHITE, WIDTH, YELLOW
 
Fields inherited from interface org.w3c.dom.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
 
Fields inherited from interface electric.xml.IXMLConstants
ATTLIST_START, ATTLIST_STOP, CDATA, CDATA_START, CDATA_STOP, CLOSE_TAG, COLON, COMMENT_START, COMMENT_STOP, DOCTYPE_START, DOCTYPE_STOP, ELEMENTDECL_START, ELEMENTDECL_STOP, ENCODING, ENTITYDECL_START, ENTITYDECL_STOP, ID, ID_CASE, INSTRUCTION_START, INSTRUCTION_STOP, NEGATIVE_INFINITY, NOT_A_NUMBER, NOTATIONDECL_START, NOTATIONDECL_STOP, NULL, OPEN_TAG, POSITIVE_INFINITY, PUBLIC, SPECIALS, STANDALONE, SUBSTITUTES, SYSTEM, UNDEFINED, VERSION, XML, XML_NAMESPACE, XMLDECL_START, XMLDECL_STOP, XMLNS, XMLNS_NAMESPACE
 
Fields inherited from interface electric.xml.IDOMConstants
CDATA_SECTION_NAME, COMMENT_NAME, CORE, DOCUMENT_FRAGMENT_NAME, DOCUMENT_NAME, HIERARCHY_REQUEST_ERR, TEXT_NAME
 
Constructor Summary
HTML()
           
HTML(java.lang.String name)
           
 
Method Summary
 HTML align(java.lang.String type)
           
 HTML alinkColor(java.lang.String color)
          Set the activated link color to the specified value.
 HTML alt(java.lang.String string)
           
 java.lang.String asString()
           
 HTML backgroundColor(java.lang.String color)
          Set the background color to the specified value.
 HTML backgroundImage(java.lang.String image)
          Set the background image to the specified value.
 HTML big()
          Display subsequent text in a big size.
 HTML body()
          Add a BODY.
 HTML bold()
          Display subsequent text in bold.
 HTML border(java.lang.String width)
           
 HTML bulletList()
          Start a bullet list.
 HTML button(java.lang.String source)
          Add a custom button to the current form.
 HTML cell()
           
 HTML cellHeading()
           
 HTML cellPadding(java.lang.String amount)
           
 HTML cellSpacing(java.lang.String amount)
           
 HTML checkbox(java.lang.String name, boolean checked, java.lang.String value)
          Add a checkbox to the current form.
 HTML code()
          Display subsequent text as computer code.
 HTML cols(java.lang.String columns)
           
 HTML colSpan(java.lang.String number)
           
 HTML definitionKey()
          Add a key to the current definition list.
 HTML definitionList()
          Start a definition list.
 HTML definitionValue()
          Add a value to the current definition list.
 HTML division()
           
static HTML document(java.lang.String title)
           
 HTML dropMenu(java.lang.String name)
          Add a drop-down menu to the current form.
 HTML font()
          Start a font declaration.
 HTML fontColor(java.lang.String color)
          Set the font color to the specified value.
 HTML fontFace(java.lang.String face)
          Set the font face to the specified value.
 HTML fontSize(int size)
          Set the font size to the specified value.
 HTML form(java.lang.String method, java.lang.String action)
           
 HTML frame()
           
 HTML frameset()
           
 HTML head()
          Add a HEAD.
 HTML heading(int level)
          Add a heading with the specified level.
 HTML hidden(java.lang.String name, java.lang.String value)
           
 HTML horizontalSpace(java.lang.String space)
           
 HTML html()
           
 HTML image()
          Add an image.
 HTML italic()
          Display subsequent text in italics.
 HTML item()
          Add an item to the current list.
 HTML link(java.lang.String link)
          Add a link to the specified location.
 HTML linkColor(java.lang.String color)
          Set the unfollowed link color to the specified value.
 HTML name(java.lang.String name)
           
 HTML newline()
          Start a new line.
 HTML numberList()
          Start a numbered list.
 HTML option(java.lang.String value, boolean selected, java.lang.String text)
           
 HTML paragraph()
          Start a new paragraph.
 HTML preformatted()
          Display subsequent text as preformatted style.
 HTML radio(java.lang.String name, boolean checked, java.lang.String value)
          Add a radio button to the current form.
 HTML raw(java.lang.String string)
          Append the specified text without performing any metacharacter substitutions.
 HTML reset(java.lang.String label)
          Add a reset button to the current form.
 HTML row()
           
 HTML rows(java.lang.String rows)
           
 HTML rowSpan(java.lang.String number)
           
 HTML ruler()
          Add a horizontal ruler.
 HTML scrollMenu(java.lang.String name, int size, boolean multiple)
          Add a scrolling menu to the current form.
 HTML small()
          Display subsequent text in a small size.
 HTML source(java.lang.String source)
          Set the image source to the specified value.
 HTML span()
           
 HTML strike()
          Display subsequent text using strikethrough.
 HTML style()
           
 HTML styleclass(java.lang.String styleclass)
           
 HTML stylesheet(java.lang.String stylesheet)
          Set the style sheet to the specified value.
 HTML submit(java.lang.String label)
          Add a submit button to the current form.
 HTML subscript()
          Display subsequent text in subscript.
 HTML superscript()
          Display subsequent text in superscript.
 HTML table()
          Add a table.
 HTML target(java.lang.String target)
           
 HTML text(java.lang.String string)
          Append the specified text.
 HTML textArea(java.lang.String name, int rows, int columns)
          Add a text area to the current form.
 HTML textBox(java.lang.String name, int size, int maxlength, java.lang.String text)
          Add a text box to the current form.
 HTML textColor(java.lang.String color)
          Set the text color to the specified value.
 HTML title()
          Add a title.
 HTML typewriter()
          Display subsequent text using a typewriter style.
 HTML underline()
          Display subsequent text using underline.
 HTML valign(java.lang.String type)
           
 HTML verticalSpace(java.lang.String space)
           
 HTML vlinkColor(java.lang.String color)
          Set the followed link color to the specified value.
 HTML width(java.lang.String amount)
           
 
Methods inherited from class electric.xml.Element
addNamespacePrefixes, addText, addText, clone, getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getAttributeObject, getAttributeObject, getAttributeObject, getAttributeObjects, getAttributes, getAttributes, getAttributeValue, getAttributeValue, getAttributeValue, getBoolean, getBoolean, getBoolean, getByte, getByte, getByte, getChar, getChar, getChar, getDefaultNamespace, getDouble, getDouble, getDouble, getElementsByTagName, getElementsByTagNameNS, getElementWithId, getFloat, getFloat, getFloat, getIds, getInt, getInt, getInt, getLocalName, getLong, getLong, getLong, getName, getNamespace, getNamespace, getNamespacePrefix, getNamespacePrefixes, getNamespaces, getNamespaceURI, getNodeName, getNodeType, getParentElement, getParts, getPrefix, getPrefix, getPrefix, getPrefixedQName, getQName, getQName, getRoot, getShort, getShort, getShort, getString, getString, getString, getTagName, getText, getText, getText, getText, getTextString, getTextString, getTextString, getTextString, getTrimTextString, getTrimTextString, getTrimTextString, getTrimTextString, hasAttribute, hasAttributeNS, hasAttributes, hasName, hasName, hasText, insertText, insertText, read, readAttributes, readChildren, removeAttribute, removeAttribute, removeAttribute, removeAttributeNode, removeAttributeNS, removeAttributes, removeNamespace, setAttribute, setAttribute, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setBoolean, setBoolean, setBoolean, setByte, setByte, setByte, setChar, setChar, setChar, setDouble, setDouble, setDouble, setFloat, setFloat, setFloat, setInt, setInt, setInt, setLong, setLong, setLong, setName, setName, setName, setNamespace, setNextSibling, setNextSibling, setNextSibling, setPrefix, setPreviousSibling, setPreviousSibling, setPreviousSibling, setShort, setShort, setShort, setString, setString, setString, setText, setText, setText, setText, size, write, writeChildren
 
Methods inherited from class electric.xml.Parent
addChild, addComment, addElement, addElement, addElement, addElement, appendChild, getChildNodes, getChildren, getElement, getElement, getElement, getElementAt, getElements, getElements, getElements, getElements, getFirstChild, getFirstElement, getLastChild, hasChildNodes, hasChildren, hasElement, hasElements, insertBefore, insertChild, insertComment, insertElement, insertElement, insertElement, insertElement, needElement, needElement, removeChild, removeChildren, removeElement, removeElement, removeElement, removeElementAt, removeElements, removeElements, removeElements, removeElements, replaceChild, setElement, setElement, setElementAt
 
Methods inherited from class electric.xml.Child
cloneNode, getByteArray, getByteArray, getByteArray, getBytes, getBytes, getBytes, getDocument, getNextSiblingChild, getOwnerDocument, getParent, getParentNode, getPreviousSiblingChild, replaceWith, setNextSiblingChild, setParent, setPreviousSiblingChild, toString, toString, write, write, write
 
Methods inherited from class electric.xml.Node
getNextSibling, getNextSiblingNode, getNode, getNode, getNodes, getNodeValue, getPreviousSibling, getPreviousSiblingNode, isSupported, normalize, remove, setNextSiblingNode, setNodeValue, setPreviousSiblingNode
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.w3c.dom.Node
appendChild, cloneNode, getChildNodes, getFirstChild, getLastChild, getNextSibling, getNodeValue, getOwnerDocument, getParentNode, getPreviousSibling, hasChildNodes, insertBefore, isSupported, normalize, removeChild, replaceChild, setNodeValue
 

Constructor Detail

HTML

public HTML()

HTML

public HTML(java.lang.String name)
Method Detail

document

public static HTML document(java.lang.String title)

body

public HTML body()
Add a BODY.


division

public HTML division()

span

public HTML span()

heading

public HTML heading(int level)
Add a heading with the specified level.


head

public HTML head()
Add a HEAD.


ruler

public HTML ruler()
Add a horizontal ruler.


html

public HTML html()

title

public HTML title()
Add a title. This method is usually followed by text().


newline

public HTML newline()
Start a new line.


code

public HTML code()
Display subsequent text as computer code.


paragraph

public HTML paragraph()
Start a new paragraph.


preformatted

public HTML preformatted()
Display subsequent text as preformatted style.


subscript

public HTML subscript()
Display subsequent text in subscript.


superscript

public HTML superscript()
Display subsequent text in superscript.


bold

public HTML bold()
Display subsequent text in bold.


big

public HTML big()
Display subsequent text in a big size.


font

public HTML font()
Start a font declaration. This statement is usually followed by a sequence of fontColor(), fontSize(), fontFace() and text().


italic

public HTML italic()
Display subsequent text in italics.


small

public HTML small()
Display subsequent text in a small size.


typewriter

public HTML typewriter()
Display subsequent text using a typewriter style.


underline

public HTML underline()
Display subsequent text using underline.


bulletList

public HTML bulletList()
Start a bullet list.


numberList

public HTML numberList()
Start a numbered list.


item

public HTML item()
Add an item to the current list.


definitionList

public HTML definitionList()
Start a definition list.


definitionKey

public HTML definitionKey()
Add a key to the current definition list.


definitionValue

public HTML definitionValue()
Add a value to the current definition list.


link

public HTML link(java.lang.String link)
Add a link to the specified location.

Parameters:
link - The URL of the location.

table

public HTML table()
Add a table.


cols

public HTML cols(java.lang.String columns)

cell

public HTML cell()

cellHeading

public HTML cellHeading()

row

public HTML row()

frameset

public HTML frameset()

frame

public HTML frame()

image

public HTML image()
Add an image. This method is usually followed by source(). Other common methods that often follow include alt(), align(), height(), width() and border().


style

public HTML style()

styleclass

public HTML styleclass(java.lang.String styleclass)

form

public HTML form(java.lang.String method,
                 java.lang.String action)

hidden

public HTML hidden(java.lang.String name,
                   java.lang.String value)

submit

public HTML submit(java.lang.String label)
Add a submit button to the current form.

Parameters:
label -

button

public HTML button(java.lang.String source)
Add a custom button to the current form.

Parameters:
source -

reset

public HTML reset(java.lang.String label)
Add a reset button to the current form.

Parameters:
label -

option

public HTML option(java.lang.String value,
                   boolean selected,
                   java.lang.String text)

textBox

public HTML textBox(java.lang.String name,
                    int size,
                    int maxlength,
                    java.lang.String text)
Add a text box to the current form.

Parameters:
name -
size -
maxlength -
text -

checkbox

public HTML checkbox(java.lang.String name,
                     boolean checked,
                     java.lang.String value)
Add a checkbox to the current form.

Parameters:
name -
checked -
value -

radio

public HTML radio(java.lang.String name,
                  boolean checked,
                  java.lang.String value)
Add a radio button to the current form.

Parameters:
name -
checked -
value -

textArea

public HTML textArea(java.lang.String name,
                     int rows,
                     int columns)
Add a text area to the current form.

Parameters:
name -
rows -
columns -

dropMenu

public HTML dropMenu(java.lang.String name)
Add a drop-down menu to the current form.

Parameters:
name -

scrollMenu

public HTML scrollMenu(java.lang.String name,
                       int size,
                       boolean multiple)
Add a scrolling menu to the current form.

Parameters:
name -
size -
multiple -

asString

public java.lang.String asString()

backgroundColor

public HTML backgroundColor(java.lang.String color)
Set the background color to the specified value.

Parameters:
color - The color.

textColor

public HTML textColor(java.lang.String color)
Set the text color to the specified value.

Parameters:
color - The color.

linkColor

public HTML linkColor(java.lang.String color)
Set the unfollowed link color to the specified value.

Parameters:
color - The color.

vlinkColor

public HTML vlinkColor(java.lang.String color)
Set the followed link color to the specified value.

Parameters:
color - The color.

alinkColor

public HTML alinkColor(java.lang.String color)
Set the activated link color to the specified value.

Parameters:
color - The color.

backgroundImage

public HTML backgroundImage(java.lang.String image)
Set the background image to the specified value.

Parameters:
image - A URL to the background image.

raw

public HTML raw(java.lang.String string)
Append the specified text without performing any metacharacter substitutions. This is useful when the string is XML or HTML.


text

public HTML text(java.lang.String string)
Append the specified text.

Parameters:
string - The text.

fontColor

public HTML fontColor(java.lang.String color)
Set the font color to the specified value.

Parameters:
color - The color.

fontSize

public HTML fontSize(int size)
Set the font size to the specified value. Valid settings range from 1 (tiny) to 7 (fairly big) with 3 being the default size.


fontFace

public HTML fontFace(java.lang.String face)
Set the font face to the specified value. If you specify more than one value separated by commas, the browser will pick the first font that it supports.


strike

public HTML strike()
Display subsequent text using strikethrough.


align

public HTML align(java.lang.String type)

valign

public HTML valign(java.lang.String type)

stylesheet

public HTML stylesheet(java.lang.String stylesheet)
Set the style sheet to the specified value.


source

public HTML source(java.lang.String source)
Set the image source to the specified value.


alt

public HTML alt(java.lang.String string)

verticalSpace

public HTML verticalSpace(java.lang.String space)

horizontalSpace

public HTML horizontalSpace(java.lang.String space)

border

public HTML border(java.lang.String width)

cellSpacing

public HTML cellSpacing(java.lang.String amount)

cellPadding

public HTML cellPadding(java.lang.String amount)

width

public HTML width(java.lang.String amount)

rowSpan

public HTML rowSpan(java.lang.String number)

colSpan

public HTML colSpan(java.lang.String number)

rows

public HTML rows(java.lang.String rows)

name

public HTML name(java.lang.String name)

target

public HTML target(java.lang.String target)


copyright© 2001-2004 by webMethods All Rights Reserved.