Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-users] pointcut wildcard question

Hi,

I notice some behaviour with pointcuts that I do not understand. Consider the following:

pointcut getters() : execution( * MyInterface+.get*())

-> This matches any method that starts with 'get' of any subclass of MyInterface and has no arguments.

Then I change it to this:

pointcut getters() : execution( * MyInterface+.get*(*))

-> I thought that this would match the same methods as before, with additionaliy getters that take arguments. So the ones with no arguments and the ones with any number of arguments.

However testing in Eclipse shows that the second form does NOT match the methods without arguments. Is this intentionally?

regards,

Wim


Back to the top