|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.myfaces.shared.renderkit.html.HtmlRendererUtils
public final class HtmlRendererUtils
Nested Class Summary | |
---|---|
static class |
HtmlRendererUtils.LinkParameter
|
static class |
HtmlRendererUtils.ScriptContext
The ScriptContext offers methods and fields to help with rendering out a script and keeping a proper formatting. |
Field Summary | |
---|---|
static java.lang.String |
ALLOW_CDATA_SECTION_ON
|
static java.lang.String |
CLEAR_HIDDEN_FIELD_FN_NAME
|
static java.lang.String |
DEFAULT_CHAR_ENCODING
|
static java.lang.String |
HIDDEN_COMMANDLINK_FIELD_NAME
|
static java.lang.String |
HIDDEN_COMMANDLINK_FIELD_NAME_MYFACES_OLD
|
static java.lang.String |
HIDDEN_COMMANDLINK_FIELD_NAME_TRINIDAD
|
static java.lang.String |
SUBMIT_FORM_FN_NAME
|
Method Summary | |
---|---|
static void |
allowCdataSection(javax.faces.context.FacesContext fc,
boolean cdataSectionAllowed)
|
static void |
appendAutoScrollAssignment(java.lang.StringBuffer onClickValue,
java.lang.String formName)
Adds the hidden form input value assignment that is necessary for the autoscroll feature to an html link or button onclick attribute. |
static void |
appendClearHiddenCommandFormParamsFunctionCall(java.lang.StringBuffer buf,
java.lang.String formName)
|
static void |
decodeUIInput(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent component)
Utility to set the submitted value of the provided component from the data in the current request object. |
static void |
decodeUISelectBoolean(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent component)
X-CHECKED: tlddoc h:selectBooleanCheckbox |
static void |
decodeUISelectMany(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent component)
X-CHECKED: tlddoc h:selectManyListbox |
static void |
decodeUISelectOne(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent component)
X-CHECKED: tlddoc h:selectManyListbox |
static javax.faces.convert.Converter |
findUIOutputConverterFailSafe(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent uiComponent)
|
static javax.faces.convert.Converter |
findUISelectManyConverterFailsafe(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent uiComponent)
|
static java.lang.String |
getClearHiddenCommandFormParamsFunctionName(java.lang.String formName)
Prefixes the given String with CLEAR_HIDDEN_FIELD_FN_NAME and removes special characters |
static java.lang.String |
getClearHiddenCommandFormParamsFunctionNameMyfacesLegacy(java.lang.String formName)
|
static java.lang.String |
getDisplayValueOnlyStyle(javax.faces.component.UIComponent component)
|
static java.lang.String |
getDisplayValueOnlyStyleClass(javax.faces.component.UIComponent component)
|
static java.lang.String |
getHiddenCommandLinkFieldName(FormInfo formInfo)
Get the name of the request parameter that holds the id of the link-type component that caused the form to be submitted. |
static java.lang.String |
getHiddenCommandLinkFieldNameMyfacesOld(FormInfo formInfo)
|
static java.lang.String |
getImageLocation(javax.faces.component.UIComponent component)
|
static java.lang.String |
getJavascriptLocation(javax.faces.component.UIComponent component)
|
static java.lang.String |
getStyleLocation(javax.faces.component.UIComponent component)
|
static java.util.Set |
getSubmittedOrSelectedValuesAsSet(boolean selectMany,
javax.faces.component.UIComponent uiComponent,
javax.faces.context.FacesContext facesContext,
javax.faces.convert.Converter converter)
|
static java.lang.String[] |
getSupportedContentTypes()
|
static boolean |
isAllowedCdataSection(javax.faces.context.FacesContext fc)
|
static boolean |
isDisabledOrReadOnly(javax.faces.component.UIComponent component)
|
static boolean |
isDisplayValueOnly(javax.faces.component.UIComponent component)
|
static boolean |
isXHTMLContentType(java.lang.String contentType)
|
static void |
renderAutoScrollFunction(javax.faces.context.FacesContext facesContext,
javax.faces.context.ResponseWriter writer)
Renders the autoscroll javascript function. |
static void |
renderAutoScrollHiddenInput(javax.faces.context.FacesContext facesContext,
javax.faces.context.ResponseWriter writer)
Renders the hidden form input that is necessary for the autoscroll feature. |
static void |
renderClearHiddenCommandFormParamsFunction(javax.faces.context.ResponseWriter writer,
java.lang.String formName,
java.util.Set dummyFormParams,
java.lang.String formTarget)
Render the javascript function that is called on a click on a commandLink to clear the hidden inputs. |
static void |
renderDisplayValueOnly(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent input)
|
static void |
renderDisplayValueOnlyAttributes(javax.faces.component.UIComponent uiComponent,
javax.faces.context.ResponseWriter writer)
|
static void |
renderDisplayValueOnlyForSelects(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent uiComponent)
|
static void |
renderFormSubmitScript(javax.faces.context.FacesContext facesContext)
|
static void |
renderHiddenCommandFormParams(javax.faces.context.ResponseWriter writer,
java.util.Set dummyFormParams)
|
static void |
renderHiddenInputField(javax.faces.context.ResponseWriter writer,
java.lang.Object name,
java.lang.Object value)
|
static boolean |
renderHTMLAttribute(javax.faces.context.ResponseWriter writer,
java.lang.String componentProperty,
java.lang.String attrName,
java.lang.Object value)
|
static boolean |
renderHTMLAttribute(javax.faces.context.ResponseWriter writer,
javax.faces.component.UIComponent component,
java.lang.String componentProperty,
java.lang.String htmlAttrName)
|
static boolean |
renderHTMLAttributes(javax.faces.context.ResponseWriter writer,
javax.faces.component.UIComponent component,
java.lang.String[] attributes)
|
static boolean |
renderHTMLAttributesWithOptionalStartElement(javax.faces.context.ResponseWriter writer,
javax.faces.component.UIComponent component,
java.lang.String elementName,
java.lang.String[] attributes)
|
static boolean |
renderHTMLAttributeWithOptionalStartElement(javax.faces.context.ResponseWriter writer,
javax.faces.component.UIComponent component,
java.lang.String elementName,
java.lang.String attrName,
java.lang.Object value,
boolean startElementWritten)
|
static void |
renderListbox(javax.faces.context.FacesContext facesContext,
javax.faces.component.UISelectMany selectMany,
boolean disabled,
int size)
|
static void |
renderListbox(javax.faces.context.FacesContext facesContext,
javax.faces.component.UISelectOne selectOne,
boolean disabled,
int size)
|
static void |
renderMenu(javax.faces.context.FacesContext facesContext,
javax.faces.component.UISelectMany selectMany,
boolean disabled)
|
static void |
renderMenu(javax.faces.context.FacesContext facesContext,
javax.faces.component.UISelectOne selectOne,
boolean disabled)
|
static boolean |
renderOptionalEndElement(javax.faces.context.ResponseWriter writer,
javax.faces.component.UIComponent component,
java.lang.String elementName,
java.lang.String[] attributes)
|
static void |
renderSelectOptions(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent component,
javax.faces.convert.Converter converter,
java.util.Set lookupSet,
java.util.List selectItemList)
Renders the select options for a UIComponent that is
rendered as an HTML select element. |
static java.lang.String |
selectContentType(java.lang.String contentTypeListString)
|
static void |
writeIdIfNecessary(javax.faces.context.ResponseWriter writer,
javax.faces.component.UIComponent component,
javax.faces.context.FacesContext facesContext)
|
static void |
writePrettyIndent(javax.faces.context.FacesContext facesContext)
|
static void |
writePrettyLineSeparator(javax.faces.context.FacesContext facesContext)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String HIDDEN_COMMANDLINK_FIELD_NAME
public static final java.lang.String HIDDEN_COMMANDLINK_FIELD_NAME_MYFACES_OLD
public static final java.lang.String HIDDEN_COMMANDLINK_FIELD_NAME_TRINIDAD
public static final java.lang.String CLEAR_HIDDEN_FIELD_FN_NAME
public static final java.lang.String SUBMIT_FORM_FN_NAME
public static final java.lang.String ALLOW_CDATA_SECTION_ON
public static java.lang.String DEFAULT_CHAR_ENCODING
Method Detail |
---|
public static void decodeUIInput(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent component)
public static void decodeUISelectBoolean(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent component)
facesContext
- component
- public static boolean isDisabledOrReadOnly(javax.faces.component.UIComponent component)
public static void decodeUISelectMany(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent component)
facesContext
- component
- public static void decodeUISelectOne(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent component)
facesContext
- component
- public static void renderListbox(javax.faces.context.FacesContext facesContext, javax.faces.component.UISelectOne selectOne, boolean disabled, int size) throws java.io.IOException
java.io.IOException
public static void renderListbox(javax.faces.context.FacesContext facesContext, javax.faces.component.UISelectMany selectMany, boolean disabled, int size) throws java.io.IOException
java.io.IOException
public static void renderMenu(javax.faces.context.FacesContext facesContext, javax.faces.component.UISelectOne selectOne, boolean disabled) throws java.io.IOException
java.io.IOException
public static void renderMenu(javax.faces.context.FacesContext facesContext, javax.faces.component.UISelectMany selectMany, boolean disabled) throws java.io.IOException
java.io.IOException
public static java.util.Set getSubmittedOrSelectedValuesAsSet(boolean selectMany, javax.faces.component.UIComponent uiComponent, javax.faces.context.FacesContext facesContext, javax.faces.convert.Converter converter)
public static javax.faces.convert.Converter findUISelectManyConverterFailsafe(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent)
public static javax.faces.convert.Converter findUIOutputConverterFailSafe(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent)
public static void renderSelectOptions(javax.faces.context.FacesContext context, javax.faces.component.UIComponent component, javax.faces.convert.Converter converter, java.util.Set lookupSet, java.util.List selectItemList) throws java.io.IOException
UIComponent
that is
rendered as an HTML select element.
context
- the current FacesContext
.component
- the UIComponent
whose options need to be
rendered.converter
- component
's converterlookupSet
- the Set
to use to look up selected optionsselectItemList
- the List
of SelectItem
s to be
rendered as HTML option elements.
java.io.IOException
public static void writePrettyLineSeparator(javax.faces.context.FacesContext facesContext) throws java.io.IOException
java.io.IOException
public static void writePrettyIndent(javax.faces.context.FacesContext facesContext) throws java.io.IOException
java.io.IOException
public static boolean renderHTMLAttribute(javax.faces.context.ResponseWriter writer, java.lang.String componentProperty, java.lang.String attrName, java.lang.Object value) throws java.io.IOException
java.io.IOException
public static boolean renderHTMLAttribute(javax.faces.context.ResponseWriter writer, javax.faces.component.UIComponent component, java.lang.String componentProperty, java.lang.String htmlAttrName) throws java.io.IOException
java.io.IOException
public static boolean renderHTMLAttributes(javax.faces.context.ResponseWriter writer, javax.faces.component.UIComponent component, java.lang.String[] attributes) throws java.io.IOException
java.io.IOException
public static boolean renderHTMLAttributeWithOptionalStartElement(javax.faces.context.ResponseWriter writer, javax.faces.component.UIComponent component, java.lang.String elementName, java.lang.String attrName, java.lang.Object value, boolean startElementWritten) throws java.io.IOException
java.io.IOException
public static boolean renderHTMLAttributesWithOptionalStartElement(javax.faces.context.ResponseWriter writer, javax.faces.component.UIComponent component, java.lang.String elementName, java.lang.String[] attributes) throws java.io.IOException
java.io.IOException
public static boolean renderOptionalEndElement(javax.faces.context.ResponseWriter writer, javax.faces.component.UIComponent component, java.lang.String elementName, java.lang.String[] attributes) throws java.io.IOException
java.io.IOException
public static void writeIdIfNecessary(javax.faces.context.ResponseWriter writer, javax.faces.component.UIComponent component, javax.faces.context.FacesContext facesContext) throws java.io.IOException
java.io.IOException
public static void renderDisplayValueOnlyForSelects(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent) throws java.io.IOException
java.io.IOException
public static void renderDisplayValueOnlyAttributes(javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer) throws java.io.IOException
java.io.IOException
public static java.lang.String getDisplayValueOnlyStyleClass(javax.faces.component.UIComponent component)
public static java.lang.String getDisplayValueOnlyStyle(javax.faces.component.UIComponent component)
public static boolean isDisplayValueOnly(javax.faces.component.UIComponent component)
public static void renderDisplayValueOnly(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent input) throws java.io.IOException
java.io.IOException
public static void appendClearHiddenCommandFormParamsFunctionCall(java.lang.StringBuffer buf, java.lang.String formName)
public static void renderFormSubmitScript(javax.faces.context.FacesContext facesContext) throws java.io.IOException
java.io.IOException
public static void appendAutoScrollAssignment(java.lang.StringBuffer onClickValue, java.lang.String formName)
public static void renderAutoScrollHiddenInput(javax.faces.context.FacesContext facesContext, javax.faces.context.ResponseWriter writer) throws java.io.IOException
java.io.IOException
public static void renderAutoScrollFunction(javax.faces.context.FacesContext facesContext, javax.faces.context.ResponseWriter writer) throws java.io.IOException
java.io.IOException
public static boolean isAllowedCdataSection(javax.faces.context.FacesContext fc)
public static void allowCdataSection(javax.faces.context.FacesContext fc, boolean cdataSectionAllowed)
public static void renderHiddenCommandFormParams(javax.faces.context.ResponseWriter writer, java.util.Set dummyFormParams) throws java.io.IOException
java.io.IOException
public static void renderHiddenInputField(javax.faces.context.ResponseWriter writer, java.lang.Object name, java.lang.Object value) throws java.io.IOException
java.io.IOException
public static void renderClearHiddenCommandFormParamsFunction(javax.faces.context.ResponseWriter writer, java.lang.String formName, java.util.Set dummyFormParams, java.lang.String formTarget) throws java.io.IOException
writer
- formName
- dummyFormParams
- formTarget
-
java.io.IOException
public static java.lang.String getClearHiddenCommandFormParamsFunctionName(java.lang.String formName)
formName
-
public static java.lang.String getClearHiddenCommandFormParamsFunctionNameMyfacesLegacy(java.lang.String formName)
public static java.lang.String getHiddenCommandLinkFieldName(FormInfo formInfo)
public static java.lang.String getHiddenCommandLinkFieldNameMyfacesOld(FormInfo formInfo)
public static java.lang.String selectContentType(java.lang.String contentTypeListString)
public static java.lang.String[] getSupportedContentTypes()
public static boolean isXHTMLContentType(java.lang.String contentType)
public static java.lang.String getJavascriptLocation(javax.faces.component.UIComponent component)
public static java.lang.String getImageLocation(javax.faces.component.UIComponent component)
public static java.lang.String getStyleLocation(javax.faces.component.UIComponent component)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |