Subversion Repositories SmartDukaan

Rev

Rev 22009 | Rev 30220 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
21715 ashik.ali 1
package com.spice.profitmandi.dao.entity.logistics;
21545 ashik.ali 2
 
3
import java.io.Serializable;
4
 
5
import javax.persistence.Column;
6
import javax.persistence.Entity;
7
import javax.persistence.GeneratedValue;
8
import javax.persistence.GenerationType;
9
import javax.persistence.Id;
10
import javax.persistence.Table;
11
 
12
/**
13
 * This class basically contains address details
14
 * 
15
 * @author ashikali
16
 *
17
 */
18
@Entity
19
@Table(name="logistics.provider", schema = "logistics")
20
public class Provider implements Serializable{
21
 
22
	private static final long serialVersionUID = 1L;
23
 
24
	public Provider() {
25
	}
26
 
27
	@Id
28
	@Column(name="id", unique=true, updatable=false)
29
	@GeneratedValue(strategy = GenerationType.IDENTITY)
30
	private int id;
31
 
32
	@Column(name="name", length = 100)
33
	private String name;
34
 
35
	@Column(name = "isActive", columnDefinition = "tinyint(1) default 1")
36
	private boolean active;
37
 
38
	@Column(name = "pickup")
39
	private int pickup;
40
 
41
	@Column(name = "bundleWeightLimit")
42
	private float bundleWeightLimit;
43
 
44
	@Column(name = "groupShipmentAllowed", columnDefinition = "tinyint(1) default 0")
45
	private boolean groupShipmentAllowed;
46
 
47
	@Column(name = "maxCodLimit")
48
	private float maxCODLimit;
49
 
50
 
51
	public int getId() {
52
		return id;
53
	}
54
	public void setId(int id) {
55
		this.id = id;
56
	}
57
	public void setName(String name) {
58
        this.name = name;
59
    }
60
    public String getName() {
61
        return name;
62
    }
29222 tejbeer 63
 
64
	public boolean isActive() {
21545 ashik.ali 65
		return active;
66
	}
67
    public void setActive(boolean active) {
68
		this.active = active;
69
	}
70
 
71
    public int getPickup() {
72
		return pickup;
73
	}
74
    public void setPickup(int pickup) {
75
		this.pickup = pickup;
76
	}
77
    public float getBundleWeightLimit() {
78
		return bundleWeightLimit;
79
	}
80
    public void setBundleWeightLimit(float bundleWeightLimit) {
81
		this.bundleWeightLimit = bundleWeightLimit;
82
	}
83
 
84
    public boolean isGroupShipmentAllowed() {
85
		return groupShipmentAllowed;
86
	}
87
    public void setGroupShipmentAllowed(boolean groupShipmentAllowed) {
88
		this.groupShipmentAllowed = groupShipmentAllowed;
89
	}
90
    public float getMaxCODLimit() {
91
		return maxCODLimit;
92
	}
93
    public void setMaxCODLimit(float maxCODLimit) {
94
		this.maxCODLimit = maxCODLimit;
95
	}
21924 ashik.ali 96
 
21602 ashik.ali 97
	@Override
21924 ashik.ali 98
	public int hashCode() {
99
		final int prime = 31;
100
		int result = 1;
101
		result = prime * result + id;
102
		return result;
103
	}
104
	@Override
105
	public boolean equals(Object obj) {
106
		if (this == obj)
107
			return true;
108
		if (obj == null)
109
			return false;
110
		if (getClass() != obj.getClass())
111
			return false;
112
		Provider other = (Provider) obj;
113
		if (id != other.id)
114
			return false;
115
		return true;
116
	}
117
	@Override
21602 ashik.ali 118
	public String toString() {
119
		return "Provider [id=" + id + ", name=" + name + ", active=" + active + ", pickup=" + pickup
120
				+ ", bundleWeightLimit=" + bundleWeightLimit + ", groupShipmentAllowed=" + groupShipmentAllowed
121
				+ ", maxCODLimit=" + maxCODLimit + "]";
122
	}
21545 ashik.ali 123
 
124
 
21602 ashik.ali 125
 
21545 ashik.ali 126
}