Skip to content

Commit 922dd6c

Browse files
Move tests
1 parent 54d9d52 commit 922dd6c

File tree

2 files changed

+6
-421
lines changed

2 files changed

+6
-421
lines changed

src/main/java/org/gridsuite/computation/utils/FilterUtils.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@
2020
* @author maissa Souissi <maissa.souissi at rte-france.com>
2121
*/
2222
public final class FilterUtils {
23-
2423
// Utility class, so no constructor
2524
private FilterUtils() {
25+
throw new IllegalCallerException("Utility class");
2626
}
2727

2828
private static <T> T fromStringToDTO(String jsonString, ObjectMapper objectMapper, TypeReference<T> typeReference, T defaultValue) {
@@ -37,13 +37,11 @@ private static <T> T fromStringToDTO(String jsonString, ObjectMapper objectMappe
3737
}
3838

3939
public static List<ResourceFilterDTO> fromStringFiltersToDTO(String stringFilters, ObjectMapper objectMapper) {
40-
return fromStringToDTO(stringFilters, objectMapper, new TypeReference<>() {
41-
}, List.of());
40+
return fromStringToDTO(stringFilters, objectMapper, new TypeReference<>() { }, List.of());
4241
}
4342

4443
public static GlobalFilter fromStringGlobalFiltersToDTO(String stringGlobalFilters, ObjectMapper objectMapper) {
45-
return fromStringToDTO(stringGlobalFilters, objectMapper, new TypeReference<>() {
46-
}, null);
44+
return fromStringToDTO(stringGlobalFilters, objectMapper, new TypeReference<>() { }, null);
4745
}
4846
}
4947

0 commit comments

Comments
 (0)