-
Notifications
You must be signed in to change notification settings - Fork 153
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
1 parent
40462e1
commit 06854bc
Showing
12 changed files
with
702 additions
and
0 deletions.
There are no files selected for viewing
79 changes: 79 additions & 0 deletions
79
orcid-api-web/src/main/java/org/orcid/api/member/model/Employment.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 org.orcid.api.member.model; | ||
|
||
import java.util.Objects; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElement; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
import org.orcid.jaxb.model.v3.release.common.FuzzyDate; | ||
|
||
import io.swagger.v3.oas.annotations.media.Schema; | ||
|
||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(propOrder = { "putCode", "endDate", "organizationName", "validated" }) | ||
@XmlRootElement(name = "employment", namespace = "http://www.orcid.org/ns/summary") | ||
@Schema(description = "Employment") | ||
public class Employment { | ||
@XmlElement(name = "put-code", namespace = "http://www.orcid.org/ns/summary") | ||
private Long putCode; | ||
@XmlElement(name = "end-date", namespace = "http://www.orcid.org/ns/common") | ||
private FuzzyDate endDate; | ||
@XmlElement(name = "organization-name", namespace = "http://www.orcid.org/ns/summary") | ||
private String organizationName; | ||
@XmlElement(name = "validated", namespace = "http://www.orcid.org/ns/summary") | ||
private boolean validated; | ||
|
||
public Long getPutCode() { | ||
return putCode; | ||
} | ||
|
||
public void setPutCode(Long putCode) { | ||
this.putCode = putCode; | ||
} | ||
|
||
public FuzzyDate getEndDate() { | ||
return endDate; | ||
} | ||
|
||
public void setEndDate(FuzzyDate endDate) { | ||
this.endDate = endDate; | ||
} | ||
|
||
public String getOrganizationName() { | ||
return organizationName; | ||
} | ||
|
||
public void setOrganizationName(String organizationName) { | ||
this.organizationName = organizationName; | ||
} | ||
|
||
public boolean isValidated() { | ||
return validated; | ||
} | ||
|
||
public void setValidated(boolean validated) { | ||
this.validated = validated; | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(endDate, organizationName, putCode, validated); | ||
} | ||
|
||
@Override | ||
public boolean equals(Object obj) { | ||
if (this == obj) | ||
return true; | ||
if (obj == null) | ||
return false; | ||
if (getClass() != obj.getClass()) | ||
return false; | ||
Employment other = (Employment) obj; | ||
return Objects.equals(endDate, other.endDate) && Objects.equals(organizationName, other.organizationName) && Objects.equals(putCode, other.putCode) | ||
&& validated == other.validated; | ||
} | ||
|
||
} |
56 changes: 56 additions & 0 deletions
56
orcid-api-web/src/main/java/org/orcid/api/member/model/Employments.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,56 @@ | ||
package org.orcid.api.member.model; | ||
|
||
import java.util.List; | ||
import java.util.Objects; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElement; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
import io.swagger.v3.oas.annotations.media.Schema; | ||
|
||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(propOrder = { "count", "employments" }) | ||
@XmlRootElement(name = "employments", namespace = "http://www.orcid.org/ns/summary") | ||
@Schema(description = "Employments list") | ||
public class Employments { | ||
@XmlElement(name = "count", namespace = "http://www.orcid.org/ns/activities") | ||
private Integer count; | ||
@XmlElement(name = "employment", namespace = "http://www.orcid.org/ns/activities") | ||
private List<Employment> employments; | ||
|
||
public Integer getCount() { | ||
return count; | ||
} | ||
|
||
public void setCount(Integer count) { | ||
this.count = count; | ||
} | ||
|
||
public List<Employment> getEmployments() { | ||
return employments; | ||
} | ||
|
||
public void setEmployments(List<Employment> employments) { | ||
this.employments = employments; | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(count, employments); | ||
} | ||
|
||
@Override | ||
public boolean equals(Object obj) { | ||
if (this == obj) | ||
return true; | ||
if (obj == null) | ||
return false; | ||
if (getClass() != obj.getClass()) | ||
return false; | ||
Employments other = (Employments) obj; | ||
return Objects.equals(count, other.count) && Objects.equals(employments, other.employments); | ||
} | ||
} |
87 changes: 87 additions & 0 deletions
87
orcid-api-web/src/main/java/org/orcid/api/member/model/ExternalIdentifier.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,87 @@ | ||
package org.orcid.api.member.model; | ||
|
||
import java.util.Objects; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElement; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
import io.swagger.v3.oas.annotations.media.Schema; | ||
|
||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(propOrder = { "putCode", "externalIdType", "externalIdValue", "externalIdUrl", "validated" }) | ||
@XmlRootElement(name = "external-identifier", namespace = "http://www.orcid.org/ns/summary") | ||
@Schema(description = "External identifier") | ||
public class ExternalIdentifier { | ||
@XmlElement(name = "put-code", namespace = "http://www.orcid.org/ns/activities") | ||
private Long putCode; | ||
@XmlElement(name = "external-id-type", namespace = "http://www.orcid.org/ns/activities") | ||
private String externalIdType; | ||
@XmlElement(name = "external-id-value", namespace = "http://www.orcid.org/ns/activities") | ||
private String externalIdValue; | ||
@XmlElement(name = "external-id-url", namespace = "http://www.orcid.org/ns/activities") | ||
private String externalIdUrl; | ||
@XmlElement(name = "validated", namespace = "http://www.orcid.org/ns/activities") | ||
private boolean validated; | ||
|
||
public Long getPutCode() { | ||
return putCode; | ||
} | ||
|
||
public void setPutCode(Long putCode) { | ||
this.putCode = putCode; | ||
} | ||
|
||
public String getExternalIdType() { | ||
return externalIdType; | ||
} | ||
|
||
public void setExternalIdType(String externalIdType) { | ||
this.externalIdType = externalIdType; | ||
} | ||
|
||
public String getExternalIdValue() { | ||
return externalIdValue; | ||
} | ||
|
||
public void setExternalIdValue(String externalIdValue) { | ||
this.externalIdValue = externalIdValue; | ||
} | ||
|
||
public String getExternalIdUrl() { | ||
return externalIdUrl; | ||
} | ||
|
||
public void setExternalIdUrl(String externalIdUrl) { | ||
this.externalIdUrl = externalIdUrl; | ||
} | ||
|
||
public boolean isValidated() { | ||
return validated; | ||
} | ||
|
||
public void setValidated(boolean validated) { | ||
this.validated = validated; | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(externalIdType, externalIdUrl, externalIdValue, putCode, validated); | ||
} | ||
|
||
@Override | ||
public boolean equals(Object obj) { | ||
if (this == obj) | ||
return true; | ||
if (obj == null) | ||
return false; | ||
if (getClass() != obj.getClass()) | ||
return false; | ||
ExternalIdentifier other = (ExternalIdentifier) obj; | ||
return Objects.equals(externalIdType, other.externalIdType) && Objects.equals(externalIdUrl, other.externalIdUrl) | ||
&& Objects.equals(externalIdValue, other.externalIdValue) && Objects.equals(putCode, other.putCode) && validated == other.validated; | ||
} | ||
|
||
} |
46 changes: 46 additions & 0 deletions
46
orcid-api-web/src/main/java/org/orcid/api/member/model/ExternalIdentifiers.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,46 @@ | ||
package org.orcid.api.member.model; | ||
|
||
import java.util.List; | ||
import java.util.Objects; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElement; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
import io.swagger.v3.oas.annotations.media.Schema; | ||
|
||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(propOrder = { "externalIdentifiers" }) | ||
@XmlRootElement(name = "external-identifiers", namespace = "http://www.orcid.org/ns/summary") | ||
@Schema(description = "External identifiers list") | ||
public class ExternalIdentifiers { | ||
@XmlElement(name = "external-identifier", namespace = "http://www.orcid.org/ns/activities") | ||
List<ExternalIdentifier> externalIdentifiers; | ||
|
||
public List<ExternalIdentifier> getExternalIdentifiers() { | ||
return externalIdentifiers; | ||
} | ||
|
||
public void setExternalIdentifiers(List<ExternalIdentifier> externalIdentifiers) { | ||
this.externalIdentifiers = externalIdentifiers; | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(externalIdentifiers); | ||
} | ||
|
||
@Override | ||
public boolean equals(Object obj) { | ||
if (this == obj) | ||
return true; | ||
if (obj == null) | ||
return false; | ||
if (getClass() != obj.getClass()) | ||
return false; | ||
ExternalIdentifiers other = (ExternalIdentifiers) obj; | ||
return Objects.equals(externalIdentifiers, other.externalIdentifiers); | ||
} | ||
} |
11 changes: 11 additions & 0 deletions
11
orcid-api-web/src/main/java/org/orcid/api/member/model/Fundings.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,11 @@ | ||
package org.orcid.api.member.model; | ||
|
||
import javax.xml.bind.annotation.XmlRootElement; | ||
|
||
import io.swagger.v3.oas.annotations.media.Schema; | ||
|
||
@XmlRootElement(name = "fundings", namespace = "http://www.orcid.org/ns/summary") | ||
@Schema(description = "Fundings") | ||
public class Fundings extends ItemsCount { | ||
|
||
} |
53 changes: 53 additions & 0 deletions
53
orcid-api-web/src/main/java/org/orcid/api/member/model/ItemsCount.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,53 @@ | ||
package org.orcid.api.member.model; | ||
|
||
import java.util.Objects; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElement; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
import io.swagger.v3.oas.annotations.media.Schema; | ||
|
||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(propOrder = { "selfAssertedCount", "validatedCount" }) | ||
@Schema(description = "Items count abstract class") | ||
public abstract class ItemsCount { | ||
@XmlElement(name = "self-asserted-count", namespace = "http://www.orcid.org/ns/summary") | ||
private Integer selfAssertedCount; | ||
@XmlElement(name = "validated-count", namespace = "http://www.orcid.org/ns/summary") | ||
private Integer validatedCount; | ||
|
||
public Integer getSelfAssertedCount() { | ||
return selfAssertedCount; | ||
} | ||
|
||
public void setSelfAssertedCount(Integer selfAssertedCount) { | ||
this.selfAssertedCount = selfAssertedCount; | ||
} | ||
|
||
public Integer getValidatdeCount() { | ||
return validatedCount; | ||
} | ||
|
||
public void setValidatedCount(Integer validatedCount) { | ||
this.validatedCount = validatedCount; | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(selfAssertedCount, validatedCount); | ||
} | ||
|
||
@Override | ||
public boolean equals(Object obj) { | ||
if (this == obj) | ||
return true; | ||
if (obj == null) | ||
return false; | ||
if (getClass() != obj.getClass()) | ||
return false; | ||
ItemsCount other = (ItemsCount) obj; | ||
return Objects.equals(selfAssertedCount, other.selfAssertedCount) && Objects.equals(validatedCount, other.validatedCount); | ||
} | ||
} |
Oops, something went wrong.