[aosd-discuss] "AOP considered harmful"
Juri Memmert
memmert at jpmdesign.de
Mon Apr 25 14:47:10 EST 2005
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Eric Tanter wrote:
> But still, this mailing list is _discuss_ at aosd.net (notice the emphasize
> on 'discuss'), and it seems to me a bit exagerated to insinuate that AOP
> -as it is formulated today- has no problem, and that we shouldn't
> questions ourselves.
Of course AOSD has problems... lots of them... And we need to discuss
them... ;-)
And I think we have more fundamental problems than broken encapsulation.
The major issue in terms of encapsulation, in my opinion, is that AOSD
is not OO and trying to sell it as such is mostly a waste of time (Your
mileage may vary on that, of course).
The major unit of consideration in OO is the class (or however you wish
to name that unit). In AOSD, it is not.
In my work, each concern adheres to the rules of OO, encapsulation among
them, and the major unit of separation is the class. So, on a
sub-concern level, AOSD is indeed plain OO. (Each concern also adheres
to the declarative completeness principle so that each concern declares
what it requires from other concerns in the system.)
But on the concern level, on the weaver level, classes are not important
anymore as units of encapsulation, the concerns and their relationships
are important.
Were I to implement two concerns that share some common information
(field access for instance) in standard OO, the encapsulation would have
to be less restrictive than when implementing both concerns individually
to allow different modules to access the elements of common interest.
So, by implementing the concerns in plain OO, I would break
encapsulation manually, which I consider no better than doing it
automatically through a weaver.
So, I do not see a big problem in the claim that AOSD can break
encapsulation... for the focus is not on the class with broken
encapsulation anymore but on the concerns with intact encapsulation.
Juri
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (Darwin)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFCbUk+dlXiXRccbPMRAlPQAJ9qi84aTmZ2WM8CtPhjbYvu7akL+wCeMMQj
sm/+sMqLvVg3focCbwkLu9A=
=xonC
-----END PGP SIGNATURE-----
More information about the discuss
mailing list