brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Zaid Mohsin <zaid.moh...@cloudsoftcorp.com>
Subject First member entity reference
Date Mon, 29 Sep 2014 13:31:12 GMT
Hi Dev,
I’ve been using the new attributes in DynamicCluster that reference the first member entity
and sets a boolean attribute (cluster.first) on each group member to indicate if that is the
first member of the cluster. I think it would be more useful to add an additional attribute
that references the first node to the other non-first members (non-first has attribute of
type Entity that references the first member). Is that feasible? Bad or good design?

Currently to access the first node attributes I’m doing this:

entity.getAttribute(DynamicCluster.CLUSTER).getAttribute(DynamicCluster.FIRST).getAttribute(MY_ATTRIBUTE);

where if we include the first entity reference it would look something like this

entity.getAttribute(DynamicCluster.FIRST).getAttribute(MY_ATTRIBUTE);

Regards

Mime
View raw message