[jboss-dev-forums] [Design the new POJO MicroContainer] - Field signature usage

alesj do-not-reply at jboss.com
Mon Mar 17 07:36:09 EDT 2008


When doing annotation lookup on fields in AbstractBeanAnnotationAdapter there are two ways of doing that.

1) The same way as I'm doing it now via propertys
This is possible since fields are now 'propertys'.
But would require Signature abstraction on PropertyInfo.

2) Doing normal fields inspection
This would require a change to AnnotatedElementMetaDataLoader, since currently only public fields are supported.
Dealing with possible duplicates, e.g. existing only setter + FIELDS|ALL mode

The first one looks cleaner, and we should be 'fixing' the signature issue anyway for the instance annotations: http://www.jboss.org/index.html?module=bb&op=viewtopic&t=131947
But it a bit of magic, since I doubt users/devs will expect fields as part of propertys.

The second one is more natural, handling fields is what you expect.
But would require more changes, e.g. MDL change, duplicates handling, ...

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4137030#4137030

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4137030



More information about the jboss-dev-forums mailing list