Class StringFilter

java.lang.Object
overit.geocall.util.StringFilter

public class StringFilter extends Object
An include/exclude regular expressions mathing rule to be used against a string
  • Field Details

  • Constructor Details

    • StringFilter

      public StringFilter(String includes)
      Creates a filter including some kind of files
      Parameters:
      includes - a regular expression defining inclusions. A null value leads to anlcude any
    • StringFilter

      public StringFilter(String includes, String excludes)
      Creates a filter including some kind of files and among these files excluding some other
      Parameters:
      includes - a regular expression defining inclusions. A null value leads to anlcude any
      excludes - a regular expression defining exclusions. A null value leads to don't exclude any
  • Method Details

    • matches

      public boolean matches(String name)
      The main matching method
      Parameters:
      name - the string to be checked against the filter
      Returns:
      true if the fileter match the name, false otherwise
    • getKey

      public String getKey()
      Returns an unique description of the filter, i/e a representation of the regular expressions
      Returns:
      A string that represent an unique description of the filter, i/e a representation of the regular expressions