Skip to content

Commit bcaf896

Browse files
committed
Adding the new client options to the json printer and parser #10909
1 parent faba65d commit bcaf896

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

src/main/java/edu/harvard/iq/dataverse/util/json/JsonParser.java

+2
Original file line numberDiff line numberDiff line change
@@ -1011,6 +1011,8 @@ public String parseHarvestingClient(JsonObject obj, HarvestingClient harvestingC
10111011
harvestingClient.setHarvestingSet(obj.getString("set",null));
10121012
harvestingClient.setCustomHttpHeaders(obj.getString("customHeaders", null));
10131013
harvestingClient.setAllowHarvestingMissingCVV(obj.getBoolean("allowHarvestingMissingCVV", false));
1014+
harvestingClient.setUseListrecords(obj.getBoolean("useListRecords", false));
1015+
harvestingClient.setUseOaiIdentifiersAsPids(obj.getBoolean("useOaiIdentifiersAsPids", false));
10141016

10151017
return dataverseAlias;
10161018
}

src/main/java/edu/harvard/iq/dataverse/util/json/JsonPrinter.java

+2
Original file line numberDiff line numberDiff line change
@@ -1011,6 +1011,8 @@ public static JsonObjectBuilder json(HarvestingClient harvestingClient) {
10111011
add("status", harvestingClient.isHarvestingNow() ? "inProgress" : "inActive").
10121012
add("customHeaders", harvestingClient.getCustomHttpHeaders()).
10131013
add("allowHarvestingMissingCVV", harvestingClient.getAllowHarvestingMissingCVV()).
1014+
add("useListRecords", harvestingClient.isUseListRecords()).
1015+
add("useOaiIdentifiersAsPids", harvestingClient.isUseOaiIdentifiersAsPids()).
10141016
add("lastHarvest", harvestingClient.getLastHarvestTime() == null ? null : harvestingClient.getLastHarvestTime().toString()).
10151017
add("lastResult", harvestingClient.getLastResult()).
10161018
add("lastSuccessful", harvestingClient.getLastSuccessfulHarvestTime() == null ? null : harvestingClient.getLastSuccessfulHarvestTime().toString()).

0 commit comments

Comments
 (0)