Announcement Announcement Module
Collapse
No announcement yet.
Howto write the expression in a <aop:pointcut>? Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Howto write the expression in a <aop:pointcut>?

    Hi,

    I can write a <aopointcut> like this:
    Code:
    <aop:pointcut id="nodeDaoMethods" expression="execution(* com.m.ll.lldao.impl.NodeDaoImpl.*(..))" />
    I want to specify some particular methods of the NodeDaoImpl class in the expression (the method names have nothing in common, i.e. if regular expression is used, a regular expression for those names is x | y | z, where x, y, z are method names). How could I do that?

    Regards.

  • #2
    If I understand the question correctly, you could do something like:

    Code:
    <aop:pointcut id="nodeDaoMethods" expression="execution(* com.m.ll.lldao.impl.NodeDaoImpl.x(..)) || execution(* com.m.ll.lldao.impl.NodeDaoImpl.y(..)) || execution(* com.m.ll.lldao.impl.NodeDaoImpl.z(..))" />

    Comment

    Working...
    X