Skip to content

Commit

Permalink
feat: Add Functions To IndexingProfiles.java
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexanderBlanchardAC committed Nov 15, 2024
1 parent aa367cc commit 429a950
Showing 1 changed file with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ public class IndexingProfile extends BaseIndexingSettings {
private long lastUpdateOfAuthorities;
private long lastChangeProcessed;
private Pattern suppressRecordsWithUrlsMatching;
private Pattern treatItemsAsEcontent;
private String fallbackFormatField;
private boolean processRecordLinking;
private int evergreenOrgUnitSchema;
Expand Down Expand Up @@ -194,6 +195,7 @@ public IndexingProfile(String serverName, ResultSet indexingProfileRS, Connectio

this.setDoAutomaticEcontentSuppression(indexingProfileRS.getBoolean("doAutomaticEcontentSuppression"));
this.setSuppressRecordsWithUrlsMatching(indexingProfileRS.getString("suppressRecordsWithUrlsMatching"));
this.setTreatItemsAsEcontent(indexingProfileRS.getString("treatItemsAsEcontent"));
this.setEContentDescriptor(getCharFromRecordSet(indexingProfileRS, "eContentDescriptor"));

this.setLastYearCheckoutsSubfield(getCharFromRecordSet(indexingProfileRS, "lastYearCheckouts"));
Expand Down Expand Up @@ -892,10 +894,22 @@ public void setSuppressRecordsWithUrlsMatching(String suppressRecordsWithUrlsMat
}
}

public void setTreatItemsAsEcontent(String treatItemsAsEcontent) {
if (treatItemsAsEcontent.isEmpty()){
this.treatItemsAsEcontent = null;
} else {
this.treatItemsAsEcontent = Pattern.compile(treatItemsAsEcontent, Pattern.CASE_INSENSITIVE);
}
}

public Pattern getSuppressRecordsWithUrlsMatching() {
return suppressRecordsWithUrlsMatching;
}

public Pattern getTreatItemsAsEcontent() {
return treatItemsAsEcontent;
}

public void setFallbackFormatField(String fallbackFormatField) {
this.fallbackFormatField = fallbackFormatField;
}
Expand Down

0 comments on commit 429a950

Please sign in to comment.