/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.arrebol.taxiservicios.model.view.report;

import java.io.Serializable;
import java.util.Date;

/**
 *
 * @author Picasso
 */
public class SavingDriver implements Serializable {

    private static final long serialVersionUID = 6288786958693094307L;

    private String id;
    private String personName;
    private String economicNumber;
    private Date admissionDate;
    private String sanction;
    private String disposition;
    private String accident;
    private Double totalSanction;
    private Double totalDisposition;
    private Double totalAccident;
    private Double totalAdd;
    private Double totalSaving;
    private Double totalSiniestro;
    private Double total;
    private Double totalSumSiniestro;
    private Double totalAdeudo;

    public SavingDriver() {
    }

    public SavingDriver(String id) {
        this.id = id;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public void setPersonName(String personName) {
        this.personName = personName;
    }

    public String getPersonName() {
        return personName;
    }

    public String getEconomicNumber() {
        return economicNumber;
    }

    public void setEconomicNumber(String economicNumber) {
        this.economicNumber = economicNumber;
    }

    public Date getAdmissionDate() {
        return admissionDate;
    }

    public void setAdmissionDate(Date admissionDate) {
        this.admissionDate = admissionDate;
    }

    public String getSanction() {
        return sanction;
    }

    public void setSanction(String sanction) {
        this.sanction = sanction;
    }

    public String getDisposition() {
        return disposition;
    }

    public void setDisposition(String disposition) {
        this.disposition = disposition;
    }

    public String getAccident() {
        return accident;
    }

    public void setAccident(String accident) {
        this.accident = accident;
    }

    public Double getTotalSanction() {
        if (null == totalSanction) {
            totalSanction = 0d;
        }
        return totalSanction;
    }

    public void setTotalSanction(Double totalSanction) {
        this.totalSanction = totalSanction;
    }

    public Double getTotalDisposition() {
        if (null == totalDisposition) {
            totalDisposition = 0d;
        }
        return totalDisposition;
    }

    public void setTotalDisposition(Double totalDisposition) {
        this.totalDisposition = totalDisposition;
    }

    public Double getTotalAccident() {
        return totalAccident;
    }

    public void setTotalAccident(Double totalAccident) {
        this.totalAccident = totalAccident;
    }

    public Double getTotalAdd() {
        if (null == totalAdd) {
            totalAdd = 0d;
        }
        return totalAdd;
    }

    public void setTotalAdd(Double totalAdd) {
        this.totalAdd = totalAdd;
    }

    public Double getTotalSaving() {
        if (null == totalSaving) {
            totalSaving = 0d;
        }
        return totalSaving;
    }

    public void setTotalSaving(Double totalSaving) {
        this.totalSaving = totalSaving;
    }

    public Double getTotal() {
        return getTotalSaving() - (getTotalSanction() + getTotalDisposition());
    }

    public void setTotal(Double total) {
        this.total = total;
    }

    public Double getTotalSiniestro() {
        return totalSiniestro;
    }

    public void setTotalSiniestro(Double totalSiniestro) {
        this.totalSiniestro = totalSiniestro;
    }

    public Double getTotalSumSiniestro() {
        return getTotalSiniestro() - getTotalAccident();
    }

    public void setTotalSumSiniestro(Double totalSumSiniestro) {
        this.totalSumSiniestro = totalSumSiniestro;
    }

    public Double getTotalAdeudo() {
        return totalAdeudo;
    }

    public void setTotalAdeudo(Double totalAdeudo) {
        this.totalAdeudo = totalAdeudo;
    }
    
    @Override
    public String toString() {
        return "SavingDriver{" + "id=" + id + ", personName=" + personName + ", economicNumber=" + economicNumber + ", admissionDate=" + admissionDate + ", sanction=" + sanction + ", disposition=" + disposition + ", accident=" + accident + '}';
    }

}
