javax.faces.render
Class RenderKitWrapper

java.lang.Object
  extended by javax.faces.render.RenderKit
      extended by javax.faces.render.RenderKitWrapper
All Implemented Interfaces:
FacesWrapper<RenderKit>

public abstract class RenderKitWrapper
extends RenderKit
implements FacesWrapper<RenderKit>

Provides a simple implementation of RenderKit that can be subclassed by developers wishing to provide specialized behavior to an existing RenderKit instance. The default implementation of all methods is to call through to the wrapped RenderKit.

Usage: extend this class and override getWrapped() to return the instance we are wrapping.

Since:
2.0

Constructor Summary
RenderKitWrapper()
           
 
Method Summary
 void addClientBehaviorRenderer(java.lang.String type, ClientBehaviorRenderer renderer)
          The default behavior of this method is to call RenderKit#addClientBehaviorRenderer(String, ClientBehaviorRenderer) on the wrapped RenderKit object.
 void addRenderer(java.lang.String family, java.lang.String rendererType, Renderer renderer)
          The default behavior of this method is to call RenderKit#addRenderer(String, String, Renderer) on the wrapped RenderKit object.
 ResponseStream createResponseStream(java.io.OutputStream out)
          The default behavior of this method is to call RenderKit#createResponseStream(java.io.OutputStream) on the wrapped RenderKit object.
 ResponseWriter createResponseWriter(java.io.Writer writer, java.lang.String contentTypeList, java.lang.String characterEncoding)
          The default behavior of this method is to call RenderKit#createResponseWriter(java.io.Writer, String, String) on the wrapped RenderKit object.
 ClientBehaviorRenderer getClientBehaviorRenderer(java.lang.String type)
          The default behavior of this method is to call RenderKit#getClientBehaviorRenderer(String) on the wrapped RenderKit object.
 java.util.Iterator<java.lang.String> getClientBehaviorRendererTypes()
          The default behavior of this method is to call RenderKit.getClientBehaviorRendererTypes() on the wrapped RenderKit object.
 java.util.Iterator<java.lang.String> getComponentFamilies()
          The default behavior of this method is to call RenderKit.getComponentFamilies() on the wrapped RenderKit object.
 Renderer getRenderer(java.lang.String family, java.lang.String rendererType)
          The default behavior of this method is to call RenderKit#getRenderer(String, String) on the wrapped RenderKit object.
 java.util.Iterator<java.lang.String> getRendererTypes(java.lang.String componentFamily)
          The default behavior of this method is to call RenderKit#getRendererTypes(String) on the wrapped RenderKit object.
 ResponseStateManager getResponseStateManager()
          The default behavior of this method is to call RenderKit.getResponseStateManager() on the wrapped RenderKit object.
abstract  RenderKit getWrapped()
          

A class that implements this interface uses this method to return an instance of the class being wrapped.

 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RenderKitWrapper

public RenderKitWrapper()
Method Detail

getWrapped

public abstract RenderKit getWrapped()
Description copied from interface: FacesWrapper

A class that implements this interface uses this method to return an instance of the class being wrapped.

Specified by:
getWrapped in interface FacesWrapper<RenderKit>
Returns:
the wrapped RenderKit instance
See Also:
FacesWrapper.getWrapped()

addRenderer

public void addRenderer(java.lang.String family,
                        java.lang.String rendererType,
                        Renderer renderer)

The default behavior of this method is to call RenderKit#addRenderer(String, String, Renderer) on the wrapped RenderKit object.

Specified by:
addRenderer in class RenderKit
Parameters:
family - Component family of the Renderer to register
rendererType - Renderer type of the Renderer to register
renderer - Renderer instance we are registering
See Also:
RenderKit#addRenderer(String, String, Renderer)

createResponseStream

public ResponseStream createResponseStream(java.io.OutputStream out)

The default behavior of this method is to call RenderKit#createResponseStream(java.io.OutputStream) on the wrapped RenderKit object.

Specified by:
createResponseStream in class RenderKit
See Also:
RenderKit#createResponseStream(java.io.OutputStream)

createResponseWriter

public ResponseWriter createResponseWriter(java.io.Writer writer,
                                           java.lang.String contentTypeList,
                                           java.lang.String characterEncoding)

The default behavior of this method is to call RenderKit#createResponseWriter(java.io.Writer, String, String) on the wrapped RenderKit object.

Specified by:
createResponseWriter in class RenderKit
Parameters:
writer - the Writer around which this ResponseWriter must be built.
contentTypeList - an "Accept header style" list of content types for this response, or null if the RenderKit should choose the best fit. As of the current version, the values accepted by the Standard render-kit for this parameter include any valid "Accept header style" String that includes the String text/html, application/xhtml+xml, application/xml or text/xml. This may change in a future version. The RenderKit must support a value for this argument that comes straight from the Accept HTTP header, and therefore requires parsing according to the specification of the Accept header. Please see Section 14.1 of RFC 2616 for the specification of the Accept header.
characterEncoding - such as "ISO-8859-1" for this ResponseWriter, or null if the RenderKit should choose the best fit. Please see the IANA for a list of character encodings.
Returns:
a new ResponseWriter.
See Also:
RenderKit#createResponseWriter(java.io.Writer, String, String)

getRenderer

public Renderer getRenderer(java.lang.String family,
                            java.lang.String rendererType)

The default behavior of this method is to call RenderKit#getRenderer(String, String) on the wrapped RenderKit object.

Specified by:
getRenderer in class RenderKit
Parameters:
family - Component family of the requested Renderer instance
rendererType - Renderer type of the requested Renderer instance
See Also:
RenderKit#getRenderer(String, String)

getResponseStateManager

public ResponseStateManager getResponseStateManager()

The default behavior of this method is to call RenderKit.getResponseStateManager() on the wrapped RenderKit object.

Specified by:
getResponseStateManager in class RenderKit
See Also:
RenderKit.getResponseStateManager()

getComponentFamilies

public java.util.Iterator<java.lang.String> getComponentFamilies()

The default behavior of this method is to call RenderKit.getComponentFamilies() on the wrapped RenderKit object.

Overrides:
getComponentFamilies in class RenderKit
See Also:
RenderKit.getComponentFamilies()

getRendererTypes

public java.util.Iterator<java.lang.String> getRendererTypes(java.lang.String componentFamily)

The default behavior of this method is to call RenderKit#getRendererTypes(String) on the wrapped RenderKit object.

Overrides:
getRendererTypes in class RenderKit
Parameters:
componentFamily - one of the members of the Iterator returned by RenderKit.getComponentFamilies().
See Also:
RenderKit#getRendererTypes(String)

addClientBehaviorRenderer

public void addClientBehaviorRenderer(java.lang.String type,
                                      ClientBehaviorRenderer renderer)

The default behavior of this method is to call RenderKit#addClientBehaviorRenderer(String, ClientBehaviorRenderer) on the wrapped RenderKit object.

Overrides:
addClientBehaviorRenderer in class RenderKit
Parameters:
type - type of the ClientBehaviorRenderer to register
renderer - ClientBehaviorRenderer instance we are registering
See Also:
RenderKit#addClientBehaviorRenderer(String, ClientBehaviorRenderer)

getClientBehaviorRenderer

public ClientBehaviorRenderer getClientBehaviorRenderer(java.lang.String type)

The default behavior of this method is to call RenderKit#getClientBehaviorRenderer(String) on the wrapped RenderKit object.

Overrides:
getClientBehaviorRenderer in class RenderKit
Parameters:
type - type of the requested ClientBehaviorRenderer instance
See Also:
RenderKit#getClientBehaviorRenderer(String)

getClientBehaviorRendererTypes

public java.util.Iterator<java.lang.String> getClientBehaviorRendererTypes()

The default behavior of this method is to call RenderKit.getClientBehaviorRendererTypes() on the wrapped RenderKit object.

Overrides:
getClientBehaviorRendererTypes in class RenderKit
See Also:
RenderKit.getClientBehaviorRendererTypes()


Submit a bug or feature

Copyright © 2009-2011, Oracle Corporation and/or its affiliates. All Rights Reserved. Use is subject to license terms.

Generated on 10-February-2011 12:41