Class AbstractMatcherContainer

java.lang.Object
org.apache.rat.analysis.matchers.AbstractHeaderMatcher
org.apache.rat.analysis.matchers.AbstractMatcherContainer
All Implemented Interfaces:
IHeaderMatcher
Direct Known Subclasses:
AndMatcher, OrMatcher

public abstract class AbstractMatcherContainer extends AbstractHeaderMatcher
A class that implements IHeaderMatcher as a collection of other IHeaderMatchers.
  • Field Details

  • Constructor Details

    • AbstractMatcherContainer

      public AbstractMatcherContainer(String id, Collection<? extends IHeaderMatcher> enclosed)
      Constructs the abstract matcher container. If the id is not set then a unique random identifier is created. The enclosed collection is preserved in a new collection that retains the order of of the original collection.
      Parameters:
      id - The id for the matcher.
      enclosed - the collection of enclosed matchers.
    • AbstractMatcherContainer

      public AbstractMatcherContainer(Collection<? extends IHeaderMatcher> enclosed)
      Constructs the abstract matcher container with a unique random id. The enclosed collection is preserved in a new collection that retains the order of of the original collection.
      Parameters:
      enclosed - the collection of enclosed matchers.
  • Method Details

    • reset

      public void reset()
      Description copied from interface: IHeaderMatcher
      Resets this state State.i. If text is being cached this method should clear that cache.
    • finalizeState

      public IHeaderMatcher.State finalizeState()
      Description copied from interface: IHeaderMatcher
      Gets the final state for this matcher. This is called after the EOF on the input. At this point there should be no matchers in an State.i state.