Hi All,

I wanted to decorate the default converter that comes along with 
HtmlCalendarRenderer class for <t:inputCalendar> component.

I was able to actual processing of converting string to Object to the 
HtmlCalendarRenderer class using the following code:

Method: getAsObject()
UIInput inputComponent = (UIInput)component;
inputComponent.setConverter(null);
String rendererType = inputComponent.getRendererType();
Renderer renderer = 
facesContext.getRenderKit().getRenderer(inputComponent.getFamily(), 
rendererType);
Object convertedValue = renderer.getConvertedValue(facesContext, component, 
value);

The converter in question is a generic converter and applies to any UIInput 
component. The problem is with getAsString method. The component nor its 
renderer does not expose any method through which I can delegate the conversion 
to String to the actual getAsString class. What I was looking for was access to 
the default converter for any component if none have been specified, but did 
not find a way to get hold of it.

Is there any way around if I need to have a generic converter for all UIInput 
type components to act as a decorator?

Thanks,
Madhav


**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely 
for the use of the addressee(s). If you are not the intended recipient, please 
notify the sender by e-mail and delete the original message. Further, you are 
not 
to copy, disclose, or distribute this e-mail or its contents to any other 
person and 
any such actions are unlawful. This e-mail may contain viruses. Infosys has 
taken 
every reasonable precaution to minimize this risk, but is not liable for any 
damage 
you may sustain as a result of any virus in this e-mail. You should carry out 
your 
own virus checks before opening the e-mail or attachment. Infosys reserves the 
right to monitor and review the content of all messages sent to or from this 
e-mail 
address. Messages sent to or from this e-mail address may be stored on the 
Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***

Reply via email to