abc.weaving.aspectinfo
Interface AdviceSpec

All Known Implementing Classes:
AbstractAdviceSpec, AbstractAfterAdvice, AfterAdvice, AfterReturningAdvice, AfterReturningArgAdvice, AfterThrowingAdvice, AfterThrowingArgAdvice, AroundAdvice, BeforeAdvice, BeforeAfterAdvice, DeclareMessage.MessageAdvice, DeclareSoft.SoftenAdvice

public interface AdviceSpec

An advice specification.

Author:
Aske Simon Christensen

Method Summary
 boolean isAfter()
          Is this advice spec for "after" advice?
 Residue matchesAt(WeavingEnv we, ShadowMatch sm, AbstractAdviceDecl ad)
          Does this kind of advice match at the given join point shadow?
 void weave(SootMethod method, LocalGeneratorEx localgen, AdviceApplication adviceappl)
          Weave a specific advice application into the given method using the given local generator.
 

Method Detail

isAfter

boolean isAfter()
Is this advice spec for "after" advice? This affects the precedence of the advice.


matchesAt

Residue matchesAt(WeavingEnv we,
                  ShadowMatch sm,
                  AbstractAdviceDecl ad)
Does this kind of advice match at the given join point shadow?

Parameters:
we - The weaving environment
sm - The shadow match structure
ad - The advice declaration being matched, for use in generating a good error message if appropriate

weave

void weave(SootMethod method,
           LocalGeneratorEx localgen,
           AdviceApplication adviceappl)
Weave a specific advice application into the given method using the given local generator. The AdviceSpec is used to dispatch to the correct weaving method for the advice type.