Subversion Repositories SmartDukaan

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
21602 ashik.ali 1
package com.spice.profitmandi.dao.entity;
2
 
3
import java.io.Serializable;
4
import java.time.LocalDateTime;
5
 
6
import javax.persistence.Column;
7
import javax.persistence.Entity;
8
import javax.persistence.GeneratedValue;
9
import javax.persistence.GenerationType;
10
import javax.persistence.Id;
11
import javax.persistence.NamedQueries;
12
import javax.persistence.NamedQuery;
13
import javax.persistence.Table;
14
 
15
/**
16
 * This class basically contains api details
17
 * 
18
 * @author ashikali
19
 *
20
 */
21
@Entity
22
@Table(name="fofo.customer", schema = "fofo")
23
@NamedQueries({
24
	@NamedQuery(name="Customer.selectById",query="select c from Customer c where c.id= :id")
25
})
26
public class Customer implements Serializable{
27
 
28
	private static final long serialVersionUID = 1L;
29
 
30
	public Customer() {
31
	}
32
 
33
	@Id
34
	@Column(name="id")
35
	@GeneratedValue(strategy = GenerationType.IDENTITY)
36
	private int id;
37
 
38
	@Column(name="email_id", length = 20)
39
	private String emailId;
40
 
41
	@Column(name="mobile_number", length = 20)
42
	private String mobileNumber;
43
 
44
	@Column(name="address1", length = 50)
45
	private String address1;
46
 
47
	@Column(name="address2", length = 50)
48
	private String address2;
49
 
50
	@Column(name="city", length = 50)
51
	private String city;
52
 
53
	@Column(name="state", length = 50)
54
	private String state;
55
 
56
	@Column(name = "pin_code")
57
	private String pinCode;
58
 
59
	@Column(name = "createTimestamp")
60
	private LocalDateTime createTimestamp = LocalDateTime.now();
61
 
62
	public int getId() {
63
		return id;
64
	}
65
	public void setId(int id) {
66
		this.id = id;
67
	}
68
 
69
	public String getEmailId() {
70
		return emailId;
71
	}
72
	public void setEmailId(String emailId) {
73
		this.emailId = emailId;
74
	}
75
 
76
	public String getMobileNumber() {
77
		return mobileNumber;
78
	}
79
	public void setMobileNumber(String mobileNumber) {
80
		this.mobileNumber = mobileNumber;
81
	}
82
 
83
	public String getAddress1() {
84
		return address1;
85
	}
86
	public void setAddress1(String address1) {
87
		this.address1 = address1;
88
	}
89
	public String getAddress2() {
90
		return address2;
91
	}
92
	public void setAddress2(String address2) {
93
		this.address2 = address2;
94
	}
95
 
96
	public String getCity() {
97
		return city;
98
	}
99
	public void setCity(String city) {
100
		this.city = city;
101
	}
102
	public String getState() {
103
		return state;
104
	}
105
	public void setState(String state) {
106
		this.state = state;
107
	}
108
	public String getPinCode() {
109
		return pinCode;
110
	}
111
	public void setPinCode(String pinCode) {
112
		this.pinCode = pinCode;
113
	}
114
	@Override
115
	public String toString() {
116
		return "Customer [id=" + id + ", emailId=" + emailId + ", mobileNumber=" + mobileNumber + ", address1="
117
				+ address1 + ", address2=" + address2 + ", city=" + city + ", state=" + state + ", pinCode=" + pinCode
118
				+ ", createTimestamp=" + createTimestamp + "]";
119
	}
120
 
121
 
122
 
123
}