Skip to content

Commit

Permalink
Added CandidateAvailability entity class (#374)
Browse files Browse the repository at this point in the history
* add: CandidateAvailability Entity
  • Loading branch information
MohamedMahmoud299 authored Apr 28, 2022
1 parent 9a8db49 commit 2259f0d
Show file tree
Hide file tree
Showing 8 changed files with 503 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<groupId>com.bullhorn</groupId>
<artifactId>sdk-rest</artifactId>
<version>1.4.37</version>
<version>1.4.38</version>
<packaging>jar</packaging>

<name>Bullhorn REST SDK</name>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -677,6 +677,8 @@ public class MockDataLoader {
entityFiles.put(StateTaxForm.class, "onboarding365/statetaxform-data.txt");
entityFiles.put(FederalTaxForm.class, "onboarding365/federaltaxform-data.txt");

entityFiles.put(CandidateAvailability.class, "candidateavailability-data.txt");

return entityFiles;
}

Expand Down Expand Up @@ -926,6 +928,8 @@ public class MockDataLoader {
entityMetaFiles.put(StateTaxForm.class, "meta/onboarding365/statetaxform-meta-data.txt");
entityMetaFiles.put(FederalTaxForm.class, "meta/onboarding365/federaltaxform-meta-data.txt");

entityMetaFiles.put(CandidateAvailability.class, "meta/candidateavailability-meta-data.txt");

return entityMetaFiles;
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
package com.bullhornsdk.data.model.entity.core.standard;


import com.bullhornsdk.data.model.entity.core.type.CreateEntity;
import com.bullhornsdk.data.model.entity.core.type.EditHistoryEntity;
import com.bullhornsdk.data.model.entity.core.type.QueryEntity;
import com.bullhornsdk.data.model.entity.core.type.UpdateEntity;
import com.bullhornsdk.data.model.entity.customfields.CustomFieldsA;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.annotation.JsonRootName;
import org.joda.time.DateTime;

import java.util.Objects;

@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonRootName(value = "data")
@JsonPropertyOrder({ "id", "candidate", "dateAdded", "endTime", "isAvailable", "startTime", "type"})

public class CandidateAvailability implements QueryEntity, UpdateEntity, CreateEntity {

private Integer id;
private Candidate candidate;
private DateTime dateAdded;
private DateTime endTime;
private Boolean isAvailable;
private DateTime startTime;
private String type;

@Override
@JsonProperty("id")
public Integer getId() {
return id;
}

@Override
@JsonProperty("id")
public void setId(Integer id) {
this.id = id;
}

@JsonProperty("candidate")
public Candidate getCandidate() {
return candidate;
}

@JsonProperty("candidate")
public void setCandidate(Candidate candidate) {
this.candidate = candidate;
}

@JsonProperty("dateAdded")
public DateTime getDateAdded() {
return dateAdded;
}
@JsonProperty("dateAdded")
public void setDateAdded(DateTime dateAdded) {
this.dateAdded = dateAdded;
}
@JsonProperty("endTime")
public DateTime getEndTime() {
return endTime;
}
@JsonProperty("endTime")
public void setEndTime(DateTime endTime) {
this.endTime = endTime;
}
@JsonProperty("isAvailable")
public Boolean getIsAvailable() {
return isAvailable;
}
@JsonProperty("isAvailable")
public void setIsAvailable(Boolean available) {
isAvailable = available;
}
@JsonProperty("startTime")
public DateTime getStartTime() {
return startTime;
}
@JsonProperty("startTime")
public void setStartTime(DateTime startTime) {
this.startTime = startTime;
}
@JsonProperty("type")
public String getType() {
return type;
}
@JsonProperty("type")
public void setType(String type) {
this.type = type;
}

@Override
public String toString() {
return "CandidateAvailability{" +
"id=" + id +
", candidate=" + candidate +
", dateAdded=" + dateAdded +
", endTime=" + endTime +
", isAvailable=" + isAvailable +
", startTime=" + startTime +
", type='" + type + '\'' +
'}';
}

@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
CandidateAvailability that = (CandidateAvailability) o;
return Objects.equals(id, that.id) && Objects.equals(candidate, that.candidate) && Objects.equals(dateAdded, that.dateAdded) && Objects.equals(endTime, that.endTime) && Objects.equals(isAvailable, that.isAvailable) && Objects.equals(startTime, that.startTime) && Objects.equals(type, that.type);
}

@Override
public int hashCode() {
return Objects.hash(id, candidate, dateAdded, endTime, isAvailable, startTime, type);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@ public enum BullhornEntityInfo {
CandidateReferenceListWrapper.class, null, null),
CANDIDATE_WORK_HISTORY("CandidateWorkHistory", CandidateWorkHistory.class, CandidateWorkHistoryWrapper.class,
CandidateWorkHistoryListWrapper.class, null, null),
CANDIDATE_AVAILABILITY("CandidateAvailability", CandidateAvailability.class, CandidateAvailabilityWrapper.class, CandidateAvailabilityListWrapper.class, null, null),
CATEGORY("Category", Category.class, CategoryWrapper.class, CategoryListWrapper.class, null, null),
CERTIFICATION("Certification", Certification.class, CertificationWrapper.class, CertificationListWrapper.class, null, null),
CERTIFICATIONGROUP("CertificationGroup", CertificationGroup.class, CertificationGroupWrapper.class, CertificationGroupListWrapper.class, null, null),
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package com.bullhornsdk.data.model.response.list;

import com.bullhornsdk.data.model.entity.core.standard.CandidateAvailability;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;

@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonPropertyOrder({ "data", "count", "start" })
public class CandidateAvailabilityListWrapper extends StandardListWrapper<CandidateAvailability> {

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package com.bullhornsdk.data.model.response.single;

import com.bullhornsdk.data.model.entity.core.standard.CandidateAvailability;

public class CandidateAvailabilityWrapper extends StandardWrapper<CandidateAvailability> {

}
Loading

0 comments on commit 2259f0d

Please sign in to comment.