Subversion Repositories SmartDukaan

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
33124 ranu 1
package com.spice.profitmandi.dao.entity.logistics;
2
 
3
import javax.persistence.Column;
4
import javax.persistence.Entity;
5
import javax.persistence.Id;
6
import javax.persistence.Table;
7
import java.io.Serializable;
8
import java.util.Objects;
9
 
10
/**
11
 * This class basically contains api details
12
 *
13
 * @author Ranu Rajput
14
 */
15
@Entity
16
@Table(name = "inventory.area", schema = "logistics")
17
public class Area implements Serializable {
18
 
19
    @Id
20
    @Column(name = "name", unique = true, updatable = false)
21
    private String name;
22
    @Column(name = "description")
23
    private String description;
24
 
25
    public Area() {
26
    }
27
 
28
    public String getName() {
29
        return name;
30
    }
31
 
32
    public void setName(String name) {
33
        name = name;
34
    }
35
 
36
    public String getDescription() {
37
        return description;
38
    }
39
 
40
    public void setDescription(String description) {
41
        this.description = description;
42
    }
43
 
44
    @Override
45
    public String toString() {
46
        return "Area{" +
47
                "name='" + name + '\'' +
48
                ", description='" + description + '\'' +
49
                '}';
50
    }
51
 
52
    @Override
53
    public boolean equals(Object o) {
54
        if (this == o) return true;
55
        if (o == null || getClass() != o.getClass()) return false;
56
        Area area = (Area) o;
57
        return Objects.equals(name, area.name) && Objects.equals(description, area.description);
58
    }
59
 
60
    @Override
61
    public int hashCode() {
62
        return Objects.hash(name, description);
63
    }
64
}