|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectTagSupport
BodyTagSupport
AbstractClassicTag
ScriptContainer
Html
public class Html
Generates the html element and performs error handling within its body.
<netui:html dir="LTR" useLocale="true" />
JavaScript
The <netui:html> tag writes out the following JavaScript functions:
function getNetuiTagName(id) { return netui_names[id]; } function getNetuiTagName(id, tag) { if (scopeId == "") return netui_names[id]; else return netui_names[portletId__id]; } function getScopeId(tag) { if (tag == null) return ""; if (tag.scopeId != null) return tag.scopeId; return getScopeId(tag.parentElement); } results.append("\nfunction getNetuiTagName(id) {\n"); results.append("\treturn "); results.append(NAMES_OBJECT); results.append("[id]; }\n\n"); results.append("\nfunction getNetuiTagName(id, tag) {\n"); results.append("\tvar scopeId = getScopeId(tag);\n"); results.append("\tif (scopeId == \"\")\n"); results.append("\t\treturn "); results.append(NAMES_OBJECT); results.append("[id];\n"); results.append("\telse\n\t\treturn "); results.append(NAMES_OBJECT); results.append("[portletId + \"__\" + id]; }\n\n"); results.append("\nfunction getScopeId(tag) {\n"); results.append("\tif (tag == null) return \"\";\n"); results.append("\tif (tag.scopeId != null) return tag.scopeId;\n"); results.append("\treturn getScopeId(tag.parentElement);\n}\n\n");
Field Summary | |
---|---|
static String |
HTML_401
Constant representing the document type html 4.01 |
static String |
HTML_TAG_ID
The HTML tag is registered into the request with this name. |
static String |
XHTML_10
Constant representing the document type XHTML 1.0 Transitional. |
Fields inherited from class AbstractClassicTag |
---|
DefaultNamingChain, EMPTY_STRING, NETUI_UNIQUE_CNT |
Fields inherited from class BodyTagSupport |
---|
bodyContent |
Fields inherited from class TagSupport |
---|
id, pageContext |
Fields inherited from interface IErrorReporter |
---|
CONTAINER_ERRORS |
Fields inherited from interface BodyTag |
---|
EVAL_BODY_BUFFERED, EVAL_BODY_TAG |
Fields inherited from interface IterationTag |
---|
EVAL_BODY_AGAIN |
Fields inherited from interface Tag |
---|
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE |
Constructor Summary | |
---|---|
Html()
|
Method Summary | |
---|---|
void |
addError(AbstractPageError ape)
Add an error to the errors being reported by this tag. |
protected Locale |
currentLocale()
Return the current Locale for this request, creating a new one if necessary. |
int |
doAfterBody()
Save any body content of this tag, which will generally be the option(s) representing the values displayed to the user. |
int |
doEndTag()
Write out the body content and report any errors that occured. |
int |
doStartTag()
|
String |
getDocumentType()
|
int |
getNextId()
This method will return the next unique integer within the scope of this tag. |
String |
getTagName()
Returns the name of the Tag. |
int |
getTargetDocumentType()
This method will return the TagRenderBase enum value for the document type. |
boolean |
isReporting()
This boolean indicates if an ErrorReporter is reporting errors or not. |
boolean |
isUseLocale()
Gets whether the default locale's language should be used. |
protected void |
localRelease()
Release any acquired resources. |
ArrayList |
returnErrors()
Return an ArrayList of the errors |
void |
setDir(String dir)
Sets the dir value of the html. |
void |
setDocumentType(String docType)
|
void |
setUseLocale(boolean locale)
Sets whether the default locale's language should be used. |
Methods inherited from class BodyTagSupport |
---|
doInitBody, getBodyContent, getPreviousOut, release, setBodyContent |
Methods inherited from class TagSupport |
---|
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface Tag |
---|
getParent, setPageContext, setParent |
Field Detail |
---|
public static final String HTML_TAG_ID
ErrorReporter
.
public static final String HTML_401
public static final String XHTML_10
Constructor Detail |
---|
public Html()
Method Detail |
---|
public String getTagName()
getTagName
in interface INetuiTag
getTagName
in class ScriptContainer
public int getTargetDocumentType()
public void setDir(String dir)
dir
- - "LTR" or "RTL"public boolean isUseLocale()
public void setUseLocale(boolean locale)
locale
- - true or falsepublic String getDocumentType()
public void setDocumentType(String docType)
public int doStartTag() throws JspException
doStartTag
in interface Tag
doStartTag
in class ScriptContainer
JspException
public int doAfterBody() throws JspException
doAfterBody
in interface IterationTag
doAfterBody
in class ScriptContainer
JspException
- if a JSP exception has occurredpublic int doEndTag() throws JspException
doEndTag
in interface Tag
doEndTag
in class ScriptContainer
JspException
- if a JSP exception has occurredpublic void addError(AbstractPageError ape)
addError
in interface IErrorReporter
ape
- - The AbstractPageError to addpublic int getNextId()
public ArrayList returnErrors()
returnErrors
in interface IErrorReporter
ArrayList
of all errors.public boolean isReporting()
isReporting
in interface IErrorReporter
protected Locale currentLocale()
null
.
protected void localRelease()
localRelease
in class ScriptContainer
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |