Hi,

the sequense is as following:

in RenderResponsePhase:
 try to get a component via binding.
 If not found, create one and set it via binding.
in resoreViewPhase:
 set the recreated instance via binding.


I havend had time to try your problem, maybe this afternoon.
Are you using jsp or faclets? I never used faclets, and don't know how
the tx tags are created there, in jsp this should work.

Regards,
 Volker


2007/4/11, David Steinkopff <[EMAIL PROTECTED]>:
is the init sequence by jsf so that the application frist set
component bindings? really interesting, in that case thanks for the
hint.

2007/4/10, Kito D. Mann <[EMAIL PROTECTED]>:
> > From: David Steinkopff [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, April 10, 2007 10:06 AM
> > To: MyFaces Discussion
> > Subject: Re: [ Tobago ] problem with component binding
> >
> > I construct a UIInput object
> >
> > textfield = new UIInput();
> > textfield.setValue("hello UIInput");
> > textfield.setId("textfield");
> >
> > getter and setter
> >
> > public UIInput getTextfield() {
> >     return textfield;
> > }
> > public void setTextfield(UIInput textfield) {
> >     this.textfield = textfield;
> > }
> >
>
> This is probably unrelated to your problem, but in general you should avoid
> creating a component via new. You should either use
> Application.createComponent or simply initialize the component in your
> setter:
>
>  public void setTextfield(UIInput textfield) {
>    this.textfield = textfield;
>    textfield.setValue("hello UIInput");
>    textfield.setId("textfield");
>  }
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Kito D. Mann ([EMAIL PROTECTED])
> Author, JavaServer Faces in Action
> http://www.virtua.com - JSF/Java EE consulting, training, and mentoring
> http://www.JSFCentral.com - JavaServer Faces FAQ, news, and info
>
>

Reply via email to