[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-dev] pertypewithin() vs. pertype() association...

I was wondering about the design considerations in choosing pertypewithin() over pertype() proposal discussed in https://bugs.eclipse.org/bugs/show_bug.cgi?id=48082. The pertype() proposal, especially the pertype(PointcutDesignator) version, seems to align better with the rest of the language.

Pros of pertype(PointcutDesignator) over pertypewithin(). Use of pointcut designator instead of type pattern allows
- Writing abstract reusable aspects with pertype() association, while deferring selection of types to derived aspects.
- Aligning with other per- associations that all take a pointcut designator ==> less things to learn
- Implementing all use cases of pertypewithin(<type_pattern>) by using a pertype(within(<type_pattern>)) association.


-Ramnivas