org.richfaces.renderkit.html.images
Class ComboBoxArrowImage

java.lang.Object
  extended by org.ajax4jsf.resource.InternetResourceBase
      extended by org.ajax4jsf.resource.Java2Dresource
          extended by org.richfaces.renderkit.html.images.ComboBoxArrowImage
All Implemented Interfaces:
org.ajax4jsf.resource.InternetResource
Direct Known Subclasses:
ComboBoxArrowImageDisable

public class ComboBoxArrowImage
extends Java2Dresource

Since:
3.2.0 ComboBox down image renderer
Author:
Anton Belevich

Field Summary
protected static java.lang.String BACKGROUND_COLOR
           
protected static java.lang.String BORDER_COLOR
           
protected static java.lang.String DISABLED_BACKGROUND_COLOR
           
protected static java.lang.String DISABLED_BORDER_COLOR
           
protected static java.lang.String DISABLED_ICON_COLOR
           
protected static java.lang.String ICON_COLOR
           
 
Fields inherited from interface org.ajax4jsf.resource.InternetResource
CODEC_ATTR, DATA_SEPARATOR, DEFAULT_EXPIRE, DEFAULT_EXPITE_PARAMETER, ENCODE_PASS_PARAMETER, ENCODE_URI_PARAMETER, RESOURCE_PROTOCOL, RESOURCE_URI_PREFIX, RESOURCE_URI_PREFIX_LENGTH
 
Constructor Summary
ComboBoxArrowImage()
           
 
Method Summary
protected  java.lang.Object deserializeData(byte[] objectArray)
          Deserialize parameters object from byte array.
protected  java.lang.Object getDataToStore(javax.faces.context.FacesContext context, java.lang.Object data)
          Template method to construct resource-specific data ( to store in resource URI ).
 java.awt.Dimension getDimensions(javax.faces.context.FacesContext facesContext, java.lang.Object data)
          Primary calculation of image dimensions - used when HTML code is generated to render IMG's width and height Subclasses should override this method to provide correct sizes of rendered images
protected  java.awt.Dimension getDimensions(org.ajax4jsf.resource.ResourceContext resourceContext)
          Secondary calculation is used basically by getImage method
protected  void paint(org.ajax4jsf.resource.ResourceContext context, java.awt.Graphics2D g2d)
          Template method for create image as Applet-like paint.
protected  void paintBaseTriangle(java.awt.Graphics2D g2d)
           
protected  java.lang.Object storeData(javax.faces.context.FacesContext context, java.lang.String colorSkinParam, java.lang.String backgroundSkinParam, java.lang.String borderSkinParam)
           
 
Methods inherited from class org.ajax4jsf.resource.Java2Dresource
getImage, getResourceAsStream, send
 
Methods inherited from class org.ajax4jsf.resource.InternetResourceBase
encode, encode, encodeBegin, encodeEnd, getContentLength, getContentType, getExpired, getKey, getLastModified, getProperty, getRenderer, getUri, isCacheable, isSessionAware, requireFacesContext, restoreData, sendHeaders, setCacheable, setContentLength, setExpired, setKey, setLastModified, setProperty, setRenderer, setSessionAware
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ICON_COLOR

protected static final java.lang.String ICON_COLOR
See Also:
Constant Field Values

BACKGROUND_COLOR

protected static final java.lang.String BACKGROUND_COLOR
See Also:
Constant Field Values

BORDER_COLOR

protected static final java.lang.String BORDER_COLOR
See Also:
Constant Field Values

DISABLED_ICON_COLOR

protected static final java.lang.String DISABLED_ICON_COLOR
See Also:
Constant Field Values

DISABLED_BACKGROUND_COLOR

protected static final java.lang.String DISABLED_BACKGROUND_COLOR
See Also:
Constant Field Values

DISABLED_BORDER_COLOR

protected static final java.lang.String DISABLED_BORDER_COLOR
See Also:
Constant Field Values
Constructor Detail

ComboBoxArrowImage

public ComboBoxArrowImage()
Method Detail

getDimensions

protected java.awt.Dimension getDimensions(org.ajax4jsf.resource.ResourceContext resourceContext)
Description copied from class: Java2Dresource
Secondary calculation is used basically by getImage method

Overrides:
getDimensions in class Java2Dresource
Returns:

getDimensions

public java.awt.Dimension getDimensions(javax.faces.context.FacesContext facesContext,
                                        java.lang.Object data)
Description copied from class: Java2Dresource
Primary calculation of image dimensions - used when HTML code is generated to render IMG's width and height Subclasses should override this method to provide correct sizes of rendered images

Overrides:
getDimensions in class Java2Dresource
Returns:
dimensions of the image to be displayed on page

deserializeData

protected java.lang.Object deserializeData(byte[] objectArray)
Description copied from class: InternetResourceBase
Deserialize parameters object from byte array. By default, used Java de-serialisation from ObjectOutputStream , but implementations can override this method ( togewer with getDataToStore ) for implement short version.

Overrides:
deserializeData in class InternetResourceBase
Returns:

getDataToStore

protected java.lang.Object getDataToStore(javax.faces.context.FacesContext context,
                                          java.lang.Object data)
Description copied from class: InternetResourceBase
Template method to construct resource-specific data ( to store in resource URI ). If resource must store any data in session or other cache, it must be done here. Since lightweight realisation, information for restore such data muct be returned by this method.

Overrides:
getDataToStore in class InternetResourceBase
Parameters:
context - - current faces context.
data - - data for build information, usually current UIComponent
Returns:
- any Serializable object, or null.

storeData

protected java.lang.Object storeData(javax.faces.context.FacesContext context,
                                     java.lang.String colorSkinParam,
                                     java.lang.String backgroundSkinParam,
                                     java.lang.String borderSkinParam)

paint

protected void paint(org.ajax4jsf.resource.ResourceContext context,
                     java.awt.Graphics2D g2d)
Description copied from class: Java2Dresource
Template method for create image as Applet-like paint.

Overrides:
paint in class Java2Dresource
Parameters:
context - - current resource context.
g2d - - graphics to paint.

paintBaseTriangle

protected void paintBaseTriangle(java.awt.Graphics2D g2d)


Copyright © 2010. All Rights Reserved.