Interface TagRule

All Known Implementing Classes:
BasicRule, BlockExtractingRule, BodyTagRule, ContentBlockExtractingRule, FramesetRule, HeadExtractingRule, HtmlAttributesRule, MetaTagRule, MSOfficeDocumentPropertiesRule, ParameterExtractingRule, StateTransitionRule, TagReplaceRule, TitleExtractingRule

public interface TagRule
The Interface TagRule.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    process(Tag tag)
    Process.
    void
    Sets the context.
    boolean
    Called by the HTMLProcessor to determine if a rule should be called for a given tag.
  • Method Details

    • setContext

      void setContext(HTMLProcessorContext context)
      Sets the context.
      Parameters:
      context - the new context
    • shouldProcess

      boolean shouldProcess(String name)
      Called by the HTMLProcessor to determine if a rule should be called for a given tag. The name parameter will always be passed in lowercase.
      Parameters:
      name - the name
      Returns:
      true, if successful
    • process

      void process(Tag tag)
      Process.
      Parameters:
      tag - the tag