Class VariableAccessFilter<T extends CtVariableAccess<?>>

java.lang.Object
spoon.reflect.visitor.filter.VariableAccessFilter<T>
All Implemented Interfaces:
Filter<T>
Direct Known Subclasses:
FieldAccessFilter

public class VariableAccessFilter<T extends CtVariableAccess<?>> extends Object implements Filter<T>
This simple filter matches all the accesses to a given field.
  • Constructor Details

    • VariableAccessFilter

      public VariableAccessFilter(CtVariableReference<?> variable)
      Creates a new field access filter.
      Parameters:
      variable - the accessed variable
  • Method Details

    • matches

      public boolean matches(T variableAccess)
      Description copied from interface: Filter
      Tells if the given element matches.
      Specified by:
      matches in interface Filter<T extends CtVariableAccess<?>>
      Parameters:
      variableAccess - - the element to be checked for a match. Parameter element is never null if Query is used.