Skip to content

Commit dd51af2

Browse files
committed
Refactor: Rename getSdkNoticeType to getSdkNoticeSubtype and update variable names
1 parent 7d77eff commit dd51af2

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

src/main/java/eu/europa/ted/eforms/sdk/entity/SdkEntityFactory.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public static SdkNode getSdkNode(String sdkVersion, JsonNode node) throws Instan
3131
SdkNode.class, node);
3232
}
3333

34-
public static SdkNoticeSubtype getSdkNoticeType(final String sdkVersion, final JsonNode json)
34+
public static SdkNoticeSubtype getSdkNoticeSubtype(final String sdkVersion, final JsonNode json)
3535
throws InstantiationException {
3636
return SdkEntityFactory.INSTANCE.getComponentImpl(sdkVersion, SdkComponentType.NOTICE_TYPE,
3737
SdkNoticeSubtype.class, json);

src/main/java/eu/europa/ted/eforms/sdk/repository/SdkNoticeTypeRepository.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ public SdkNoticeTypeRepository(String sdkVersion, Path jsonPath) throws Instanti
2020

2121
@Override
2222
protected void populateMap(final JsonNode json) throws InstantiationException {
23-
final ArrayNode noticeTypes = (ArrayNode) json.get(SdkConstants.NOTICE_TYPES_JSON_SUBTYPES_KEY);
24-
for (final JsonNode noticeType : noticeTypes) {
25-
final SdkNoticeSubtype sdkNoticeType = SdkEntityFactory.getSdkNoticeType(sdkVersion, noticeType);
26-
put(sdkNoticeType.getId(), sdkNoticeType);
23+
final ArrayNode noticeSubtypes = (ArrayNode) json.get(SdkConstants.NOTICE_TYPES_JSON_SUBTYPES_KEY);
24+
for (final JsonNode noticeSubtype : noticeSubtypes) {
25+
final SdkNoticeSubtype sdkNoticeSubtype = SdkEntityFactory.getSdkNoticeSubtype(sdkVersion, noticeSubtype);
26+
put(sdkNoticeSubtype.getId(), sdkNoticeSubtype);
2727
}
2828
}
2929
}

0 commit comments

Comments
 (0)