microservices-event-sourcing-master/inventory-service/src/main/java/com/timeyang/address/Address.java
package com.timeyang.address;

import org.neo4j.ogm.annotation.GraphId;
import org.neo4j.ogm.annotation.NodeEntity;

/**
 * @author chaokunyang
 */
@NodeEntity
public class Address {
    @GraphId
    private Long id;
    private String country;
    private String province;
    private String city;
    private String district;
    private String street1;
    private String street2;
    private Integer zipCode;

    public Address() {
    }

    public Address(String country, String province, String city, String district, String street1, String street2, Integer zipCode) {
        this.country = country;
        this.province = province;
        this.city = city;
        this.district = district;
        this.street1 = street1;
        this.street2 = street2;
        this.zipCode = zipCode;
    }

    public Long getId() {
        return id;
    }

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

    public String getCountry() {
        return country;
    }

    public void setCountry(String country) {
        this.country = country;
    }

    public String getProvince() {
        return province;
    }

    public void setProvince(String province) {
        this.province = province;
    }

    public String getCity() {
        return city;
    }

    public void setCity(String city) {
        this.city = city;
    }

    public String getDistrict() {
        return district;
    }

    public void setDistrict(String district) {
        this.district = district;
    }

    public String getStreet1() {
        return street1;
    }

    public void setStreet1(String street1) {
        this.street1 = street1;
    }

    public String getStreet2() {
        return street2;
    }

    public void setStreet2(String street2) {
        this.street2 = street2;
    }

    public Integer getZipCode() {
        return zipCode;
    }

    public void setZipCode(Integer zipCode) {
        this.zipCode = zipCode;
    }

    @Override
    public String toString() {
        return "Address{" +
                "id=" + id +
                ", country='" + country + '\'' +
                ", province='" + province + '\'' +
                ", city='" + city + '\'' +
                ", district='" + district + '\'' +
                ", street1='" + street1 + '\'' +
                ", street2='" + street2 + '\'' +
                ", zipCode=" + zipCode +
                '}';
    }
}
