Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-users] when final is not

AspectJ permits you to add members to final classes and advise
various join points whose static shadows are in final classes
without specifying that the aspect is privileged.

Do folks think:

a) this is ok as-is
  i) but we should implement XLint messages for this

b) this should only work for privileged aspects

c) this should only work when you have the source
  code for the final classes

d) only non-public members {or some other subset} is ok
   because users of them know about the aspect

e) this should never work

Consider also:

- We permit advice on field-set join points where the
field is final, and advice on the method-execution of
final methods.

- Respecting final means that the AOP programmer who is working
on system issues can't implement a system-wide concern that
might not have been forseeable on the part of the programmer
of the final class, and in any case is not the responsibility
of the final class.

- We'd like to be able to say things like, "AspectJ respects
Java's modularity unless you explicitly declare an aspect
privileged," in order to have a clean policy that address this
concern of newcomers.

- We can write an XLint message so people can decide for
themselves whether it is ignored, a warning, or an error.

Thanks -
Wes




Back to the top