cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Carsten Ziegeler <cziege...@apache.org>
Subject Re: Spring bean names
Date Fri, 07 Dec 2007 18:08:58 GMT
Vadim Gritsenko wrote:
>>
>> It's not really a problem. You can't use "/" in id attributes. That
>> was the reason why <bean name=""/> was introduced because Spring
>> webflow needed a way to put URIs into bean ids.
> 
> But we are talking about name attribute? Is there a problem with it too?
> 
No, I don't think so - now I think I remember - I used the "id"
attribute at some point of time (therefore the dot) and later on I found
out about the name attribute.

> 
>>>> it doesn't matter as these components are
>>>> accessed through our spring configurator bean map and this bean map
>>>> checks for boths versions.
>>> Did not know this; I thought only '/' is allowed.
>>
>> The "/" is used if an Avalon selector is mimicked. If you access
>> Spring beans using the Spring Configurator's bean map, the name
>> doesn't matter because the selection is done based on the interface name.
> 
> So Carsten was wrong above? It does not rely on syntax but interface name?
> 
Both :) The map uses the interface to search for all beans of this
interface. Then the interface name is used as a prefix to find the
selector hint (key). So if a bean for interface "foo.Bar" is found and
has the bean name "foo.Bar.x" , the bean is registered with "x" in the
map. If the name is "foo.Bar/y", it's registered with "y" in the map.

Carsten

-- 
Carsten Ziegeler
cziegeler@apache.org

Mime
View raw message