Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
21720 ashik.ali 1
package com.spice.profitmandi.dao.entity.dtr;
21545 ashik.ali 2
 
3
import javax.persistence.Entity;
4
import javax.persistence.EnumType;
5
import javax.persistence.Enumerated;
6
import javax.persistence.GeneratedValue;
7
import javax.persistence.GenerationType;
8
import javax.persistence.Id;
9
import javax.persistence.Table;
10
 
21720 ashik.ali 11
import com.spice.profitmandi.dao.enumuration.dtr.AccountType;
21545 ashik.ali 12
 
13
@Entity
21720 ashik.ali 14
@Table(name="dtr.user_accounts",schema="dtr")
21545 ashik.ali 15
public class UserAccounts{
16
	/**
17
	 * 
18
	 */	
19
	@Id
20
	@GeneratedValue(strategy=GenerationType.IDENTITY)
21
	private int id;
22
	private int user_id;
22352 ashik.ali 23
 
21545 ashik.ali 24
	@Enumerated(EnumType.STRING)
25
	private AccountType account_type ;
22352 ashik.ali 26
 
21545 ashik.ali 27
	private String account_key;
28
 
22352 ashik.ali 29
 
21545 ashik.ali 30
	public int getId() {
31
		return id;
32
	}
33
	public void setId(int id) {
34
		this.id = id;
35
	}
36
	public int getUser_id() {
37
		return user_id;
38
	}
39
	public void setUser_id(int user_id) {
40
		this.user_id = user_id;
41
	}
42
	public AccountType getAccount_type() {
43
		return account_type;
44
	}
45
	public void setAccount_type(AccountType account_type) {
46
		this.account_type = account_type;
47
	}
48
	public String getAccount_key() {
49
		return account_key;
50
	}
51
	public void setAccount_key(String account_key) {
52
		this.account_key = account_key;
53
	}
21924 ashik.ali 54
 
55
 
21602 ashik.ali 56
	@Override
21924 ashik.ali 57
	public int hashCode() {
58
		final int prime = 31;
59
		int result = 1;
60
		result = prime * result + id;
61
		return result;
62
	}
63
	@Override
64
	public boolean equals(Object obj) {
65
		if (this == obj)
66
			return true;
67
		if (obj == null)
68
			return false;
69
		if (getClass() != obj.getClass())
70
			return false;
71
		UserAccounts other = (UserAccounts) obj;
72
		if (id != other.id)
73
			return false;
74
		return true;
75
	}
76
	@Override
21602 ashik.ali 77
	public String toString() {
78
		return "UserAccounts [id=" + id + ", user_id=" + user_id + ", account_type=" + account_type + ", account_key="
79
				+ account_key + "]";
80
	}
21545 ashik.ali 81
 
21602 ashik.ali 82
 
21545 ashik.ali 83
}