Class URLMatchesRegex

java.lang.Object
it.unimi.dsi.law.warc.filters.AbstractFilter<URI>
it.unimi.dsi.law.warc.filters.URLMatchesRegex
All Implemented Interfaces:
com.google.common.base.Predicate<URI>, Filter<URI>, Predicate<URI>

public class URLMatchesRegex
extends AbstractFilter<URI>
Accepts only URIs that match a certain regular expression.
  • Constructor Details

    • URLMatchesRegex

      public URLMatchesRegex​(String expr)
      Creates a filter that only accepts URLs matching a given regular expression.
      Parameters:
      expr - the regular expression.
  • Method Details

    • apply

      public boolean apply​(URI uri)
    • valueOf

      public static URLMatchesRegex valueOf​(String spec)
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals​(Object x)
      Specified by:
      equals in interface com.google.common.base.Predicate<URI>
      Overrides:
      equals in class Object