PAJES 2.3.9

org.pajes.html
Class Heading

java.lang.Object
  extended byorg.pajes.html.Tag
      extended byorg.pajes.html.TraversableElement
          extended byorg.pajes.html.SingleElementContainer
              extended byorg.pajes.html.Heading
All Implemented Interfaces:
java.lang.Cloneable, HTML, java.io.Serializable, Traversable

public class Heading
extends SingleElementContainer

Places the heading tags around a piece of text or HTML.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.pajes.html.Tag
ON_CLICK_ATTRIBUTE, TAG_CLOSE, TAG_LEFT, TAG_RIGHT
 
Constructor Summary
Heading(int level, HTML text)
          Wraps heading tags around a line of pre-formatted HTML.
Heading(int level, HTML text, java.lang.String alignment)
          Wraps heading tags around a line of pre-formatted HTML.
Heading(int level, java.lang.String text)
          Wraps heading tags around a line of pre-formatted HTML.
Heading(int level, java.lang.String text, java.lang.String alignment)
          Wraps heading tags around a line of pre-formatted HTML.
 
Method Summary
 Heading setAlignment(java.lang.String alignment)
          Sets the alignment of the heading.
 Heading setText(HTML text)
          Sets the text of the heading.
 Heading setText(java.lang.String text)
          Sets the text of the heading.
 
Methods inherited from class org.pajes.html.SingleElementContainer
get, set, size, writeContent
 
Methods inherited from class org.pajes.html.TraversableElement
dump, dump, getAll, getFieldByName, getFirstFieldByName, getFirstTagByAttribute, getFirstTagByClass, getFirstTagByID, getFirstTagByName, getTagByAttribute, getTagByClass, getTagByID, getTagByName, setWritable
 
Methods inherited from class org.pajes.html.Tag
addAttribute, addAttributes, addAttributes, addContent, clearAttribute, clearAttributes, clone, destroy, getAttribute, getAttributes, getAttributeSet, getContainer, getContent, getDocument, getId, getOnClickHandler, getOnDBLClickHandler, getOnKeyDownHandler, getOnKeyPressHandler, getOnKeyUpHandler, getOnMouseDownHandler, getOnMouseOutHandler, getOnMouseOverHandler, getOnMouseUpHandler, getStyle, getStyleSheetClass, getTagName, getTitle, getWritePermission, init, initAttributes, isWritable, isWritable, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttributes, setAttributes, setContainer, setContent, setContent, setId, setOnClickHandler, setOnDBLClickHandler, setOnKeyDownHandler, setOnKeyPressHandler, setOnKeyUpHandler, setOnMouseDownHandler, setOnMouseOutHandler, setOnMouseOverHandler, setOnMouseUpHandler, setStyle, setStyleSheetClass, setTagName, setTitle, setWritable, setWriteAttributes, setWriteEndTag, setWritelnAfter, setWritelnAfterContent, setWritelnBefore, setWritelnBeforeContent, setWritePermission, toString, write
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Heading

public Heading(int level,
               HTML text)
Wraps heading tags around a line of pre-formatted HTML.

Parameters:
level - the heading level between 1 and 6.
text - the text to display as a heading.
Throws:
TagException - if an invalid heading level number is specified.

Heading

public Heading(int level,
               HTML text,
               java.lang.String alignment)
Wraps heading tags around a line of pre-formatted HTML.

Parameters:
level - the heading level between 1 and 6.
text - the text to display as a heading.
alignment - the alignment of the heading (Left, Center or Right).

Heading

public Heading(int level,
               java.lang.String text)
Wraps heading tags around a line of pre-formatted HTML.

Parameters:
level - the heading level between 1 and 6.
text - the text to display as a heading.

Heading

public Heading(int level,
               java.lang.String text,
               java.lang.String alignment)
Wraps heading tags around a line of pre-formatted HTML.

Parameters:
level - the heading level between 1 and 6.
text - the text to display as a heading.
alignment - the alignment of the heading (Left, Center or Right).
Method Detail

setAlignment

public Heading setAlignment(java.lang.String alignment)
Sets the alignment of the heading.

Parameters:
alignment - Left, Center or Right
Returns:
the modified Heading object.
Throws:
TagException - if an invalid alignment is specified.

setText

public Heading setText(HTML text)
Sets the text of the heading.

Parameters:
text - the text to display as a heading.
Returns:
the modified Heading object.

setText

public Heading setText(java.lang.String text)
Sets the text of the heading.

Parameters:
text - the text to display as a heading.
Returns:
the modified Heading object.

PAJES 2.3.9

Copyright © 2002-2003 Viridian Pty Limited. All Rights Reserved.