Reverse attribute mapping..

Ian Young ian at iay.org.uk
Sat Aug 10 07:49:39 EDT 2013


On 6 Aug 2013, at 20:50, Tom Zeller <tzeller at dragonacea.biz> wrote:

> I think that the bean name (the "id" attribute) and the "id" property
> should have the same value, or am I missing something ?

That turns out to be the case in a lot of the Spring stuff I've done with the MDA, for example.

It's also the case where I find mixing p:-notation with properties not only acceptable but helpful:

    <bean id="se_swamid_edugainEntities" parent="CompositeStage"
        p:id="se_swamid_edugainEntities">
        <property name="composedStages">
            <list>
                ...
            </list>
        </property>
    </bean>

This is mainly because of the complete coincidence that you can line up the id and p:id values if you have 4-space indentation.  This is a big help if you're copy-and-pasting like mad because it reminds you to update both values.

In general, though, I find it is pretty confusing to mix the two notations within a single bean.  I haven't really thought about it at the file level.

	-- Ian



-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4813 bytes
Desc: not available
Url : http://shibboleth.net/pipermail/dev/attachments/20130810/30b656a9/attachment.bin 


More information about the dev mailing list