package oracle.byop.maf.data.entities;

import oracle.adfmf.java.beans.PropertyChangeListener;
import oracle.adfmf.java.beans.PropertyChangeSupport;

public class Warehouse {
    
    private Integer id = null; 
    private String  address = null;
    private String  city = null;
    private String  state = null;
    private Integer countryId = null;
    private String  zipCode = null;
    private Double    latitude = null;
    private Double    longitude = null;
    private Integer managerId = null;
    private PropertyChangeSupport propertyChangeSupport = new PropertyChangeSupport(this);

    public Warehouse() {
        super();
    }


    public Warehouse(Integer id, String address, String city, String state, Integer countryId, String zipCode, Double latitude, Double longitude, Integer managerId) {
        super();
        this.id = id;
        this.address = address;
        this.city = city;
        this.state = state;
        this.countryId = countryId;
        this.zipCode = zipCode;
        this.latitude = latitude;
        this.longitude = longitude;
        this.managerId = managerId;
    }


    public void setId(Integer id) {
        Integer oldId = this.id;
        this.id = id;
        propertyChangeSupport.firePropertyChange("id", oldId, id);
    }

    public Integer getId() {
        return id;
    }

    public void setAddress(String address) {
        String oldAddress = this.address;
        this.address = address;
        propertyChangeSupport.firePropertyChange("address", oldAddress, address);
    }

    public String getAddress() {
        return address;
    }

    public void setCity(String city) {
        String oldCity = this.city;
        this.city = city;
        propertyChangeSupport.firePropertyChange("city", oldCity, city);
    }

    public String getCity() {
        return city;
    }

    public void setState(String state) {
        String oldState = this.state;
        this.state = state;
        propertyChangeSupport.firePropertyChange("state", oldState, state);
    }

    public String getState() {
        return state;
    }

    public void setCountryId(Integer countryId) {
        Integer oldCountryId = this.countryId;
        this.countryId = countryId;
        propertyChangeSupport.firePropertyChange("countryId", oldCountryId, countryId);
    }

    public Integer getCountryId() {
        return countryId;
    }

    public void setZipCode(String zipCode) {
        String oldZipCode = this.zipCode;
        this.zipCode = zipCode;
        propertyChangeSupport.firePropertyChange("zipCode", oldZipCode, zipCode);
    }

    public String getZipCode() {
        return zipCode;
    }

    public void setLatitude(Double latitude) {
        Double oldLatitude = this.latitude;
        this.latitude = latitude;
        propertyChangeSupport.firePropertyChange("latitude", oldLatitude, latitude);
    }

    public Double getLatitude() {
        return latitude;
    }

    public void setLongitude(Double longitude) {
        Double oldLongitude = this.longitude;
        this.longitude = longitude;
        propertyChangeSupport.firePropertyChange("longitude", oldLongitude, longitude);
    }

    public Double getLongitude() {
        return longitude;
    }

    public void setManagerId(Integer managerId) {
        Integer oldManagerId = this.managerId;
        this.managerId = managerId;
        propertyChangeSupport.firePropertyChange("managerId", oldManagerId, managerId);
    }

    public Integer getManagerId() {
        return managerId;
    }

    public void addPropertyChangeListener(PropertyChangeListener l) {
        propertyChangeSupport.addPropertyChangeListener(l);
    }

    public void removePropertyChangeListener(PropertyChangeListener l) {
        propertyChangeSupport.removePropertyChangeListener(l);
    }
}
