Subversion Repositories SmartDukaan

Rev

Rev 22869 | Rev 25778 | 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 SerialNumberDetail {
        private String serialNumber;
        private String insurance;
        private float amount;
        
        public String getSerialNumber() {
                return serialNumber;
        }
        public void setSerialNumber(String serialNumber) {
                this.serialNumber = serialNumber;
        }

        public float getAmount() {
                return amount;
        }
        public void setAmount(float amount) {
                this.amount = amount;
        }
        
        @Override
        public int hashCode() {
                final int prime = 31;
                int result = 1;
                result = prime * result + Float.floatToIntBits(amount);
                result = prime * result + ((insurance == null) ? 0 : insurance.hashCode());
                result = prime * result + ((serialNumber == null) ? 0 : serialNumber.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;
                SerialNumberDetail other = (SerialNumberDetail) obj;
                if (Float.floatToIntBits(amount) != Float.floatToIntBits(other.amount))
                        return false;
                if (insurance == null) {
                        if (other.insurance != null)
                                return false;
                } else if (!insurance.equals(other.insurance))
                        return false;
                if (serialNumber == null) {
                        if (other.serialNumber != null)
                                return false;
                } else if (!serialNumber.equals(other.serialNumber))
                        return false;
                return true;
        }
        public String getInsurance() {
                return insurance;
        }
        public void setInsurance(String insurance) {
                this.insurance = insurance;
        }
        @Override
        public String toString() {
                return "SerialNumberDetail [serialNumber=" + serialNumber + ", insurance=" + insurance + ", amount=" + amount
                                + "]";
        }
        
        
}