Package de.ikor.sip.foundation.mvnplugin
Class ImportAnalyzer
java.lang.Object
de.ikor.sip.foundation.mvnplugin.ImportAnalyzer
Collects banned import matches from a single source file.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription(package private) Optional<BannedImportRecords>
checkFile
(ParsedJavaFile sourceFile, BannedImportGroups groups) Collects all imports that are banned within the given source file.
-
Constructor Details
-
ImportAnalyzer
ImportAnalyzer()
-
-
Method Details
-
checkFile
Collects all imports that are banned within the given source file.- Parameters:
sourceFile
- The parsed file to check for banned imports..groups
- The groups of banned imports to check the file against. From all groups, the one with the most specific base pattern match is chosen.- Returns:
- a
BannedImportRecords
holds information about the found matches. Returns an empty optional if no matches were found.
-