Class MethodDeclarationPattern

All Implemented Interfaces:
Cloneable, IParallelizable, IIndexConstants

public class MethodDeclarationPattern extends MethodPattern
  • Field Details

    • extraFlags

      public int extraFlags
    • declaringTypeModifiers

      public int declaringTypeModifiers
    • modifiers

      public int modifiers
    • signature

      public char[] signature
    • parameterTypes

      public char[][] parameterTypes
    • parameterNames

      public char[][] parameterNames
    • fusedDeclaringQualifier

      public char[] fusedDeclaringQualifier
  • Constructor Details

    • MethodDeclarationPattern

      public MethodDeclarationPattern(char[] declaringPackageName, char[] declaringQualification, char[] declaringSimpleName, char[] methodName, int matchRule)
    • MethodDeclarationPattern

      public MethodDeclarationPattern(char[] declaringQualifier, char[] methodName, int matchRule)
    • MethodDeclarationPattern

      public MethodDeclarationPattern(int matchRule)
  • Method Details

    • createDeclarationIndexKey

      public static char[] createDeclarationIndexKey(char[] typeName, char[] declaringQualification, char[] methodName, int argCount, char[] signature, char[][] parameterTypes, char[][] parameterNames, char[] returnType, int modifiers, char[] packageName, int typeModifiers, int extraFlags)
      Method Declaration entries are encoded as described Binary Method Declaration for class MethodName '/' Arity '/' DeclaringQualifier '/' TypeName '/' TypeModifers '/' PackageName '/' Signature '/' ParameterNamesopt '/' Modifiers '/' returnType Source method for class MethodName '/' Arity '/' DeclaringQualifier '/' TypeName '/' TypeModifers '/' PackageName '/' ParameterTypes '/' ParameterNamesopt '/' Modifiers '/' returnType TypeModifiers contains some encoded extra information ExtraFlags.IsMemberType ExtraFlags.HasNonPrivateStaticMemberTypes ExtraFlags.ParameterTypesStoredAsSignature
    • decodeIndexKey

      public void decodeIndexKey(char[] key)
      Description copied from class: SearchPattern
      Decode the given index key in this pattern. The decoded index key is used by SearchPattern.matchesDecodedKey(SearchPattern) to find out if the corresponding index entry should be considered.

      This method should be re-implemented in subclasses that need to decode an index key.

      Overrides:
      decodeIndexKey in class MethodPattern
      Parameters:
      key - the given index key
    • getBlankPattern

      public SearchPattern getBlankPattern()
      Description copied from class: SearchPattern
      Returns a blank pattern that can be used as a record to decode an index key.

      Implementors of this method should return a new search pattern that is going to be used to decode index keys.

      Overrides:
      getBlankPattern in class MethodPattern
      Returns:
      a new blank pattern
      See Also:
      SearchPattern.decodeIndexKey(char[])
    • getIndexCategories

      public char[][] getIndexCategories()
      Description copied from class: SearchPattern
      Returns an array of index categories to consider for this index query. These potential matches will be further narrowed by the match locator, but precise match locating can be expensive, and index query should be as accurate as possible so as to eliminate obvious false hits.

      This method should be re-implemented in subclasses that need to narrow down the index query.

      Overrides:
      getIndexCategories in class MethodPattern
      Returns:
      an array of index categories