|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.faces.component.UIComponent
javax.faces.component.UIComponentBase
javax.faces.component.UIOutput
javax.faces.component.UIInput
org.apache.myfaces.trinidaddemo.composite.CompositeTest.ForceRendererType
public static class CompositeTest.ForceRendererType
Turns out there's no easy way to simply replace the renderer for a control like UIInput; UIComponentTag will call setRendererType() after consulting the "binding" attribute, overriding anything done in either the getter or setter. So, here's a subclass that forces the renderer type to a constant. The alternative is writing a custom JSP tag to do the same, but then you have to re-invent the wheel as far as the input tag goes.
| Field Summary |
|---|
| Fields inherited from class javax.faces.component.UIInput |
|---|
COMPONENT_FAMILY, COMPONENT_TYPE, CONVERSION_MESSAGE_ID, REQUIRED_MESSAGE_ID |
| Constructor Summary | |
|---|---|
CompositeTest.ForceRendererType()
|
|
| Method Summary | |
|---|---|
String |
getRendererType()
|
| Methods inherited from class javax.faces.component.UIInput |
|---|
addValidator, addValueChangeListener, broadcast, compareValues, decode, getConvertedValue, getFamily, getSubmittedValue, getValidator, getValidators, getValue, getValueChangeListener, getValueChangeListeners, isImmediate, isLocalValueSet, isRequired, isValid, processDecodes, processUpdates, processValidators, removeValidator, removeValueChangeListener, restoreState, saveState, setImmediate, setLocalValueSet, setRequired, setSubmittedValue, setValid, setValidator, setValue, setValueChangeListener, updateModel, validate, validateValue |
| Methods inherited from class javax.faces.component.UIOutput |
|---|
getConverter, getLocalValue, setConverter |
| Methods inherited from class javax.faces.component.UIComponentBase |
|---|
addFacesListener, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getClientId, getFacesContext, getFacesListeners, getFacet, getFacets, getFacetsAndChildren, getId, getParent, getRenderer, getRendersChildren, getValueBinding, isRendered, isTransient, processRestoreState, processSaveState, queueEvent, removeFacesListener, restoreAttachedState, saveAttachedState, setId, setParent, setRendered, setRendererType, setTransient, setValueBinding |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.faces.component.ValueHolder |
|---|
getConverter, getLocalValue, setConverter |
| Constructor Detail |
|---|
public CompositeTest.ForceRendererType()
| Method Detail |
|---|
public String getRendererType()
getRendererType in class javax.faces.component.UIComponentBase
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||