Package de.cuioss.test.jsf.mocks
Class CuiMockRenderer
- java.lang.Object
-
- javax.faces.render.Renderer
-
- de.cuioss.test.jsf.mocks.CuiMockRenderer
-
public class CuiMockRenderer extends Renderer
Simple Mock renderer that is capable of rendering any element by using the simple-name of the given component. In addition it is capable of rendering the 'id'-attribute as 'id' and 'name' in case the component is of typeUIInputor the attributeUIComponent.getId()is set, the 'styleClass' and 'style' attributes and reacts to the 'rendered'-attribute. It can be configured to use a certain tagname to be rendered by usingCuiMockRenderer(String). Otherwise the simple-name of the component will be used.- Author:
- Oliver Wolff
-
-
Field Summary
-
Fields inherited from class javax.faces.render.Renderer
PASSTHROUGH_RENDERER_LOCALNAME_KEY
-
-
Constructor Summary
Constructors Constructor Description CuiMockRenderer()Default constructor resulting in the actual component to be used as tagname.CuiMockRenderer(String tagName)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidencodeBegin(FacesContext context, UIComponent component)voidencodeEnd(FacesContext context, UIComponent component)-
Methods inherited from class javax.faces.render.Renderer
convertClientId, decode, encodeChildren, getConvertedValue, getRendersChildren
-
-
-
-
Constructor Detail
-
CuiMockRenderer
public CuiMockRenderer()
Default constructor resulting in the actual component to be used as tagname.
-
CuiMockRenderer
public CuiMockRenderer(String tagName)
-
-
Method Detail
-
encodeBegin
public void encodeBegin(FacesContext context, UIComponent component) throws IOException
- Overrides:
encodeBeginin classRenderer- Throws:
IOException
-
encodeEnd
public void encodeEnd(FacesContext context, UIComponent component) throws IOException
- Overrides:
encodeEndin classRenderer- Throws:
IOException
-
-