| .. | .. |
|---|
| 5 | 5 | |
|---|
| 6 | 6 | import javax.persistence.Column; |
|---|
| 7 | 7 | import javax.persistence.Entity; |
|---|
| 8 | | -import javax.persistence.GeneratedValue; |
|---|
| 9 | 8 | import javax.persistence.Id; |
|---|
| 10 | 9 | import javax.persistence.JoinColumn; |
|---|
| 11 | 10 | import javax.persistence.ManyToOne; |
|---|
| .. | .. |
|---|
| 13 | 12 | import javax.persistence.NamedQuery; |
|---|
| 14 | 13 | import javax.persistence.Table; |
|---|
| 15 | 14 | |
|---|
| 16 | | -import org.codehaus.jackson.annotate.JsonAutoDetect; |
|---|
| 17 | | -import org.codehaus.jackson.annotate.JsonIgnore; |
|---|
| 18 | | -import org.codehaus.jackson.annotate.JsonProperty; |
|---|
| 19 | | -import org.codehaus.jackson.map.annotate.JsonSerialize; |
|---|
| 15 | +import com.fasterxml.jackson.annotation.JsonAutoDetect; |
|---|
| 16 | +import com.fasterxml.jackson.annotation.JsonIgnore; |
|---|
| 17 | +import com.fasterxml.jackson.annotation.JsonInclude; |
|---|
| 18 | +import com.fasterxml.jackson.annotation.JsonInclude.Include; |
|---|
| 19 | +import com.fasterxml.jackson.annotation.JsonProperty; |
|---|
| 20 | 20 | |
|---|
| 21 | 21 | /** |
|---|
| 22 | 22 | * Entity implementation class for Entity: application_metadata |
|---|
| 23 | 23 | * |
|---|
| 24 | 24 | */ |
|---|
| 25 | 25 | @JsonAutoDetect |
|---|
| 26 | | -@JsonSerialize(include = JsonSerialize.Inclusion.NON_NULL) |
|---|
| 26 | +@JsonInclude(Include.NON_NULL) |
|---|
| 27 | 27 | @Entity |
|---|
| 28 | 28 | @Table(name = "application_metadata") |
|---|
| 29 | 29 | @NamedQueries({ |
|---|
| .. | .. |
|---|
| 49 | 49 | @Column(name = "creation_timestamp") |
|---|
| 50 | 50 | private Date creationTimestamp; |
|---|
| 51 | 51 | |
|---|
| 52 | | - |
|---|
| 53 | 52 | public String getKey() { |
|---|
| 54 | 53 | return key; |
|---|
| 55 | 54 | } |
|---|
| .. | .. |
|---|
| 73 | 72 | public void setCreationTimestamp(Date creationTimestamp) { |
|---|
| 74 | 73 | this.creationTimestamp = creationTimestamp; |
|---|
| 75 | 74 | } |
|---|
| 76 | | - |
|---|
| 77 | 75 | |
|---|
| 78 | 76 | @JsonProperty("application_id") |
|---|
| 79 | 77 | public Integer getApplicationId() { |
|---|
| .. | .. |
|---|
| 105 | 103 | public void setMandatory(boolean mandatory) { |
|---|
| 106 | 104 | this.mandatory = mandatory; |
|---|
| 107 | 105 | } |
|---|
| 108 | | - |
|---|
| 106 | + |
|---|
| 109 | 107 | @Override |
|---|
| 110 | 108 | public boolean equals(Object obj) { |
|---|
| 111 | 109 | if (!(obj instanceof ApplicationMetadata)) |
|---|
| 112 | 110 | return false; |
|---|
| 113 | | - ApplicationMetadata other = (ApplicationMetadata)obj; |
|---|
| 111 | + ApplicationMetadata other = (ApplicationMetadata) obj; |
|---|
| 114 | 112 | return key.equals(other.key) && (application == null || application.equals(other.application)); |
|---|
| 115 | 113 | } |
|---|
| 116 | | - |
|---|
| 114 | + |
|---|
| 117 | 115 | @Override |
|---|
| 118 | 116 | public int hashCode() { |
|---|
| 119 | | - |
|---|
| 117 | + |
|---|
| 120 | 118 | return key.hashCode() + (application == null ? 0 : application.hashCode()); |
|---|
| 121 | 119 | } |
|---|
| 122 | 120 | |
|---|