Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
25880 amit.gupta 1
package com.spice.profitmandi.service.inventory;
21339 kshitij.so 2
 
26665 amit.gupta 3
import java.util.Arrays;
4
 
21339 kshitij.so 5
public class AvailabilityInfo
6
{
7
    private BulkPricing[] bulkPricing;
8
    private double sellingPrice;
9
    private String color;
10
    private long item_id;
11
    private String sellingPriceType;
12
    private double netPriceAfterCashBack;
13
    private double cash_back;
14
    private int maxQuantity;
15
    private int cash_back_type;
16
    private int quantityStep;
17
    private int availability;
18
    private int minBuyQuantity;
26665 amit.gupta 19
    private double mrp;
21339 kshitij.so 20
 
26665 amit.gupta 21
	@Override
22
	public String toString() {
23
		return "AvailabilityInfo [bulkPricing=" + Arrays.toString(bulkPricing) + ", sellingPrice=" + sellingPrice
24
				+ ", color=" + color + ", item_id=" + item_id + ", sellingPriceType=" + sellingPriceType
25
				+ ", netPriceAfterCashBack=" + netPriceAfterCashBack + ", cash_back=" + cash_back + ", maxQuantity="
26
				+ maxQuantity + ", cash_back_type=" + cash_back_type + ", quantityStep=" + quantityStep
27
				+ ", availability=" + availability + ", minBuyQuantity=" + minBuyQuantity + ", mrp=" + mrp + "]";
28
	}
21339 kshitij.so 29
	public BulkPricing[] getBulkPricing() {
30
		return bulkPricing;
31
	}
26665 amit.gupta 32
	public double getMrp() {
33
		return mrp;
34
	}
35
	public void setMrp(double mrp) {
36
		this.mrp = mrp;
37
	}
21339 kshitij.so 38
	public void setBulkPricing(BulkPricing[] bulkPricing) {
39
		this.bulkPricing = bulkPricing;
40
	}
41
	public double getSellingPrice() {
42
		return sellingPrice;
43
	}
44
	public void setSellingPrice(double sellingPrice) {
45
		this.sellingPrice = sellingPrice;
46
	}
47
	public String getColor() {
48
		return color;
49
	}
50
	public void setColor(String color) {
51
		this.color = color;
52
	}
53
	public long getItem_id() {
54
		return item_id;
55
	}
56
	public void setItem_id(long item_id) {
57
		this.item_id = item_id;
58
	}
59
	public String getSellingPriceType() {
60
		return sellingPriceType;
61
	}
62
	public void setSellingPriceType(String sellingPriceType) {
63
		this.sellingPriceType = sellingPriceType;
64
	}
65
	public double getNetPriceAfterCashBack() {
66
		return netPriceAfterCashBack;
67
	}
68
	public void setNetPriceAfterCashBack(double netPriceAfterCashBack) {
69
		this.netPriceAfterCashBack = netPriceAfterCashBack;
70
	}
71
	public double getCash_back() {
72
		return cash_back;
73
	}
74
	public void setCash_back(double cash_back) {
75
		this.cash_back = cash_back;
76
	}
77
	public int getMaxQuantity() {
78
		return maxQuantity;
79
	}
80
	public void setMaxQuantity(int maxQuantity) {
81
		this.maxQuantity = maxQuantity;
82
	}
83
	public int getCash_back_type() {
84
		return cash_back_type;
85
	}
86
	public void setCash_back_type(int cash_back_type) {
87
		this.cash_back_type = cash_back_type;
88
	}
89
	public int getQuantityStep() {
90
		return quantityStep;
91
	}
92
	public void setQuantityStep(int quantityStep) {
93
		this.quantityStep = quantityStep;
94
	}
95
	public int getAvailability() {
96
		return availability;
97
	}
98
	public void setAvailability(int availability) {
99
		this.availability = availability;
100
	}
101
	public int getMinBuyQuantity() {
102
		return minBuyQuantity;
103
	}
104
	public void setMinBuyQuantity(int minBuyQuantity) {
105
		this.minBuyQuantity = minBuyQuantity;
106
	}
26665 amit.gupta 107
	@Override
108
	public int hashCode() {
109
		final int prime = 31;
110
		int result = 1;
111
		result = prime * result + availability;
112
		result = prime * result + Arrays.hashCode(bulkPricing);
113
		long temp;
114
		temp = Double.doubleToLongBits(cash_back);
115
		result = prime * result + (int) (temp ^ (temp >>> 32));
116
		result = prime * result + cash_back_type;
117
		result = prime * result + ((color == null) ? 0 : color.hashCode());
118
		result = prime * result + (int) (item_id ^ (item_id >>> 32));
119
		result = prime * result + maxQuantity;
120
		result = prime * result + minBuyQuantity;
121
		temp = Double.doubleToLongBits(mrp);
122
		result = prime * result + (int) (temp ^ (temp >>> 32));
123
		temp = Double.doubleToLongBits(netPriceAfterCashBack);
124
		result = prime * result + (int) (temp ^ (temp >>> 32));
125
		result = prime * result + quantityStep;
126
		temp = Double.doubleToLongBits(sellingPrice);
127
		result = prime * result + (int) (temp ^ (temp >>> 32));
128
		result = prime * result + ((sellingPriceType == null) ? 0 : sellingPriceType.hashCode());
129
		return result;
130
	}
131
	@Override
132
	public boolean equals(Object obj) {
133
		if (this == obj)
134
			return true;
135
		if (obj == null)
136
			return false;
137
		if (getClass() != obj.getClass())
138
			return false;
139
		AvailabilityInfo other = (AvailabilityInfo) obj;
140
		if (availability != other.availability)
141
			return false;
142
		if (!Arrays.equals(bulkPricing, other.bulkPricing))
143
			return false;
144
		if (Double.doubleToLongBits(cash_back) != Double.doubleToLongBits(other.cash_back))
145
			return false;
146
		if (cash_back_type != other.cash_back_type)
147
			return false;
148
		if (color == null) {
149
			if (other.color != null)
150
				return false;
151
		} else if (!color.equals(other.color))
152
			return false;
153
		if (item_id != other.item_id)
154
			return false;
155
		if (maxQuantity != other.maxQuantity)
156
			return false;
157
		if (minBuyQuantity != other.minBuyQuantity)
158
			return false;
159
		if (Double.doubleToLongBits(mrp) != Double.doubleToLongBits(other.mrp))
160
			return false;
161
		if (Double.doubleToLongBits(netPriceAfterCashBack) != Double.doubleToLongBits(other.netPriceAfterCashBack))
162
			return false;
163
		if (quantityStep != other.quantityStep)
164
			return false;
165
		if (Double.doubleToLongBits(sellingPrice) != Double.doubleToLongBits(other.sellingPrice))
166
			return false;
167
		if (sellingPriceType == null) {
168
			if (other.sellingPriceType != null)
169
				return false;
170
		} else if (!sellingPriceType.equals(other.sellingPriceType))
171
			return false;
172
		return true;
173
	}
174
 
175
 
21339 kshitij.so 176
 
177
 
178
}