Package proguard.util

Class CollectionMatcher


  • public class CollectionMatcher
    extends StringMatcher
    This matcher tests whether strings match with a String in a given Set.
    • Constructor Summary

      Constructors 
      Constructor Description
      CollectionMatcher​(java.lang.String... strings)  
      CollectionMatcher​(java.util.Set<java.lang.String> set)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean matches​(java.lang.String string)
      Checks whether the given string matches.
      protected boolean matches​(java.lang.String string, int beginOffset, int endOffset)
      Checks whether the given substring matches.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • CollectionMatcher

        public CollectionMatcher​(java.util.Set<java.lang.String> set)
      • CollectionMatcher

        public CollectionMatcher​(java.lang.String... strings)
    • Method Detail

      • matches

        public boolean matches​(java.lang.String string)
        Description copied from class: StringMatcher
        Checks whether the given string matches.
        Overrides:
        matches in class StringMatcher
        Parameters:
        string - the string to match.
        Returns:
        a boolean indicating whether the string matches the criterion.
      • matches

        protected boolean matches​(java.lang.String string,
                                  int beginOffset,
                                  int endOffset)
        Description copied from class: StringMatcher
        Checks whether the given substring matches.
        Specified by:
        matches in class StringMatcher
        Parameters:
        string - the string to match.
        beginOffset - the start offset of the substring (inclusive).
        endOffset - the end offset of the substring (exclusive).
        Returns:
        a boolean indicating whether the substring matches the criterion.