Rev 24171 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed
package com.spice.profitmandi.dao.entity.fofo;import java.time.LocalDateTime;import javax.persistence.Column;import javax.persistence.Convert;import javax.persistence.Entity;import javax.persistence.GeneratedValue;import javax.persistence.GenerationType;import javax.persistence.Id;import javax.persistence.Table;import com.spice.profitmandi.dao.convertor.LocalDateTimeAttributeConverter;@Entity@Table(name="fofo.partner_target",schema="fofo")public class PartnerTarget {@Id@Column(name="id")@GeneratedValue(strategy = GenerationType.IDENTITY)private int id;@Column(name="fofo_id")private int fofoId;@Column(name="target_value")private float targetValue;@Convert(converter = LocalDateTimeAttributeConverter.class)@Column(name="target_month")private LocalDateTime targetMonth;public int getId() {return id;}public void setId(int id) {this.id = id;}public int getFofoId() {return fofoId;}public void setFofoId(int fofoId) {this.fofoId = fofoId;}public float getTargetValue() {return targetValue;}public void setTargetValue(float targetValue) {this.targetValue = targetValue;}public LocalDateTime getTargetMonth() {return targetMonth;}public void setTargetMonth(LocalDateTime targetMonth) {this.targetMonth = targetMonth;}@Overridepublic int hashCode() {final int prime = 31;int result = 1;result = prime * result + fofoId;result = prime * result + id;result = prime * result + ((targetMonth == null) ? 0 : targetMonth.hashCode());result = prime * result + Float.floatToIntBits(targetValue);return result;}@Overridepublic boolean equals(Object obj) {if (this == obj)return true;if (obj == null)return false;if (getClass() != obj.getClass())return false;PartnerTarget other = (PartnerTarget) obj;if (fofoId != other.fofoId)return false;if (id != other.id)return false;if (targetMonth == null) {if (other.targetMonth != null)return false;} else if (!targetMonth.equals(other.targetMonth))return false;if (Float.floatToIntBits(targetValue) != Float.floatToIntBits(other.targetValue))return false;return true;}@Overridepublic String toString() {return "PartnerTarget [id=" + id + ", fofoId=" + fofoId + ", targetValue=" + targetValue + ", targetMonth="+ targetMonth + "]";}}