-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
4 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 1 addition & 35 deletions
36
...etis-enrichment-common/src/main/java/eu/europeana/enrichment/api/internal/FieldValue.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,5 @@ | ||
package eu.europeana.enrichment.api.internal; | ||
|
||
import java.util.Objects; | ||
public record FieldValue(String value, String language) { | ||
|
||
public final class FieldValue { | ||
|
||
private final String value; | ||
private final String language; | ||
|
||
public FieldValue(String value, String language) { | ||
this.value = value; | ||
this.language = language; | ||
} | ||
|
||
public String getValue() { | ||
return value; | ||
} | ||
|
||
public String getLanguage() { | ||
return language; | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) { | ||
return true; | ||
} | ||
if (o == null || getClass() != o.getClass()) { | ||
return false; | ||
} | ||
final FieldValue that = (FieldValue) o; | ||
return Objects.equals(value, that.value) && Objects.equals(language, that.language); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(value, language); | ||
} | ||
} |