org.apache.myfaces.custom.date
Class HtmlDateRenderer

java.lang.Object
  extended by javax.faces.render.Renderer
      extended by org.apache.myfaces.shared_tomahawk.renderkit.html.HtmlRenderer
          extended by org.apache.myfaces.custom.date.HtmlDateRenderer
All Implemented Interfaces:
EventListener, javax.faces.event.ComponentSystemEventListener, javax.faces.event.FacesListener

public class HtmlDateRenderer
extends org.apache.myfaces.shared_tomahawk.renderkit.html.HtmlRenderer
implements javax.faces.event.ComponentSystemEventListener

Version:
$Revision: 745285 $ $Date: 2009-02-17 17:52:58 -0500 (mar, 17 feb 2009) $
Author:
Sylvain Vieujot (latest modification by $Author: lu4242 $)

Field Summary
static String DATE_MESSAGE_ID
          The message identifier of the FacesMessage to be created if the input is not a valid date.
 
Constructor Summary
HtmlDateRenderer()
           
 
Method Summary
 void decode(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent)
           
protected  void encodeAmpmChoice(DateFormatSymbols symbols, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, int calendar_ampm, int selected)
           
protected  void encodeEmptyInputMonthSelection(javax.faces.component.UIComponent component, javax.faces.context.ResponseWriter writer, int selectedMonth)
           
protected  void encodeEmtypAmpmChoice(javax.faces.component.UIComponent component, javax.faces.context.ResponseWriter writer, int selectedAmpm)
           
 void encodeEnd(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent)
           
protected  void encodeInputAmpm(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String clientId, org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData, boolean disabled, boolean readonly, Locale currentLocale)
           
protected  void encodeInputDay(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String clientId, org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData, boolean disabled, boolean readonly)
           
protected  void encodeInputField(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String id, String value, int size, boolean disabled, boolean readonly)
           
protected  void encodeInputHours(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String clientId, org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData, boolean disabled, boolean readonly)
           
protected  void encodeInputMinutes(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String clientId, org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData, boolean disabled, boolean readonly)
           
protected  void encodeInputMonth(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String clientId, org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData, Locale currentLocale, boolean disabled, boolean readonly)
           
protected  void encodeInputSeconds(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String clientId, org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData, boolean disabled, boolean readonly)
           
protected  void encodeInputYear(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String clientId, org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData, boolean disabled, boolean readonly)
           
protected  void encodePopupCalendarButton(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, javax.faces.context.ResponseWriter writer, String clientId, Locale currentLocale)
           
static String getClientIdForDaySubcomponent(String clientId)
           
 Object getConvertedValue(javax.faces.context.FacesContext context, javax.faces.component.UIComponent uiComponent, Object submittedValue)
           
protected  boolean isDisabled(javax.faces.context.FacesContext facesContext, org.apache.myfaces.custom.date.HtmlInputDate inputDate)
           
 void processEvent(javax.faces.event.ComponentSystemEvent event)
           
 
Methods inherited from class org.apache.myfaces.shared_tomahawk.renderkit.html.HtmlRenderer
getActionUrl, getChildCount, getChildren, getClientId, isCommonEventsOptimizationEnabled, isCommonPropertiesOptimizationEnabled, renderId, shouldRenderId, toUri
 
Methods inherited from class javax.faces.render.Renderer
convertClientId, encodeBegin, encodeChildren, getRendersChildren
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DATE_MESSAGE_ID

public static final String DATE_MESSAGE_ID

The message identifier of the FacesMessage to be created if the input is not a valid date.

See Also:
Constant Field Values
Constructor Detail

HtmlDateRenderer

public HtmlDateRenderer()
Method Detail

getClientIdForDaySubcomponent

public static String getClientIdForDaySubcomponent(String clientId)

processEvent

public void processEvent(javax.faces.event.ComponentSystemEvent event)
Specified by:
processEvent in interface javax.faces.event.ComponentSystemEventListener

isDisabled

protected boolean isDisabled(javax.faces.context.FacesContext facesContext,
                             org.apache.myfaces.custom.date.HtmlInputDate inputDate)

encodeEnd

public void encodeEnd(javax.faces.context.FacesContext facesContext,
                      javax.faces.component.UIComponent uiComponent)
               throws IOException
Overrides:
encodeEnd in class javax.faces.render.Renderer
Throws:
IOException

encodeInputField

protected void encodeInputField(javax.faces.context.FacesContext facesContext,
                                javax.faces.component.UIComponent uiComponent,
                                javax.faces.context.ResponseWriter writer,
                                String id,
                                String value,
                                int size,
                                boolean disabled,
                                boolean readonly)
                         throws IOException
Throws:
IOException

encodeInputDay

protected void encodeInputDay(javax.faces.context.FacesContext facesContext,
                              javax.faces.component.UIComponent uiComponent,
                              javax.faces.context.ResponseWriter writer,
                              String clientId,
                              org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData,
                              boolean disabled,
                              boolean readonly)
                       throws IOException
Throws:
IOException

encodeInputMonth

protected void encodeInputMonth(javax.faces.context.FacesContext facesContext,
                                javax.faces.component.UIComponent uiComponent,
                                javax.faces.context.ResponseWriter writer,
                                String clientId,
                                org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData,
                                Locale currentLocale,
                                boolean disabled,
                                boolean readonly)
                         throws IOException
Throws:
IOException

encodeEmptyInputMonthSelection

protected void encodeEmptyInputMonthSelection(javax.faces.component.UIComponent component,
                                              javax.faces.context.ResponseWriter writer,
                                              int selectedMonth)
                                       throws IOException
Throws:
IOException

encodeInputYear

protected void encodeInputYear(javax.faces.context.FacesContext facesContext,
                               javax.faces.component.UIComponent uiComponent,
                               javax.faces.context.ResponseWriter writer,
                               String clientId,
                               org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData,
                               boolean disabled,
                               boolean readonly)
                        throws IOException
Throws:
IOException

encodeInputHours

protected void encodeInputHours(javax.faces.context.FacesContext facesContext,
                                javax.faces.component.UIComponent uiComponent,
                                javax.faces.context.ResponseWriter writer,
                                String clientId,
                                org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData,
                                boolean disabled,
                                boolean readonly)
                         throws IOException
Throws:
IOException

encodeInputMinutes

protected void encodeInputMinutes(javax.faces.context.FacesContext facesContext,
                                  javax.faces.component.UIComponent uiComponent,
                                  javax.faces.context.ResponseWriter writer,
                                  String clientId,
                                  org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData,
                                  boolean disabled,
                                  boolean readonly)
                           throws IOException
Throws:
IOException

encodeInputSeconds

protected void encodeInputSeconds(javax.faces.context.FacesContext facesContext,
                                  javax.faces.component.UIComponent uiComponent,
                                  javax.faces.context.ResponseWriter writer,
                                  String clientId,
                                  org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData,
                                  boolean disabled,
                                  boolean readonly)
                           throws IOException
Throws:
IOException

encodeAmpmChoice

protected void encodeAmpmChoice(DateFormatSymbols symbols,
                                javax.faces.component.UIComponent uiComponent,
                                javax.faces.context.ResponseWriter writer,
                                int calendar_ampm,
                                int selected)
                         throws IOException
Throws:
IOException

encodeInputAmpm

protected void encodeInputAmpm(javax.faces.context.FacesContext facesContext,
                               javax.faces.component.UIComponent uiComponent,
                               javax.faces.context.ResponseWriter writer,
                               String clientId,
                               org.apache.myfaces.custom.date.AbstractHtmlInputDate.UserData userData,
                               boolean disabled,
                               boolean readonly,
                               Locale currentLocale)
                        throws IOException
Throws:
IOException

encodeEmtypAmpmChoice

protected void encodeEmtypAmpmChoice(javax.faces.component.UIComponent component,
                                     javax.faces.context.ResponseWriter writer,
                                     int selectedAmpm)
                              throws IOException
Throws:
IOException

encodePopupCalendarButton

protected void encodePopupCalendarButton(javax.faces.context.FacesContext facesContext,
                                         javax.faces.component.UIComponent uiComponent,
                                         javax.faces.context.ResponseWriter writer,
                                         String clientId,
                                         Locale currentLocale)
                                  throws IOException
Throws:
IOException

decode

public void decode(javax.faces.context.FacesContext facesContext,
                   javax.faces.component.UIComponent uiComponent)
Overrides:
decode in class javax.faces.render.Renderer

getConvertedValue

public Object getConvertedValue(javax.faces.context.FacesContext context,
                                javax.faces.component.UIComponent uiComponent,
                                Object submittedValue)
                         throws javax.faces.convert.ConverterException
Overrides:
getConvertedValue in class javax.faces.render.Renderer
Throws:
javax.faces.convert.ConverterException


Copyright © 2012 The Apache Software Foundation. All Rights Reserved.