Class FileImportControl

java.lang.Object
com.puppycrawl.tools.checkstyle.checks.imports.AbstractImportControl
com.puppycrawl.tools.checkstyle.checks.imports.FileImportControl

Represents an import rules for a specific file. Only the file name is considered and only files processed by TreeWalker. The file's extension is ignored.
  • Field Details

    • name

      private final String name
      The name for the file.
    • patternForExactMatch

      The regex pattern for exact matches - only not null if regex is true.
    • regex

      private final boolean regex
      If this file name represents a regular expression.
  • Constructor Details

    • FileImportControl

      FileImportControl(PkgImportControl parent, String name, boolean regex)
      Construct a file node.
      Parameters:
      parent - the parent node.
      name - the name of the file.
      regex - flags interpretation of name as regex pattern.
  • Method Details