Subversion Repositories SmartDukaan

Rev

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