Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.struts.taglib.html
Class HtmlTag

    java.lang.Object
      |
      +--javax.servlet.jsp.tagext.TagSupport
            |
            +--org.apache.struts.taglib.html.HtmlTag

All Implemented Interfaces:
  java.io.Serializable, javax.servlet.jsp.tagext.Tag

public class HtmlTag
extends javax.servlet.jsp.tagext.TagSupport

Renders an HTML
element with appropriate language attributes if there is a current Locale available in the user's session.

Version:
  $Revision: 1.1 $ $Date: 2003/08/26 12:57:38 $
Author:
  Craig R. McClanahan, David Graham
See Also:
  Serialized Form

Field Summary
`protected boolean` | `locale` Should we set the current Locale for this user if needed?
`protected static MessageResources` | `messages` The message resources for this package.
`protected boolean` | `xhtml` Are we rendering an xhtml page?

Fields inherited from class javax.servlet.jsp.tagext.TagSupport
`id, pageContext`

Fields inherited from interface javax.servlet.jsp.tagext.Tag
`EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE`

Constructor Summary
`HtmlTag()`

Method Summary
`protected java.util.Locale` | `currentLocale()` Deprecated. Use getCurrentLocale instead because it makes the display logic easier.
`int` | `doEndTag()` Process the end of this tag.
`int` | `doStartTag()` Process the start of this tag.
`protected java.util.Locale` | `getCurrentLocale()` Return the current Locale for this request.
`boolean` | `getLocale()`
`boolean` | `getXhtml()`
`void` | `release()` Release any acquired resources.
`void` | `setLocale(boolean locale)`
`void` | `setXhtml(boolean xhtml)`

Methods inherited from class javax.servlet.jsp.tagext.TagSupport
`findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue`

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

Field Detail

### messages

    protected static MessageResources messages

  The message resources for this package.

### locale

    protected boolean locale

  Should we set the current Locale for this user if needed?

### xhtml

    protected boolean xhtml

  Are we rendering an xhtml page?

Constructor Detail

### HtmlTag

    public HtmlTag()

Method Detail

### getLocale

    public boolean getLocale()

### setLocale

    public void setLocale(boolean locale)

### getXhtml

    public boolean getXhtml()

### setXhtml

    public void setXhtml(boolean xhtml)

### doStartTag

    public int doStartTag()
                   throws javax.servlet.jsp.JspException

  Process the start of this tag.

  Specified by:
    `doStartTag` in interface `javax.servlet.jsp.tagext.Tag`
  Overrides:
    `doStartTag` in class `javax.servlet.jsp.tagext.TagSupport`
  Throws:
    `javax.servlet.jsp.JspException` - if a JSP exception has occurred

### doEndTag

    public int doEndTag()
                 throws javax.servlet.jsp.JspException

  Process the end of this tag.

  Specified by:
    `doEndTag` in interface `javax.servlet.jsp.tagext.Tag`
  Overrides:
    `doEndTag` in class `javax.servlet.jsp.tagext.TagSupport`
  Throws:
    `javax.servlet.jsp.JspException` - if a JSP exception has occurred

### release

    public void release()

  Release any acquired resources.

  Specified by:
    `release` in interface `javax.servlet.jsp.tagext.Tag`
  Overrides:
    `release` in class `javax.servlet.jsp.tagext.TagSupport`

### currentLocale

    protected java.util.Locale currentLocale()

  Deprecated. Use getCurrentLocale instead because it makes the display logic easier.

  Return the current Locale for this request, creating a new one if necessary. If there is no current Locale, and locale support is not requested, return `null`.

### getCurrentLocale

    protected java.util.Locale getCurrentLocale()

  Return the current Locale for this request. If there is no locale in the session and the locale attribute is set to "true", this method will create a Locale based on the client's Accept-Language header or the server's default locale and store it in the session. This will always return a Locale and never null.

  Since:
    Struts 1.1

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000-2003 - Apache Software Foundation