Results 1 to 2 of 2

Thread: Wildcards in @Pointcut execution

  1. #1
    Join Date
    Jul 2009
    Posts
    1

    Default Wildcards in @Pointcut execution

    Hi,

    I have an example pointcut which I can't quite figure out

    Pointcut("execution(* *..Controller+.*(..))")

    I'm wondering if anyone can tell me what the "+" is doing in the middle of the package. Is this a wildcard or just part of the package name?

    A stupid question I'm sure but it's bugging me and I don't have access to my spring environment to do some tests.

  2. #2
    Join Date
    Jun 2006
    Location
    The Netherlands
    Posts
    13,632

    Default

    Well I suggest the AspectJ reference guide or the excellent AspectJ in Action book.

    1) It isn't part of the package it is part of the classname
    2) It means any subclass/subinterface or implementation (the latter if the + is on an Interface as in your sample)
    Marten Deinum
    Java Consultant / Pragmatist / Open Source Enthousiast / Author


    Pro Spring MVC: With Web Flow
    Conspect

    Have you read the reference guide.
    Use the [ code ] tags, young padawan

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •