Interface Advisor

    • Field Summary

      Fields 
      Modifier and TypeFieldDescription
      static AdviceEMPTY_ADVICE
      Common placeholder for an empty Advice to be returned from getAdvice() if no proper advice has been configured (yet).
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and TypeMethodDescription
      AdvicegetAdvice()
      Return the advice part of this aspect.
      booleanisPerInstance()
      Return whether this advice is associated with a particular instance (for example, creating a mixin) or shared with all instances of the advised class obtained from the same Spring bean factory.
    • Field Detail

      • EMPTY_ADVICE

        static final Advice EMPTY_ADVICE
        Common placeholder for an empty Advice to be returned from getAdvice() if no proper advice has been configured (yet).
        Since:
        5.0
    • Method Detail

      • isPerInstance

        boolean isPerInstance()
        Return whether this advice is associated with a particular instance (for example, creating a mixin) or shared with all instances of the advised class obtained from the same Spring bean factory.

        Note that this method is not currently used by the framework. Typical Advisor implementations always return true. Use singleton/prototype bean definitions or appropriate programmatic proxy creation to ensure that Advisors have the correct lifecycle model.

        Returns:
        whether this advice is associated with a particular target instance