Subversion Repositories SmartDukaan

Rev

Rev 34163 | Blame | Compare with Previous | Last modification | View Log | RSS feed

package com.spice.profitmandi.service.inventory;

import java.util.Arrays;

public class AvailabilityInfo
{
    private BulkPricing[] bulkPricing;
    private double sellingPrice;
    private String color;
    private long item_id;
        private long catalog_id;
    private String sellingPriceType;
    private double netPriceAfterCashBack;
    private double cash_back;
    private int maxQuantity;
    private int cash_back_type;
    private int quantityStep;
    private int availability;
    private int partnerAvailability;
    private int minBuyQuantity;
    private double mrp;
    
        @Override
        public String toString() {
                return "AvailabilityInfo [bulkPricing=" + Arrays.toString(bulkPricing) + ", sellingPrice=" + sellingPrice
                                + ", color=" + color + ", item_id=" + item_id + ", catalog_id=" + catalog_id + ", sellingPriceType=" + sellingPriceType
                                + ", netPriceAfterCashBack=" + netPriceAfterCashBack + ", cash_back=" + cash_back + ", maxQuantity="
                                + maxQuantity + ", cash_back_type=" + cash_back_type + ", quantityStep=" + quantityStep
                                + ", availability=" + availability + ", minBuyQuantity=" + minBuyQuantity + ", mrp=" + mrp + "]";
        }
        public BulkPricing[] getBulkPricing() {
                return bulkPricing;
        }
        public double getMrp() {
                return mrp;
        }
        public void setMrp(double mrp) {
                this.mrp = mrp;
        }
        public void setBulkPricing(BulkPricing[] bulkPricing) {
                this.bulkPricing = bulkPricing;
        }
        public double getSellingPrice() {
                return sellingPrice;
        }
        public void setSellingPrice(double sellingPrice) {
                this.sellingPrice = sellingPrice;
        }
        public String getColor() {
                return color;
        }
        public void setColor(String color) {
                this.color = color;
        }
        public long getItem_id() {
                return item_id;
        }
        public void setItem_id(long item_id) {
                this.item_id = item_id;
        }
        public String getSellingPriceType() {
                return sellingPriceType;
        }
        public void setSellingPriceType(String sellingPriceType) {
                this.sellingPriceType = sellingPriceType;
        }
        public double getNetPriceAfterCashBack() {
                return netPriceAfterCashBack;
        }
        public void setNetPriceAfterCashBack(double netPriceAfterCashBack) {
                this.netPriceAfterCashBack = netPriceAfterCashBack;
        }
        public double getCash_back() {
                return cash_back;
        }
        public void setCash_back(double cash_back) {
                this.cash_back = cash_back;
        }
        public int getMaxQuantity() {
                return maxQuantity;
        }
        public void setMaxQuantity(int maxQuantity) {
                this.maxQuantity = maxQuantity;
        }
        public int getCash_back_type() {
                return cash_back_type;
        }
        public void setCash_back_type(int cash_back_type) {
                this.cash_back_type = cash_back_type;
        }
        public int getQuantityStep() {
                return quantityStep;
        }
        public void setQuantityStep(int quantityStep) {
                this.quantityStep = quantityStep;
        }
        public int getAvailability() {
                return availability;
        }
        public void setAvailability(int availability) {
                this.availability = availability;
        }
        public int getPartnerAvailability() {
                return partnerAvailability;
        }
        public void setPartnerAvailability(int partnerAvailability) {
                this.partnerAvailability = partnerAvailability;
        }
        public int getMinBuyQuantity() {
                return minBuyQuantity;
        }
        public void setMinBuyQuantity(int minBuyQuantity) {
                this.minBuyQuantity = minBuyQuantity;
        }

        public long getCatalog_id() {
                return catalog_id;
        }

        public void setCatalog_id(long catalog_id) {
                this.catalog_id = catalog_id;
        }

        @Override
        public int hashCode() {
                final int prime = 31;
                int result = 1;
                result = prime * result + availability;
                result = prime * result + Arrays.hashCode(bulkPricing);
                long temp;
                temp = Double.doubleToLongBits(cash_back);
                result = prime * result + (int) (temp ^ (temp >>> 32));
                result = prime * result + cash_back_type;
                result = prime * result + ((color == null) ? 0 : color.hashCode());
                result = prime * result + (int) (item_id ^ (item_id >>> 32));
                result = prime * result + (int) (catalog_id ^ (catalog_id >>> 32));
                result = prime * result + maxQuantity;
                result = prime * result + minBuyQuantity;
                temp = Double.doubleToLongBits(mrp);
                result = prime * result + (int) (temp ^ (temp >>> 32));
                temp = Double.doubleToLongBits(netPriceAfterCashBack);
                result = prime * result + (int) (temp ^ (temp >>> 32));
                result = prime * result + quantityStep;
                temp = Double.doubleToLongBits(sellingPrice);
                result = prime * result + (int) (temp ^ (temp >>> 32));
                result = prime * result + ((sellingPriceType == null) ? 0 : sellingPriceType.hashCode());
                return result;
        }
        @Override
        public boolean equals(Object obj) {
                if (this == obj)
                        return true;
                if (obj == null)
                        return false;
                if (getClass() != obj.getClass())
                        return false;
                AvailabilityInfo other = (AvailabilityInfo) obj;
                if (availability != other.availability)
                        return false;
                if (!Arrays.equals(bulkPricing, other.bulkPricing))
                        return false;
                if (Double.doubleToLongBits(cash_back) != Double.doubleToLongBits(other.cash_back))
                        return false;
                if (cash_back_type != other.cash_back_type)
                        return false;
                if (color == null) {
                        if (other.color != null)
                                return false;
                } else if (!color.equals(other.color))
                        return false;
                if (item_id != other.item_id)
                        return false;
                if (catalog_id != other.catalog_id)
                        return false;
                if (maxQuantity != other.maxQuantity)
                        return false;
                if (minBuyQuantity != other.minBuyQuantity)
                        return false;
                if (Double.doubleToLongBits(mrp) != Double.doubleToLongBits(other.mrp))
                        return false;
                if (Double.doubleToLongBits(netPriceAfterCashBack) != Double.doubleToLongBits(other.netPriceAfterCashBack))
                        return false;
                if (quantityStep != other.quantityStep)
                        return false;
                if (Double.doubleToLongBits(sellingPrice) != Double.doubleToLongBits(other.sellingPrice))
                        return false;
                if (sellingPriceType == null) {
                        if (other.sellingPriceType != null)
                                return false;
                } else if (!sellingPriceType.equals(other.sellingPriceType))
                        return false;
                return true;
        }
        
        

    
}