Package org.sonar.iac.common.extension
Class IacSensor
- java.lang.Object
-
- org.sonar.iac.common.extension.IacSensor
-
- All Implemented Interfaces:
org.sonar.api.batch.sensor.Sensor,org.sonar.api.scanner.sensor.ProjectSensor
public abstract class IacSensor extends Object implements org.sonar.api.batch.sensor.Sensor
-
-
Field Summary
Fields Modifier and Type Field Description protected org.sonar.api.measures.FileLinesContextFactoryfileLinesContextFactoryprotected org.sonar.api.resources.Languagelanguageprotected org.sonar.api.issue.NoSonarFilternoSonarFilter
-
Constructor Summary
Constructors Modifier Constructor Description protectedIacSensor(org.sonar.api.SonarRuntime sonarRuntime, org.sonar.api.measures.FileLinesContextFactory fileLinesContextFactory, org.sonar.api.issue.NoSonarFilter noSonarFilter, org.sonar.api.resources.Language language)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voiddescribe(org.sonar.api.batch.sensor.SensorDescriptor descriptor)voidexecute(org.sonar.api.batch.sensor.SensorContext sensorContext)protected abstract StringgetActivationSettingKey()protected voidimportExternalReports(org.sonar.api.batch.sensor.SensorContext sensorContext)protected booleanisSonarLintContext(org.sonar.api.batch.sensor.SensorContext sensorContext)protected org.sonar.api.batch.fs.FilePredicatemainFilePredicate(org.sonar.api.batch.sensor.SensorContext sensorContext)protected abstract StringrepositoryKey()protected ParseExceptiontoParseException(String action, org.sonar.api.batch.fs.InputFile inputFile, Exception cause)protected abstract TreeParser<Tree>treeParser()protected abstract List<TreeVisitor<InputFileContext>>visitors(org.sonar.api.batch.sensor.SensorContext sensorContext, DurationStatistics statistics)
-
-
-
Method Detail
-
describe
public void describe(org.sonar.api.batch.sensor.SensorDescriptor descriptor)
- Specified by:
describein interfaceorg.sonar.api.scanner.sensor.ProjectSensor- Specified by:
describein interfaceorg.sonar.api.batch.sensor.Sensor
-
treeParser
protected abstract TreeParser<Tree> treeParser()
-
repositoryKey
protected abstract String repositoryKey()
-
visitors
protected abstract List<TreeVisitor<InputFileContext>> visitors(org.sonar.api.batch.sensor.SensorContext sensorContext, DurationStatistics statistics)
-
getActivationSettingKey
protected abstract String getActivationSettingKey()
-
execute
public void execute(org.sonar.api.batch.sensor.SensorContext sensorContext)
- Specified by:
executein interfaceorg.sonar.api.scanner.sensor.ProjectSensor- Specified by:
executein interfaceorg.sonar.api.batch.sensor.Sensor
-
mainFilePredicate
protected org.sonar.api.batch.fs.FilePredicate mainFilePredicate(org.sonar.api.batch.sensor.SensorContext sensorContext)
-
importExternalReports
protected void importExternalReports(org.sonar.api.batch.sensor.SensorContext sensorContext)
-
isSonarLintContext
protected boolean isSonarLintContext(org.sonar.api.batch.sensor.SensorContext sensorContext)
-
toParseException
protected ParseException toParseException(String action, org.sonar.api.batch.fs.InputFile inputFile, Exception cause)
-
-