Examples of InputPath


Examples of org.sonar.api.batch.fs.InputPath

  }

  @Override
  public void store(Issue issue) {
    Resource r;
    InputPath inputPath = issue.inputPath();
    if (inputPath != null) {
      if (inputPath instanceof InputDir) {
        r = Directory.create(inputPath.relativePath());
      } else {
        r = File.create(inputPath.relativePath());
      }
    } else {
      r = project;
    }
    Issuable issuable = perspectives.as(Issuable.class, r);
View Full Code Here

Examples of org.sonar.api.batch.fs.InputPath

        .beginArray();
      for (Issue issue : issueCache.byModule(def.getKey())) {
        jsonWriter.beginObject()
          .prop("repository", issue.ruleKey().repository())
          .prop("rule", issue.ruleKey().rule());
        InputPath inputPath = issue.inputPath();
        if (inputPath != null) {
          jsonWriter.prop("path", inputPath.relativePath());
        }
        jsonWriter.prop("message", issue.message())
          .prop("effortToFix", issue.effortToFix())
          .prop("line", issue.line());
        Severity overridenSeverity = issue.overridenSeverity();
View Full Code Here

Examples of org.sonar.api.batch.fs.InputPath

  @Override
  public void put(Value value, Object object, CoderContext context) {
    DefaultIssue issue = (DefaultIssue) object;
    value.putString(issue.key());
    InputPath inputPath = issue.inputPath();
    if (inputPath != null) {
      if (inputPath instanceof InputDir) {
        value.put(0);
        value.putString(((DefaultInputDir) inputPath).moduleKey());
        value.putString(inputPath.relativePath());
      } else {
        value.put(1);
        value.putString(((DefaultInputFile) inputPath).moduleKey());
        value.putString(inputPath.relativePath());
        value.put(issue.line());
      }
    } else {
      value.putNull();
    }
View Full Code Here

Examples of org.sonar.api.batch.fs.InputPath

  }

  @Override
  public void store(Issue issue) {
    String resourceKey;
    InputPath inputPath = issue.inputPath();
    if (inputPath != null) {
      resourceKey = ComponentKeys.createEffectiveKey(def.getKey(), inputPath);
    } else {
      resourceKey = def.getKey();
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.