Subversion Repositories SmartDukaan

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
24135 govind 1
package com.spice.profitmandi.dao.entity.fofo;
2
 
3
import javax.persistence.Column;
4
import javax.persistence.Entity;
5
import javax.persistence.GeneratedValue;
6
import javax.persistence.GenerationType;
7
import javax.persistence.Id;
8
import javax.persistence.Table;
9
@Entity
10
@Table(name="fofo.sales_head_details",schema="fofo")
11
public class SaleHeadDetails {
12
 
13
 
14
	@Id
15
	@Column(name="id")
16
	@GeneratedValue(strategy = GenerationType.IDENTITY)
17
	private int id;
18
 
19
	@Column(name="sales_head_name")
20
	private String name;
21
 
22
	@Column(name ="sales_head_email")
23
	private String email;
24
 
25
	@Override
26
	public int hashCode() {
27
		final int prime = 31;
28
		int result = 1;
29
		result = prime * result + ((email == null) ? 0 : email.hashCode());
30
		result = prime * result + id;
31
		result = prime * result + ((name == null) ? 0 : name.hashCode());
32
		return result;
33
	}
34
 
35
	@Override
36
	public boolean equals(Object obj) {
37
		if (this == obj)
38
			return true;
39
		if (obj == null)
40
			return false;
41
		if (getClass() != obj.getClass())
42
			return false;
43
		SaleHeadDetails other = (SaleHeadDetails) obj;
44
		if (email == null) {
45
			if (other.email != null)
46
				return false;
47
		} else if (!email.equals(other.email))
48
			return false;
49
		if (id != other.id)
50
			return false;
51
		if (name == null) {
52
			if (other.name != null)
53
				return false;
54
		} else if (!name.equals(other.name))
55
			return false;
56
		return true;
57
	}
58
 
59
	public int getId() {
60
		return id;
61
	}
62
 
63
	public void setId(int id) {
64
		this.id = id;
65
	}
66
 
67
	public String getName() {
68
		return name;
69
	}
70
 
71
	public void setName(String name) {
72
		this.name = name;
73
	}
74
 
75
	public String getEmail() {
76
		return email;
77
	}
78
 
79
	public void setEmail(String email) {
80
		this.email = email;
81
	}
82
 
83
	@Override
84
	public String toString() {
85
		return "SaleHeadDetails [id=" + id + ", name=" + name + ", email=" + email + "]";
86
	}
87
}