Hi folks, Andi has brought in a new feature for 2.0.0-M1, namely to provide a list of hierarchical breadcrumbs in the Wicket viewer.
For example, in Estatio there's a hierarchy of Lease > LeaseItem > LeaseTerm. Each domain object "knows" its parent (there can be only one). When one of these objects is rendered, the breadcrumbs panel (rendered above the icon/title) show the full chain. You will have seen similar device in your IDE, I am sure. My question is about programming model for this. Andi has implemented this using a new @Parent annotation, that is on the parent reference within the child object, eg: public class Lease { .. } public class LeaseItem { @Parent Lease lease; ... } public class LeaseTerm { @Parent LeaseItem leaseItem; ... } However, we moved away quite a long time ago from these very specific annotations, and so now try to wrap up everything as attributes of @Property/@PropertyLayout etc. Since this is a UI concern only, I think instead we should add a new attribute to @PropertyLayout, eg: public class LeaseTerm { @PropertyLayout(parented=true) LeaseItem leaseItem; } One wrinkle ... since this is for 2.0.0-M1, which supports meta-annotations, I've actually gone through and changed all attributes that have a boolean, because there needs to be a default "not specified" setting. For example, @DomainObject(bounded=true|false) is instead @DomainObject(bounding=Bounding.BOUNDED|NOT_BOUNDED|NOT_SPECIFIED). So, in fact I propose: public class LeaseTerm { @PropertyLayout(parenting=Parenting.PARENTED|NOT_PARENTED|NOT_SPECIFIED) LeaseItem leaseItem; } or perhaps the term "parenting" is rather strange. Since this is a UI concern only, we could instead use the word "breadcrumbs", etc: public class LeaseTerm { @PropertyLayout(breadcrumbs=Breadcrumbs.BREADCRUMBS|NO_BREADCRUMBS|NOT_SPECIFIED) LeaseItem leaseItem; } Opinions, please. Thx! Dan