Overview | Package | Class | Use | Tree | Deprecated | Index | Help
|  | BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

WebLogic Server 5.1.0sp9 API Reference

## weblogic.html
Class HeadingElement

    java.lang.Object
      |
      +--weblogic.html.HtmlElement
            |
            +--weblogic.html.ElementWithAttributes
                  |
                  +--weblogic.html.SinglePartElement
                        |
                        +--weblogic.html.HeadingElement

public class HeadingElement
extends SinglePartElement

HeadingElement objects are used to add HTML headings (H1, H2, etc.) to an htmlKona page. The heading level defaults to 1 if not specified. HTML 2.0 and above supports H1-H6. Some browsers support more heading levels. Note that not all browsers default to ALIGN=LEFT; many default to a centered alignment for headings. Valid alignments for headings are left, center, right. Also note that search engines may give words appearing in headings more importance in indexes, and may use the headings in a document to build a hierarchical outline.

Author:
  Copyright (c) 1995-96, WebLogic, Inc.
  Copyright © 2001 BEA Systems, Inc. All Rights Reserved.

Fields inherited from class weblogic.html.HtmlElement
`codeset, useObsolete`

Constructor Summary
`HeadingElement()` Constructs a HeadingElement that defaults to level H1.
`HeadingElement(HtmlElement val, int num)` Constructs a HeadingElement with the specified HtmlElement set to the specified level.
`HeadingElement(java.lang.String val)` Constructs a HeadingElement with the specified string that defaults to level H1.
`HeadingElement(java.lang.String val, int num)` Constructs a HeadingElement with the specified string set to the specified level.

Method Summary
`protected java.lang.String` | `getHtmlCode()`
`int` | `getLevel()` Gets the heading level of a HeadingElement.
`protected boolean` | `printCR()`
`HeadingElement` | `setAlign(java.lang.String align)` Sets the ALIGN attribute for a HeadingElement.
`HeadingElement` | `setAlign(TextAlignType align)` Sets the ALIGN attribute for a HeadingElement.
`HeadingElement` | `setLevel(int val)` Sets the heading level for a HeadingElement.

Methods inherited from class weblogic.html.SinglePartElement
`getElement, printBody, printBody, printBody, setElement, setElement, widthAsLiteral`

Methods inherited from class weblogic.html.ElementWithAttributes
`addAttribute, addAttribute, escapeQuotes, getBooleanAttribute, getElementAttribute, getLocalVar, getQuotedAttribute, output, output, output, printBody, printEndingTag, setBooleanAttribute, setBooleanAttribute, setClass, setDirection, setElementAttribute, setElementAttribute, setElementAttribute, setElementAttribute, setElementAttribute, setId, setLang, setLocalVar, setQuotedAttribute, setStyle`

Methods inherited from class weblogic.html.HtmlElement
`asAnchorElement, asBigElement, asBlockquoteElement, asBoldElement, asCenteredElement, asCiteElement, asCodeElement, asCommentElement, asDefineTermElement, asEmphasisElement, asFontElement, asFontElement, asFontElement, asHtmlContainer, asItalicElement, asKeyboardElement, asLiteralElement, asParagraphElement, asSampleElement, asSmallElement, asStrikeElement, asStrongElement, asSubscriptElement, asSuperscriptElement, asTeletypeElement, asUnderlineElement, asVariableElement, getVersion, setAnchorMode, setCodeset, toString, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### HeadingElement

    public HeadingElement()

  Constructs a HeadingElement that defaults to level H1.

### HeadingElement

    public HeadingElement(java.lang.String val)

  Constructs a HeadingElement with the specified string that defaults to level H1.

  Parameters:
    `val` - Heading text

### HeadingElement

    public HeadingElement(java.lang.String val,
                          int num)

  Constructs a HeadingElement with the specified string set to the specified level.

  Parameters:
    `val` - Heading text
    `num` - Heading level

### HeadingElement

    public HeadingElement(HtmlElement val,
                          int num)

  Constructs a HeadingElement with the specified HtmlElement set to the specified level.

  Parameters:
    `val` - HtmlElement
    `num` - Heading level

Method Detail

### getHtmlCode

    protected java.lang.String getHtmlCode()

  Overrides:
    getHtmlCode in class ElementWithAttributes

### printCR

    protected boolean printCR()

  Overrides:
    printCR in class ElementWithAttributes

### setLevel

    public HeadingElement setLevel(int val)

  Sets the heading level for a HeadingElement.

  Parameters:
    `val` - Heading level
  Returns:
    HeadingElement object

### setAlign

    public HeadingElement setAlign(TextAlignType align)

  Sets the ALIGN attribute for a HeadingElement.

  Parameters:
    `align` - TextAlignType alignment
  Returns:
    HeadingElement

### setAlign

    public HeadingElement setAlign(java.lang.String align)

  Sets the ALIGN attribute for a HeadingElement.

  Parameters:
    `align` - String value
  Returns:
    HeadingElement

### getLevel

    public int getLevel()

  Gets the heading level of a HeadingElement.

  Returns:
    Heading level

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Documentation is available at http://www.weblogic.com/docs51
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD