Subversion Repositories SmartDukaan

Rev

Rev 22549 | Rev 23821 | Go to most recent revision | View as "text/plain" | Blame | Compare with Previous | Last modification | View Log | RSS feed

package com.spice.profitmandi.common.model;

public class PriceModel {
        private boolean mop;
        private float price;
        private float maxDiscountAmount;
        
        public boolean isMop() {
                return mop;
        }
        public void setMop(boolean mop) {
                this.mop = mop;
        }
        public float getPrice() {
                return price;
        }
        public void setPrice(float price) {
                this.price = price;
        }
        
        public float getMaxDiscountAmount() {
                return maxDiscountAmount;
        }
        public void setMaxDiscountAmount(float maxDiscountAmount) {
                this.maxDiscountAmount = maxDiscountAmount;
        }
        @Override
        public int hashCode() {
                final int prime = 31;
                int result = 1;
                result = prime * result + (mop ? 1231 : 1237);
                result = prime * result + Float.floatToIntBits(price);
                return result;
        }
        @Override
        public boolean equals(Object obj) {
                if (this == obj)
                        return true;
                if (obj == null)
                        return false;
                if (getClass() != obj.getClass())
                        return false;
                PriceModel other = (PriceModel) obj;
                if (mop != other.mop)
                        return false;
                if (Float.floatToIntBits(price) != Float.floatToIntBits(other.price))
                        return false;
                if (Float.floatToIntBits(maxDiscountAmount) != Float.floatToIntBits(other.maxDiscountAmount))
                        return false;
                return true;
        }
        @Override
        public String toString() {
                return "PriceModel [mop=" + mop + ", price=" + price + "maxDiscountAmount=" +maxDiscountAmount + "]";
        }
        
}