org.apache.myfaces.trinidadinternal.renderkit.core.xhtml
Class XhtmlRenderer

java.lang.Object
  extended by javax.faces.render.Renderer
      extended by org.apache.myfaces.trinidad.render.CoreRenderer
          extended by org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.XhtmlRenderer
All Implemented Interfaces:
java.lang.Cloneable, org.apache.myfaces.trinidad.render.TypedRenderer
Direct Known Subclasses:
BreadCrumbsRenderer, CellFormatRenderer, ChartRenderer, ChooseDateRenderer, ColumnGroupRenderer, DesktopPanelPageHeaderRenderer, DocumentRenderer, FormRenderer, FrameBorderLayoutRenderer, FrameRenderer, FrameRenderer, GoLinkRenderer, HeadRenderer, HtmlRenderer, IconRenderer, ImageRenderer, ImportScriptRenderer, LabelAndMessageRenderer, MediaRenderer, MessageBoxRenderer, MetaRenderer, NavigationPaneRenderer, PanelAccordionRenderer, PanelBorderLayoutRenderer, PanelBoxRenderer, PanelCaptionGroupRenderer, PanelFormLayoutRenderer, PanelGroupLayoutRenderer, PanelHeaderRenderer, PanelHorizontalLayoutRenderer, PanelListRenderer, PanelPartialRootRenderer, PanelPopupRenderer, PanelTipRenderer, PdaFrameBorderLayoutRenderer, PdaPanelPageHeaderRenderer, PollRenderer, RowLayoutRenderer, ScriptRenderer, SelectRangeChoiceBarRenderer, SeparatorRenderer, ShowDetailItemRenderer, SingleStepButtonBarRenderer, SpacerRenderer, StatusIndicatorRenderer, StyleSheetRenderer, TableLayoutRenderer, TableRenderer, TableSelectOneRenderer, TrainRenderer, TrainRenderer, TreeRenderer, TreeTableNavRenderer, ValueRenderer

public class XhtmlRenderer
extends org.apache.myfaces.trinidad.render.CoreRenderer
implements org.apache.myfaces.trinidad.render.TypedRenderer, java.lang.Cloneable


Field Summary
static java.lang.String TRANSPARENT_GIF
           
 
Fields inherited from class org.apache.myfaces.trinidad.render.CoreRenderer
CHAR_UNDEFINED, NO_CHILD_INDEX
 
Constructor Summary
protected XhtmlRenderer(org.apache.myfaces.trinidad.bean.FacesBean.Type type)
           
 
Method Summary
protected  boolean canSkipRendering(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, javax.faces.component.UIComponent component)
          Returns true if the component can skip its own rendering; true if PPR is on for this request, is not currently active, and this component not a target.
protected  boolean canSkipRendering(org.apache.myfaces.trinidad.context.RenderingContext rc, java.lang.String clientId)
          Returns true if the component can skip its own rendering; true if PPR is on for this request, is not currently active, and this component not a target.
 javax.faces.render.Renderer cloneWithType(org.apache.myfaces.trinidad.bean.FacesBean.Type type)
          Clone a Renderer instance with a new Type.
protected  void findTypeConstants(org.apache.myfaces.trinidad.bean.FacesBean.Type type)
           
static java.lang.String getAbsoluteImageUri(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, java.lang.String imagePath)
           
protected static java.lang.String getBaseImageUri(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc)
           
protected  java.lang.String getDefaultStyleClass(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getInlineStyle(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnclick(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOndblclick(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnkeydown(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnkeypress(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnkeyup(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnmousedown(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnmousemove(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnmouseout(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnmouseover(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getOnmouseup(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String[] getPartialTriggers(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getShortDesc(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  java.lang.String getStyleClass(javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  void renderAllAttributes(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
          Render the main renderer-specific attributes: "title", "class", "style", and all the Javascript attributes.
protected  void renderAllAttributes(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean, boolean renderStyleAttrs)
          Render the main renderer-specific attributes: "title", "class", "style", and all the Javascript attributes.
protected  void renderDecorativeIcon(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, java.lang.String iconUri, java.lang.Object width, java.lang.Object height, java.lang.Object id, java.lang.Object altText)
          Renders an icon.
protected  void renderDecorativeIcon(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, java.lang.String iconUri, java.lang.Object width, java.lang.Object height, java.lang.Object id, java.lang.Object altText, javax.faces.component.UIComponent comp)
           
protected  void renderEventHandlers(javax.faces.context.FacesContext context, javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
          Render all the Javascript attributes.
protected  void renderFormattedText(javax.faces.context.FacesContext context, java.lang.Object textValue)
           
protected static void renderHAlign(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, java.lang.Object hAlign)
           
protected  void renderInlineStyle(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
static void renderInlineStyleAttribute(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, javax.faces.component.UIComponent component, java.lang.String style)
          Renders the inline style attribute for the specified node
protected  void renderPossiblyFormattedText(javax.faces.context.FacesContext context, java.lang.Object textValue)
           
static void renderScriptDeferAttribute(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc)
          Renders the "defer" attribute for a script element.
static void renderScriptTypeAttribute(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc)
          Checks whether in inaccessible mode, and if not, renders "type" attribute for a script element.
protected  void renderShortDescAttribute(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  void renderSpacer(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, java.lang.String width, java.lang.String height)
          Renders a spacer.
protected  void renderStyleAttributes(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean)
           
protected  void renderStyleAttributes(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, javax.faces.component.UIComponent component, org.apache.myfaces.trinidad.bean.FacesBean bean, java.lang.String defaultStyleClass)
          When there's a default style class pass it in to this method
static void renderSubmitButtonNonJSBrowser(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, java.lang.String valueAttri, java.lang.String nameAttri)
          This method renders an input element of type "submit".
protected  void renderTransparent(javax.faces.context.FacesContext context, org.apache.myfaces.trinidad.context.RenderingContext rc, java.lang.String width, java.lang.String height, boolean needsQuoting, java.lang.Object id)
          Renders a transparent gif using a script to save space.
protected  void renderVerticalSpacer(javax.faces.context.FacesContext context, java.lang.Object height, java.lang.Object id, javax.faces.component.UIComponent comp)
          Renders a vertical spacer for a specified non-null height.
protected  java.lang.Object resolveProperty(org.apache.myfaces.trinidad.bean.FacesBean bean, org.apache.myfaces.trinidad.bean.PropertyKey key)
          This method evaluates the property of the specified bean if it supports the specified property key and if the current value is null, then evaluate the default value.
protected  java.lang.Object resolveProperty(org.apache.myfaces.trinidad.bean.FacesBean bean, org.apache.myfaces.trinidad.bean.PropertyKey key, boolean checkDefault)
          This method evaluates the property of the specified bean if it supports the specified property key and if the current value is null, then evaluate the default value if and only if checkDefault is true.
protected  boolean shouldRenderId(javax.faces.context.FacesContext context, javax.faces.component.UIComponent component)
          Returns true if the component should render an ID.
protected  boolean skipDecode(javax.faces.context.FacesContext context)
           
static boolean supportsAccessKeys(org.apache.myfaces.trinidad.context.RenderingContext rc)
           
static boolean supportsAdvancedForms(org.apache.myfaces.trinidad.context.RenderingContext rc)
           
static boolean supportsAutoCompleteFormElements(org.apache.myfaces.trinidad.context.RenderingContext rc)
           
static boolean supportsDisabledFormElements(org.apache.myfaces.trinidad.context.RenderingContext rc)
           
static boolean supportsEditing(org.apache.myfaces.trinidad.context.RenderingContext rc)
           
static boolean supportsIntrinsicEvents(org.apache.myfaces.trinidad.context.RenderingContext rc)
          See section 5.14 of xhtml modularization.
static boolean supportsNarrowScreen(org.apache.myfaces.trinidad.context.RenderingContext rc)
          Returns true if an agent is a narrow-screen PDA
static boolean supportsNavigation(org.apache.myfaces.trinidad.context.RenderingContext rc)
           
static boolean supportsOnClickOnImgInput(org.apache.myfaces.trinidad.context.RenderingContext rc)
          Returns true if the agent supports the "onclick" JS Handler in an "input" HTML element of type "image"
static boolean supportsReadonlyFormElements(org.apache.myfaces.trinidad.context.RenderingContext rc)
           
static boolean supportsScripting(org.apache.myfaces.trinidad.context.RenderingContext rc)
          Returns true if the agent supports the Script module.
static boolean supportsSeparateWindow(org.apache.myfaces.trinidad.context.RenderingContext rc)
           
static boolean supportsStyleAttributes(org.apache.myfaces.trinidad.context.RenderingContext rc)
          Returns true if the style attributes should be rendered for this node.
static boolean supportsTarget(org.apache.myfaces.trinidad.context.RenderingContext rc)
          Returns true if the agent supports setting the target attribute of other elements.
static boolean supportsTextPresentation(org.apache.myfaces.trinidad.context.RenderingContext rc)
          Returns true if the agent supports the text presentation module.
 
Methods inherited from class org.apache.myfaces.trinidad.render.CoreRenderer
afterEncode, beforeEncode, decode, decode, decodeBehaviors, delegateRenderer, delegateRendererBegin, delegateRendererEnd, encodeAll, encodeAllChildren, encodeBegin, encodeBegin, encodeChild, encodeChildren, encodeComponentResources, encodeEnd, encodeEnd, getBehaviorParameters, getClientId, getFacesBean, getFacet, getNextRenderedChildIndex, getRenderedChildCount, getRenderedFacetsAndChildren, getRenderingProperty, hasRenderedChildren, isDesktop, isGecko, isGenericPDA, isIE, isInaccessibleMode, isIPhone, isKonqueror, isNokiaS60, isOpera, isPDA, isScreenReaderMode, isWebKit, partialEncodeVisit, renderEncodedActionURI, renderEncodedResourceURI, renderId, renderStyleClass, renderStyleClasses, setRenderingProperty, setupChildrenEncodingContext, setupEncodingContext, setupEncodingContext, tearDownChildrenEncodingContext, tearDownEncodingContext, tearDownEncodingContext, toActionUri, toChar, toInt, toLong, toResourceUri, toString, toUri, visitChildrenForEncoding
 
Methods inherited from class javax.faces.render.Renderer
convertClientId, getConvertedValue, getRendersChildren
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TRANSPARENT_GIF

public static final java.lang.String TRANSPARENT_GIF
See Also:
Constant Field Values
Constructor Detail

XhtmlRenderer

protected XhtmlRenderer(org.apache.myfaces.trinidad.bean.FacesBean.Type type)
Method Detail

cloneWithType

public javax.faces.render.Renderer cloneWithType(org.apache.myfaces.trinidad.bean.FacesBean.Type type)
Clone a Renderer instance with a new Type.

Specified by:
cloneWithType in interface org.apache.myfaces.trinidad.render.TypedRenderer

findTypeConstants

protected void findTypeConstants(org.apache.myfaces.trinidad.bean.FacesBean.Type type)

supportsScripting

public static boolean supportsScripting(org.apache.myfaces.trinidad.context.RenderingContext rc)
Returns true if the agent supports the Script module.

See section 5.16 of xhtml modularization


supportsEditing

public static boolean supportsEditing(org.apache.myfaces.trinidad.context.RenderingContext rc)

supportsAdvancedForms

public static boolean supportsAdvancedForms(org.apache.myfaces.trinidad.context.RenderingContext rc)

supportsIntrinsicEvents

public static boolean supportsIntrinsicEvents(org.apache.myfaces.trinidad.context.RenderingContext rc)
See section 5.14 of xhtml modularization.


supportsStyleAttributes

public static boolean supportsStyleAttributes(org.apache.myfaces.trinidad.context.RenderingContext rc)
Returns true if the style attributes should be rendered for this node.

Clients should override this method if the the user agent doesn't support style attributes.

See section 5.18 of xhtml modularization


supportsNavigation

public static boolean supportsNavigation(org.apache.myfaces.trinidad.context.RenderingContext rc)

supportsTextPresentation

public static boolean supportsTextPresentation(org.apache.myfaces.trinidad.context.RenderingContext rc)
Returns true if the agent supports the text presentation module.

See section 5.4.1 of xhtml modularization.


supportsAccessKeys

public static boolean supportsAccessKeys(org.apache.myfaces.trinidad.context.RenderingContext rc)

supportsDisabledFormElements

public static final boolean supportsDisabledFormElements(org.apache.myfaces.trinidad.context.RenderingContext rc)

supportsReadonlyFormElements

public static final boolean supportsReadonlyFormElements(org.apache.myfaces.trinidad.context.RenderingContext rc)

supportsAutoCompleteFormElements

public static final boolean supportsAutoCompleteFormElements(org.apache.myfaces.trinidad.context.RenderingContext rc)

supportsSeparateWindow

public static final boolean supportsSeparateWindow(org.apache.myfaces.trinidad.context.RenderingContext rc)

supportsTarget

public static final boolean supportsTarget(org.apache.myfaces.trinidad.context.RenderingContext rc)
Returns true if the agent supports setting the target attribute of other elements.

See section 5.12 of xhtml modularization.


supportsNarrowScreen

public static boolean supportsNarrowScreen(org.apache.myfaces.trinidad.context.RenderingContext rc)
Returns true if an agent is a narrow-screen PDA

Parameters:
context - a RenderingContext
Returns:
a boolean

skipDecode

protected boolean skipDecode(javax.faces.context.FacesContext context)
Overrides:
skipDecode in class org.apache.myfaces.trinidad.render.CoreRenderer

canSkipRendering

protected boolean canSkipRendering(org.apache.myfaces.trinidad.context.RenderingContext rc,
                                   java.lang.String clientId)
Returns true if the component can skip its own rendering; true if PPR is on for this request, is not currently active, and this component not a target. Note that if the component is not a leaf, then you'd still have to render the children.

Call this overload if you have the clientId already.


canSkipRendering

protected boolean canSkipRendering(javax.faces.context.FacesContext context,
                                   org.apache.myfaces.trinidad.context.RenderingContext rc,
                                   javax.faces.component.UIComponent component)
Returns true if the component can skip its own rendering; true if PPR is on for this request, is not currently active, and this component not a target. Note that if the component is not a leaf, then you'd still have to render the children.

Call this overload if you don't have the clientId already.


shouldRenderId

protected boolean shouldRenderId(javax.faces.context.FacesContext context,
                                 javax.faces.component.UIComponent component)
Returns true if the component should render an ID. Components that deliver events should always return "true".

Overrides:
shouldRenderId in class org.apache.myfaces.trinidad.render.CoreRenderer

renderAllAttributes

protected void renderAllAttributes(javax.faces.context.FacesContext context,
                                   org.apache.myfaces.trinidad.context.RenderingContext rc,
                                   javax.faces.component.UIComponent component,
                                   org.apache.myfaces.trinidad.bean.FacesBean bean)
                            throws java.io.IOException
Render the main renderer-specific attributes: "title", "class", "style", and all the Javascript attributes. This will render style attributes.

Throws:
java.io.IOException

renderAllAttributes

protected void renderAllAttributes(javax.faces.context.FacesContext context,
                                   org.apache.myfaces.trinidad.context.RenderingContext rc,
                                   javax.faces.component.UIComponent component,
                                   org.apache.myfaces.trinidad.bean.FacesBean bean,
                                   boolean renderStyleAttrs)
                            throws java.io.IOException
Render the main renderer-specific attributes: "title", "class", "style", and all the Javascript attributes. Takes a boolean to determine if renderStyleAttributes should be called, which renders "class", "style"

Throws:
java.io.IOException

renderInlineStyleAttribute

public static void renderInlineStyleAttribute(javax.faces.context.FacesContext context,
                                              org.apache.myfaces.trinidad.context.RenderingContext rc,
                                              javax.faces.component.UIComponent component,
                                              java.lang.String style)
                                       throws java.io.IOException
Renders the inline style attribute for the specified node

Throws:
java.io.IOException

renderInlineStyle

protected void renderInlineStyle(javax.faces.context.FacesContext context,
                                 org.apache.myfaces.trinidad.context.RenderingContext rc,
                                 javax.faces.component.UIComponent component,
                                 org.apache.myfaces.trinidad.bean.FacesBean bean)
                          throws java.io.IOException
Throws:
java.io.IOException

renderShortDescAttribute

protected void renderShortDescAttribute(javax.faces.context.FacesContext context,
                                        org.apache.myfaces.trinidad.context.RenderingContext rc,
                                        javax.faces.component.UIComponent component,
                                        org.apache.myfaces.trinidad.bean.FacesBean bean)
                                 throws java.io.IOException
Throws:
java.io.IOException

renderStyleAttributes

protected void renderStyleAttributes(javax.faces.context.FacesContext context,
                                     org.apache.myfaces.trinidad.context.RenderingContext rc,
                                     javax.faces.component.UIComponent component,
                                     org.apache.myfaces.trinidad.bean.FacesBean bean)
                              throws java.io.IOException
Throws:
java.io.IOException

getDefaultStyleClass

protected java.lang.String getDefaultStyleClass(javax.faces.component.UIComponent component,
                                                org.apache.myfaces.trinidad.bean.FacesBean bean)

renderStyleAttributes

protected void renderStyleAttributes(javax.faces.context.FacesContext context,
                                     org.apache.myfaces.trinidad.context.RenderingContext rc,
                                     javax.faces.component.UIComponent component,
                                     org.apache.myfaces.trinidad.bean.FacesBean bean,
                                     java.lang.String defaultStyleClass)
                              throws java.io.IOException
When there's a default style class pass it in to this method

Throws:
java.io.IOException

renderEventHandlers

protected void renderEventHandlers(javax.faces.context.FacesContext context,
                                   javax.faces.component.UIComponent component,
                                   org.apache.myfaces.trinidad.bean.FacesBean bean)
                            throws java.io.IOException
Render all the Javascript attributes.

Throws:
java.io.IOException

renderHAlign

protected static void renderHAlign(javax.faces.context.FacesContext context,
                                   org.apache.myfaces.trinidad.context.RenderingContext rc,
                                   java.lang.Object hAlign)
                            throws java.io.IOException
Throws:
java.io.IOException

renderPossiblyFormattedText

protected final void renderPossiblyFormattedText(javax.faces.context.FacesContext context,
                                                 java.lang.Object textValue)
                                          throws java.io.IOException
Throws:
java.io.IOException

renderFormattedText

protected final void renderFormattedText(javax.faces.context.FacesContext context,
                                         java.lang.Object textValue)
                                  throws java.io.IOException
Throws:
java.io.IOException

getAbsoluteImageUri

public static java.lang.String getAbsoluteImageUri(javax.faces.context.FacesContext context,
                                                   org.apache.myfaces.trinidad.context.RenderingContext rc,
                                                   java.lang.String imagePath)

getBaseImageUri

protected static java.lang.String getBaseImageUri(javax.faces.context.FacesContext context,
                                                  org.apache.myfaces.trinidad.context.RenderingContext rc)

renderDecorativeIcon

protected final void renderDecorativeIcon(javax.faces.context.FacesContext context,
                                          org.apache.myfaces.trinidad.context.RenderingContext rc,
                                          java.lang.String iconUri,
                                          java.lang.Object width,
                                          java.lang.Object height,
                                          java.lang.Object id,
                                          java.lang.Object altText)
                                   throws java.io.IOException
Renders an icon. If the the specified iconUri is a relative URI, it is appended to the value of the base Image URI. This method may only be called for decorative icons - icons that are purely visual.

Throws:
java.io.IOException

renderDecorativeIcon

protected final void renderDecorativeIcon(javax.faces.context.FacesContext context,
                                          org.apache.myfaces.trinidad.context.RenderingContext rc,
                                          java.lang.String iconUri,
                                          java.lang.Object width,
                                          java.lang.Object height,
                                          java.lang.Object id,
                                          java.lang.Object altText,
                                          javax.faces.component.UIComponent comp)
                                   throws java.io.IOException
Throws:
java.io.IOException

renderVerticalSpacer

protected final void renderVerticalSpacer(javax.faces.context.FacesContext context,
                                          java.lang.Object height,
                                          java.lang.Object id,
                                          javax.faces.component.UIComponent comp)
                                   throws java.io.IOException
Renders a vertical spacer for a specified non-null height.

Throws:
java.io.IOException

renderSpacer

protected final void renderSpacer(javax.faces.context.FacesContext context,
                                  org.apache.myfaces.trinidad.context.RenderingContext rc,
                                  java.lang.String width,
                                  java.lang.String height)
                           throws java.io.IOException
Renders a spacer.

Throws:
java.io.IOException

renderTransparent

protected final void renderTransparent(javax.faces.context.FacesContext context,
                                       org.apache.myfaces.trinidad.context.RenderingContext rc,
                                       java.lang.String width,
                                       java.lang.String height,
                                       boolean needsQuoting,
                                       java.lang.Object id)
                                throws java.io.IOException
Renders a transparent gif using a script to save space.

Throws:
java.io.IOException

resolveProperty

protected java.lang.Object resolveProperty(org.apache.myfaces.trinidad.bean.FacesBean bean,
                                           org.apache.myfaces.trinidad.bean.PropertyKey key)
This method evaluates the property of the specified bean if it supports the specified property key and if the current value is null, then evaluate the default value.

If the bean does not support the specified key, this method returns null. Unsupported keys occur when the bean's type its type returned null from findKey when findTypeConstants method was called.

Parameters:
bean - the property value holder.
key - the key associated to the property to evaluate.
Returns:
null if key is null, the current property value in the bean for the specified key if it was set, or the default value if it wasn't.
See Also:
findTypeConstants(org.apache.myfaces.trinidad.bean.FacesBean.Type)

resolveProperty

protected java.lang.Object resolveProperty(org.apache.myfaces.trinidad.bean.FacesBean bean,
                                           org.apache.myfaces.trinidad.bean.PropertyKey key,
                                           boolean checkDefault)
This method evaluates the property of the specified bean if it supports the specified property key and if the current value is null, then evaluate the default value if and only if checkDefault is true.

If the bean does not support the specified key, this method returns null. Unsupported keys occur when the bean's type its type returned null from findKey when findTypeConstants method was called.

Parameters:
bean - the property value holder.
key - the key associated to the property to evaluate.
checkDefault - a flag to tell the method to look for the default value if no value was explicitely set.
Returns:
null if key is null, the current property value in the bean for the specified key if it was set, or the default value if it wasn't and checkDefault is true.

renderScriptDeferAttribute

public static void renderScriptDeferAttribute(javax.faces.context.FacesContext context,
                                              org.apache.myfaces.trinidad.context.RenderingContext rc)
                                       throws java.io.IOException
Renders the "defer" attribute for a script element. In order to support partial page rendering, scripts must be rendered using the "defer" attribute to ensure that they are executed in the appropriate context. However, some browsers (eg. IE) do not reliably load scripts which are deferred. This method detects whether the target agent can handle the defer attribute correctly and only renders this attribute when as appropriate.

Note: ResponseWriter.startElement("script", null) must be called before calling this method.

Throws:
java.io.IOException

renderScriptTypeAttribute

public static void renderScriptTypeAttribute(javax.faces.context.FacesContext context,
                                             org.apache.myfaces.trinidad.context.RenderingContext rc)
                                      throws java.io.IOException
Checks whether in inaccessible mode, and if not, renders "type" attribute for a script element.

Note: ResponseWriter.startElement("script", null) must be called before calling this method.

Throws:
java.io.IOException

renderSubmitButtonNonJSBrowser

public static void renderSubmitButtonNonJSBrowser(javax.faces.context.FacesContext context,
                                                  org.apache.myfaces.trinidad.context.RenderingContext rc,
                                                  java.lang.String valueAttri,
                                                  java.lang.String nameAttri)
                                           throws java.io.IOException
This method renders an input element of type "submit". The input element's name attribute is encoded with parameter name and value pairs. Thus, it would enable Non-JavaScript browsers to include the element's name in their payLoad, if the element submits the page.

Parameters:
context - a FacesContext
rc - a RenderingContext
valueAttri - a String it is the value attribute of the submit button
nameAttri - a String it is the name attribute of the submit button
Throws:
java.io.IOException

getShortDesc

protected java.lang.String getShortDesc(javax.faces.component.UIComponent component,
                                        org.apache.myfaces.trinidad.bean.FacesBean bean)

getStyleClass

protected java.lang.String getStyleClass(javax.faces.component.UIComponent component,
                                         org.apache.myfaces.trinidad.bean.FacesBean bean)

getInlineStyle

protected java.lang.String getInlineStyle(javax.faces.component.UIComponent component,
                                          org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnclick

protected java.lang.String getOnclick(javax.faces.component.UIComponent component,
                                      org.apache.myfaces.trinidad.bean.FacesBean bean)

getOndblclick

protected java.lang.String getOndblclick(javax.faces.component.UIComponent component,
                                         org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnkeydown

protected java.lang.String getOnkeydown(javax.faces.component.UIComponent component,
                                        org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnkeyup

protected java.lang.String getOnkeyup(javax.faces.component.UIComponent component,
                                      org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnkeypress

protected java.lang.String getOnkeypress(javax.faces.component.UIComponent component,
                                         org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnmousedown

protected java.lang.String getOnmousedown(javax.faces.component.UIComponent component,
                                          org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnmousemove

protected java.lang.String getOnmousemove(javax.faces.component.UIComponent component,
                                          org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnmouseout

protected java.lang.String getOnmouseout(javax.faces.component.UIComponent component,
                                         org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnmouseover

protected java.lang.String getOnmouseover(javax.faces.component.UIComponent component,
                                          org.apache.myfaces.trinidad.bean.FacesBean bean)

getOnmouseup

protected java.lang.String getOnmouseup(javax.faces.component.UIComponent component,
                                        org.apache.myfaces.trinidad.bean.FacesBean bean)

getPartialTriggers

protected java.lang.String[] getPartialTriggers(javax.faces.component.UIComponent component,
                                                org.apache.myfaces.trinidad.bean.FacesBean bean)

supportsOnClickOnImgInput

public static boolean supportsOnClickOnImgInput(org.apache.myfaces.trinidad.context.RenderingContext rc)
Returns true if the agent supports the "onclick" JS Handler in an "input" HTML element of type "image"



Copyright © 2001-2011 The Apache Software Foundation. All Rights Reserved.