diff options
Diffstat (limited to 'server/sonar-db-dao/src/main/java/org/sonar/db/issue')
-rw-r--r-- | server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueDto.java | 7 | ||||
-rw-r--r-- | server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueMapper.java | 4 |
2 files changed, 10 insertions, 1 deletions
diff --git a/server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueDto.java b/server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueDto.java index df8b2f9fb07..252431d5a26 100644 --- a/server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueDto.java +++ b/server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueDto.java @@ -28,6 +28,7 @@ import com.google.protobuf.InvalidProtocolBufferException; import java.io.Serializable; import java.util.Collection; import java.util.Date; +import java.util.Optional; import java.util.Set; import javax.annotation.CheckForNull; import javax.annotation.Nullable; @@ -97,6 +98,8 @@ public final class IssueDto implements Serializable { private String filePath; private String tags; private boolean isFromHotspot; + // populate only when retrieving closed issue for issue tracking + private String lineChangeData; /** * On batch side, component keys and uuid are useless @@ -698,6 +701,10 @@ public final class IssueDto implements Serializable { return this; } + public Optional<String> getLineChangeData() { + return Optional.ofNullable(lineChangeData); + } + @Override public String toString() { return ToStringBuilder.reflectionToString(this, ToStringStyle.SHORT_PREFIX_STYLE); diff --git a/server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueMapper.java b/server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueMapper.java index 0f80126c88c..9098c986d15 100644 --- a/server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueMapper.java +++ b/server/sonar-db-dao/src/main/java/org/sonar/db/issue/IssueMapper.java @@ -43,7 +43,9 @@ public interface IssueMapper { int updateIfBeforeSelectedDate(IssueDto issue); void scrollNonClosedByComponentUuid(@Param("componentUuid") String componentUuid, ResultHandler<IssueDto> handler); - + + void scrollClosedByComponentUuid(@Param("componentUuid") String componentUuid, ResultHandler<IssueDto> handler); + List<IssueDto> selectNonClosedByComponentUuidExcludingExternals(@Param("componentUuid") String componentUuid); List<IssueDto> selectNonClosedByModuleOrProject(@Param("projectUuid") String projectUuid, @Param("likeModuleUuidPath") String likeModuleUuidPath); |