-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into EA-3957-insert-multiple-items
- Loading branch information
Showing
47 changed files
with
1,408 additions
and
706 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
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
79 changes: 79 additions & 0 deletions
79
set-definitions/src/main/java/eu/europeana/set/definitions/model/BaseWebResource.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 |
---|---|---|
@@ -0,0 +1,79 @@ | ||
package eu.europeana.set.definitions.model; | ||
|
||
import java.util.Objects; | ||
|
||
public class BaseWebResource { | ||
|
||
public static final String TYPE = "WebResource"; | ||
private String source; | ||
private String id; | ||
private String thumbnail; | ||
|
||
public BaseWebResource() { | ||
super(); | ||
} | ||
|
||
public BaseWebResource(BaseWebResource copy) { | ||
this.source = copy.getSource(); | ||
this.id = copy.getId(); | ||
this.thumbnail = copy.getThumbnail(); | ||
} | ||
|
||
public BaseWebResource(String id, String source, String thumbnail) { | ||
this.id = id; | ||
this.source = source; | ||
this.thumbnail = thumbnail; | ||
} | ||
|
||
public String getId() { | ||
return id; | ||
} | ||
|
||
public String getSource() { | ||
return source; | ||
} | ||
|
||
public String getThumbnail() { | ||
return thumbnail; | ||
} | ||
|
||
public String getType() { | ||
return TYPE; | ||
} | ||
|
||
public void setThumbnail(String thumbnailParam) { | ||
thumbnail = thumbnailParam; | ||
} | ||
|
||
public void setSource(String sourceParam) { | ||
source = sourceParam; | ||
} | ||
|
||
public void setId(String idParam) { | ||
id = idParam; | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) { | ||
return true; | ||
} | ||
if (o == null || getClass() != o.getClass()) { | ||
return false; | ||
} | ||
|
||
BaseWebResource that = (BaseWebResource) o; | ||
|
||
return Objects.equals(source, that.getSource()) | ||
&& id.equals(that.getId()) | ||
&& Objects.equals(thumbnail, that.getThumbnail()); | ||
} | ||
|
||
public int hashCode() { | ||
int result = (id == null) ? 0 : id.hashCode(); | ||
result += (thumbnail == null) ? 0 : thumbnail.hashCode(); | ||
result += (source == null) ? 0 : source.hashCode(); | ||
return result; | ||
} | ||
|
||
} |
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
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
Oops, something went wrong.