Quoting Niclas Hedhman <[email protected]>:

To make all fragments only contextual ones ( the .withConcerns()
declarations in assembly) is out of the question. It is too difficult to get
an overall picture of things hang together.

The contextual fragments are meant for things that the developer doesn't
need to know when reviewing the domain model, a bit like AOP is promoted to
OOP developers.

-- Niclas


Aah, well, I guess what is difficult for others is easier for anothers. I thought it would have made it clearer to separate code into three sections:

1. The API definition (only interfaces)

2. The API implementation (only possible internal interfaces + implementing classes, possibly many different implementations for same thing, concentrating on security/efficiency/etc)

3. The mapping between defintion and implementation (done, for example, at assembling stage). Thus, whoever creates the mapping, can choose between more secure/efficient/etc implementations. The API creators nor implementators need to worry about declaring which mixin/concern implementation is used, only the creators of mapping would need to worry about that.

It is true though, that it would make things more difficult, and possibly benefits might not be worth the effort. Hard to say, as this again depends on so many factors. I guess if someone really wants the described separation, can always just leave out all the @Mixins(...) etc annotations out.


_______________________________________________
qi4j-dev mailing list
[email protected]
http://lists.ops4j.org/mailman/listinfo/qi4j-dev

Reply via email to