Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package at.jku.se.healthmanager.domain;
- import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
- import javax.persistence.*;
- import java.io.Serializable;
- import java.time.ZonedDateTime;
- import java.util.Objects;
- import java.util.HashSet;
- import java.util.Collections;
- /**
- * A BloodPressureEntry.
- */
- @Entity
- @Table(name = "blood_pressure_entry")
- public class BloodPressureEntry implements Serializable {
- private static final long serialVersionUID = 1L;
- @Id
- @GeneratedValue(strategy = GenerationType.IDENTITY)
- private Long id;
- @Column(name = "sys_blood")
- private Integer sysBlood;
- @Column(name = "dias_blood")
- private Integer diasBlood;
- @Column(name = "jhi_create")
- private ZonedDateTime create;
- @ManyToOne
- @JsonIgnoreProperties("bloodPressureEntries")
- private BloodPressureData bloodPressureData;
- @OneToOne
- @JoinColumn(unique = true)
- private PulsEntry puls;
- // jhipster-needle-entity-add-field - JHipster will add fields here, do not remove
- public Long getId() {
- return id;
- }
- public void setId(Long id) {
- this.id = id;
- }
- public Integer getSysBlood() {
- return sysBlood;
- }
- public BloodPressureEntry sysBlood(Integer sysBlood) {
- this.sysBlood = sysBlood;
- return this;
- }
- public void setSysBlood(Integer sysBlood) {
- this.sysBlood = sysBlood;
- }
- public Integer getDiasBlood() {
- return diasBlood;
- }
- public BloodPressureEntry diasBlood(Integer diasBlood) {
- this.diasBlood = diasBlood;
- return this;
- }
- public void setDiasBlood(Integer diasBlood) {
- this.diasBlood = diasBlood;
- }
- public ZonedDateTime getCreate() {
- return create;
- }
- public BloodPressureEntry create(ZonedDateTime create) {
- this.create = create;
- return this;
- }
- public void setCreate(ZonedDateTime create) {
- this.create = create;
- }
- public BloodPressureEntry bloodPressureData(BloodPressureData bloodPressureData) {
- this.bloodPressureData = bloodPressureData;
- return this;
- }
- public void setBloodPressureData(BloodPressureData bloodPressureData) {
- this.bloodPressureData = bloodPressureData;
- }
- public PulsEntry getPuls() {
- return puls;
- }
- public BloodPressureEntry puls(PulsEntry pulsEntry) {
- this.puls = pulsEntry;
- return this;
- }
- public void setPuls(PulsEntry pulsEntry) {
- this.puls = pulsEntry;
- }
- // jhipster-needle-entity-add-getters-setters - JHipster will add getters and setters here, do not remove
- @Override
- public boolean equals(Object o) {
- if (this == o) {
- return true;
- }
- if (o == null || getClass() != o.getClass()) {
- return false;
- }
- BloodPressureEntry bloodPressureEntry = (BloodPressureEntry) o;
- if (bloodPressureEntry.getId() == null || getId() == null) {
- return false;
- }
- return Objects.equals(getId(), bloodPressureEntry.getId());
- }
- @Override
- public int hashCode() {
- return Objects.hashCode(getId());
- }
- @Override
- public String toString() {
- return "BloodPressureEntry{" +
- "id=" + getId() +
- ", sysBlood=" + getSysBlood() +
- ", diasBlood=" + getDiasBlood() +
- ", create='" + getCreate() + "'" +
- "}";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement