dev@javaserverfaces.java.net

Re: [jsf 2.0] inconsistent javadoc between UIViewRoot.getComponentResources and UIViewRoot.addComponentResource

From: Matthias Wessendorf <matzew_at_apache.org>
Date: Fri, 15 May 2009 17:05:01 +0200

Hey Leo,

I guess you are asking for some myfaces stuff, right ?
Would be cool to do a CC to the dev_at_m.a.o list
(I guess the comments list is not visible)

Thanks,
Matthias

On Mon, May 4, 2009 at 4:48 PM, Ryan Lubke <Ryan.Lubke_at_sun.com> wrote:
> On 5/3/09 9:29 PM, Leonardo Uribe wrote:
> Hello Leonardo,
>
> Spec feedback is best sent to jsr-314-comments_at_jcp.org.
>
> I'll forward this on.
>>
>> Hi
>>
>> Checking the latest javadoc (jsf-spec-2.0-20090327) for jsf 2.0, there is
>> something wrong with the description of UIViewRoot.getComponentResources and
>> UIViewRoot.addComponentResource.
>>
>> The description on UIViewRoot.getComponentResources(FacesContext context,
>> String target)  says this:
>>
>> ".........Return an unmodifiable List of UIComponents for the provided
>> target agrument........"
>>
>> but the description of UIViewRoot.addComponentResource(FacesContext
>> context, UIComponent componentResource, String target) says this:
>>
>> "..... ...................
>> # Call getComponentResources(javax.faces.context.FacesContext,
>> java.lang.String) to obtain the child list for the given target.
>> # If the component ID of componentResource matches the the ID of a
>> resource that has allready been added, remove the old resource.
>> # Add the component resource to the list.
>> .............."
>>
>> The inconsistency is that if getComponentResources return an unmodifiable
>> List, you can't remove and add components to that list, but the remaining
>> javadoc comments suggests this. Obviously, the code don't do what javadoc
>> says.
>>
>> It is possible that someone correct the javadoc and publish the correct
>> behavior?.
>>
>> regards
>>
>> Leonardo Uribe
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_javaserverfaces.dev.java.net
> For additional commands, e-mail: dev-help_at_javaserverfaces.dev.java.net
>
>



-- 
Matthias Wessendorf
blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
twitter: http://twitter.com/mwessendorf