[jsr-314-open-mirror] [jsr-314-open] Fwd: Fix UIData state saving model

Leonardo Uribe lu4242 at gmail.com
Mon Sep 20 21:12:34 EDT 2010


Hi Martin

I have been thinking a lot about it and for this one just add two simple
methods on UIComponent could do the job:

    public Object getTransient(Serializable key)
    {
        TransientStateHelper helper = getTransientStateHelper(false);
        if (helper != null)
        {
            return helper.get(key);
        }
        return null;
    }

    public Object putTransient(Serializable key, Object value)
    {
        return getTransientStateHelper().put(key, value);
    }


Just like TransientStateHelper.

In theory, these methods will be used by the vdl or renderers, so this two
simple methods will handle these cases correctly.

>From my point of view, these methods in some way looks similar to the ones
used for handle ValueBinding / ValueExpression on UIComponent.

best regards,

Leonardo Uribe

2010/9/16 Martin Marinschek <mmarinschek at apache.org>

> Hi Leo,
>
> > I was thinking if the interface provided for handle transient properties
> > should be exposed in some
> > way, adding some methods (getter/setter) on UIComponent, to make possible
> > manipulate them from "outside"
> > the component instance. It will be very useful, specially for UIViewRoot.
>
> +1!
>
> what would be your proposed API?
>
> best regards,
>
> Martin
>
>
> --
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jsr-314-open-mirror/attachments/20100920/4b14228c/attachment-0002.html 


More information about the jsr-314-open-mirror mailing list