abc.weaving.aspectinfo
Class Pointcut.DNF

java.lang.Object
  extended by abc.weaving.aspectinfo.Pointcut.DNF
Enclosing class:
Pointcut

protected static final class Pointcut.DNF
extends java.lang.Object

This class is used to calculate the disjunctive normal form of pointcuts. This needs to happen to efficiently implement the backtracking semantics of disjunction. This structure is built compositionally for compound pointcuts, and then converted back to a Pointcut when the final version is required. This structure should only be constructed for pointcuts that do not have any name clashes (the pointcuts returned by the inline method have this property).


Constructor Summary
Pointcut.DNF(Pointcut pc)
          Construct DNF from a singleton pointcut
 
Method Summary
static Pointcut.DNF and(Pointcut.DNF dnf1, Pointcut.DNF dnf2)
           
static Pointcut.DNF declare(Pointcut.DNF dnf, java.util.List formals)
          Add a new formal that is in scope somewhere.
 Pointcut makePointcut(Position pos)
          Turn the DNF back into a pointcut
static Pointcut.DNF or(Pointcut.DNF dnf1, Pointcut.DNF dnf2)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Pointcut.DNF

public Pointcut.DNF(Pointcut pc)
Construct DNF from a singleton pointcut

Method Detail

or

public static Pointcut.DNF or(Pointcut.DNF dnf1,
                              Pointcut.DNF dnf2)

declare

public static Pointcut.DNF declare(Pointcut.DNF dnf,
                                   java.util.List formals)
Add a new formal that is in scope somewhere. The precise scope is lost, so this is only safe for pointcuts that are valid and contain no name clashes.


and

public static Pointcut.DNF and(Pointcut.DNF dnf1,
                               Pointcut.DNF dnf2)

makePointcut

public Pointcut makePointcut(Position pos)
Turn the DNF back into a pointcut

Parameters:
pos - The source position of the original pointcut
Returns:
The resulting pointcut