/src/LinFu.AOP/Interfaces/IFieldFilter.cs

http://github.com/philiplaureano/LinFu · C# · 18 lines · 8 code · 1 blank · 9 comment · 0 complexity · fd5230cc886a3869b4c1b4cd60c041d8 MD5 · raw file

  1. using Mono.Cecil;
  2. namespace LinFu.AOP.Cecil.Interfaces
  3. {
  4. /// <summary>
  5. /// Represents a type that determines whether or not a particular field get or set should be intercepted.
  6. /// </summary>
  7. public interface IFieldFilter
  8. {
  9. /// <summary>
  10. /// Determines whether or not a particular field get or set should be intercepted.
  11. /// </summary>
  12. /// <param name="hostMethod">The host method.</param>
  13. /// <param name="targetField">The target field.</param>
  14. /// <returns>Returns <c>true</c> if the field should be intercepted; otherwise, it will return <c>false</c>.</returns>
  15. bool ShouldWeave(MethodReference hostMethod, FieldReference targetField);
  16. }
  17. }