Class Address


  • public final class Address
    extends java.lang.Object
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  Address.AddressBuilder  
    • Constructor Summary

      Constructors 
      Constructor Description
      Address()  
      Address​(java.lang.String addressLine1, java.lang.String addressLine2, java.lang.String city, java.lang.String state, java.lang.String zip, CountryCode country)
      Creates a new Address instance.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static Address.AddressBuilder builder()  
      boolean equals​(java.lang.Object o)  
      java.lang.String getAddressLine1()
      The first line of the address.
      java.lang.String getAddressLine2()
      The second line of the address
      java.lang.String getCity()
      The address city.
      CountryCode getCountry()
      The two-letter ISO country code of the address.
      java.lang.String getState()
      The state or province of the address country ISO 3166-2 code (for example: CA for California in the United States).
      java.lang.String getZip()
      The address zip or postal code.
      int hashCode()  
      void setAddressLine1​(java.lang.String addressLine1)
      The first line of the address.
      void setAddressLine2​(java.lang.String addressLine2)
      The second line of the address
      void setCity​(java.lang.String city)
      The address city.
      void setCountry​(CountryCode country)
      The two-letter ISO country code of the address.
      void setState​(java.lang.String state)
      The state or province of the address country ISO 3166-2 code (for example: CA for California in the United States).
      void setZip​(java.lang.String zip)
      The address zip or postal code.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • Address

        public Address()
      • Address

        public Address​(java.lang.String addressLine1,
                       java.lang.String addressLine2,
                       java.lang.String city,
                       java.lang.String state,
                       java.lang.String zip,
                       CountryCode country)
        Creates a new Address instance.
        Parameters:
        addressLine1 - The first line of the address.
        addressLine2 - The second line of the address
        city - The address city.
        state - The state or province of the address country ISO 3166-2 code (for example: CA for California in the United States).
        zip - The address zip or postal code.
        country - The two-letter ISO country code of the address.
    • Method Detail

      • getAddressLine1

        public java.lang.String getAddressLine1()
        The first line of the address.
      • getAddressLine2

        public java.lang.String getAddressLine2()
        The second line of the address
      • getCity

        public java.lang.String getCity()
        The address city.
      • getState

        public java.lang.String getState()
        The state or province of the address country ISO 3166-2 code (for example: CA for California in the United States).
      • getZip

        public java.lang.String getZip()
        The address zip or postal code.
      • getCountry

        public CountryCode getCountry()
        The two-letter ISO country code of the address.
      • setAddressLine1

        public void setAddressLine1​(java.lang.String addressLine1)
        The first line of the address.
      • setAddressLine2

        public void setAddressLine2​(java.lang.String addressLine2)
        The second line of the address
      • setCity

        public void setCity​(java.lang.String city)
        The address city.
      • setState

        public void setState​(java.lang.String state)
        The state or province of the address country ISO 3166-2 code (for example: CA for California in the United States).
      • setZip

        public void setZip​(java.lang.String zip)
        The address zip or postal code.
      • setCountry

        public void setCountry​(CountryCode country)
        The two-letter ISO country code of the address.
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object