-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add case format to POST explore/studies/STUDY1/cases/ endpoint #73
Conversation
src/main/java/org/gridsuite/explore/server/services/ExploreService.java
Outdated
Show resolved
Hide resolved
bc00024
to
49a5ad2
Compare
@@ -60,9 +60,13 @@ public ExploreService( | |||
this.parametersService = parametersService; | |||
} | |||
|
|||
public void createStudy(String studyName, UUID caseUuid, String description, String userId, UUID parentDirectoryUuid, Map<String, Object> importParams, Boolean duplicateCase) { | |||
public record CaseInfo(UUID caseUuid, String caseFormat) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not creating a dedicated file for this DTO ? I think that's how we do in gridsuite.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CaseInfo is not a DTO, i created it simply because sonar detected a code smell "Long Parameter List". so i fixed it by introducing a parameter object
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
https://github.com/gridsuite/sensitivity-analysis-server/blob/9eed97f9daf845871e778973fa8cf165ba658465/src/main/java/org/gridsuite/sensitivityanalysis/server/dto/ReportInfos.java#L15
https://github.com/gridsuite/security-analysis-server/blob/865c75a020435b84cf5044bdd39bd63c757601c7/src/main/java/org/gridsuite/securityanalysis/server/dto/ReportInfos.java#L21
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know what's the best to do, but by coherence it's better to do how it's done elsewhere
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code OK
No description provided.