2008/10/25 Edward Yakop <[EMAIL PROTECTED]> > On Sat, Oct 25, 2008 at 00:57, Richard Wallace > <[EMAIL PROTECTED]> wrote: > > I like it! The whole cargo.origin().get() never sat right with me. A > > couple of questions: > > > > 1) Do you really need the @AssociationField in the CargoMixin? Seems > like > > you already have all the information you need available already. > > How do I differentiate between origin and destination? Both of them > are Location associations. > If we could figure out a mechanism that doesn't require magic String. > That would be wonderful. > > > 2) I'm not in love with the builder methods. Maybe something like > > > > EntityBuilder<Cargo> builder = ...; > > Cargo cargoTemplate = builder.template(); > > builder.set( cargoTemplate.origin() ).to( origin ); > > builder.set( cargoTemplate.destination() ).to( destination ); > > How about? > builder.set( cargoTemplate.origin() ).with( origin ); >
FYI, most builder APIs I've seen use to(...) for setting, and use with(...) for describing something > Regards, > Edward Yakop > _______________________________________________ > qi4j-dev mailing list > [email protected] > http://lists.ops4j.org/mailman/listinfo/qi4j-dev > -- Cheers, Stuart
_______________________________________________ qi4j-dev mailing list [email protected] http://lists.ops4j.org/mailman/listinfo/qi4j-dev

