Class ValidateAddressRequest

  • All Implemented Interfaces:
    ValidateAddressRequestOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

    public final class ValidateAddressRequest
    extends com.google.protobuf.GeneratedMessageV3
    implements ValidateAddressRequestOrBuilder
     The request for validating an address.
     
    Protobuf type google.maps.addressvalidation.v1.ValidateAddressRequest
    See Also:
    Serialized Form
    • Field Detail

      • PREVIOUS_RESPONSE_ID_FIELD_NUMBER

        public static final int PREVIOUS_RESPONSE_ID_FIELD_NUMBER
        See Also:
        Constant Field Values
      • ENABLE_USPS_CASS_FIELD_NUMBER

        public static final int ENABLE_USPS_CASS_FIELD_NUMBER
        See Also:
        Constant Field Values
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • hasAddress

        public boolean hasAddress()
         Required. The address being validated. Unformatted addresses should be
         submitted via [`address_lines`][google.type.PostalAddress.address_lines].
        
         The total length of the fields in this input must not exceed 280
         characters.
        
         Supported regions can be found in the
         [FAQ](https://developers.google.com/maps/documentation/address-validation/faq#which_regions_are_currently_supported).
        
         The [language_code][google.type.PostalAddress.language_code] value in the
         input address is reserved for future uses and is ignored today. The
         validated address result will be populated based on the preferred language
         for the given address, as identified by the system.
        
         The Address Validation API ignores the values in
         [recipients][google.type.PostalAddress.recipients] and
         [organization][google.type.PostalAddress.organization]. Any values in those
         fields will be discarded and not returned. Please do not set them.
         
        .google.type.PostalAddress address = 1 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        hasAddress in interface ValidateAddressRequestOrBuilder
        Returns:
        Whether the address field is set.
      • getAddress

        public com.google.type.PostalAddress getAddress()
         Required. The address being validated. Unformatted addresses should be
         submitted via [`address_lines`][google.type.PostalAddress.address_lines].
        
         The total length of the fields in this input must not exceed 280
         characters.
        
         Supported regions can be found in the
         [FAQ](https://developers.google.com/maps/documentation/address-validation/faq#which_regions_are_currently_supported).
        
         The [language_code][google.type.PostalAddress.language_code] value in the
         input address is reserved for future uses and is ignored today. The
         validated address result will be populated based on the preferred language
         for the given address, as identified by the system.
        
         The Address Validation API ignores the values in
         [recipients][google.type.PostalAddress.recipients] and
         [organization][google.type.PostalAddress.organization]. Any values in those
         fields will be discarded and not returned. Please do not set them.
         
        .google.type.PostalAddress address = 1 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getAddress in interface ValidateAddressRequestOrBuilder
        Returns:
        The address.
      • getAddressOrBuilder

        public com.google.type.PostalAddressOrBuilder getAddressOrBuilder()
         Required. The address being validated. Unformatted addresses should be
         submitted via [`address_lines`][google.type.PostalAddress.address_lines].
        
         The total length of the fields in this input must not exceed 280
         characters.
        
         Supported regions can be found in the
         [FAQ](https://developers.google.com/maps/documentation/address-validation/faq#which_regions_are_currently_supported).
        
         The [language_code][google.type.PostalAddress.language_code] value in the
         input address is reserved for future uses and is ignored today. The
         validated address result will be populated based on the preferred language
         for the given address, as identified by the system.
        
         The Address Validation API ignores the values in
         [recipients][google.type.PostalAddress.recipients] and
         [organization][google.type.PostalAddress.organization]. Any values in those
         fields will be discarded and not returned. Please do not set them.
         
        .google.type.PostalAddress address = 1 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getAddressOrBuilder in interface ValidateAddressRequestOrBuilder
      • getPreviousResponseId

        public String getPreviousResponseId()
         This field must be empty for the first address validation request. If
         more requests are necessary to fully validate a single address (for
         example if the changes the user makes after the initial validation need to
         be re-validated), then each followup request must populate this field with
         the
         [response_id][google.maps.addressvalidation.v1.ValidateAddressResponse.response_id]
         from the very first response in the validation sequence.
         
        string previous_response_id = 2;
        Specified by:
        getPreviousResponseId in interface ValidateAddressRequestOrBuilder
        Returns:
        The previousResponseId.
      • getPreviousResponseIdBytes

        public com.google.protobuf.ByteString getPreviousResponseIdBytes()
         This field must be empty for the first address validation request. If
         more requests are necessary to fully validate a single address (for
         example if the changes the user makes after the initial validation need to
         be re-validated), then each followup request must populate this field with
         the
         [response_id][google.maps.addressvalidation.v1.ValidateAddressResponse.response_id]
         from the very first response in the validation sequence.
         
        string previous_response_id = 2;
        Specified by:
        getPreviousResponseIdBytes in interface ValidateAddressRequestOrBuilder
        Returns:
        The bytes for previousResponseId.
      • getEnableUspsCass

        public boolean getEnableUspsCass()
         Enables USPS CASS compatible mode. This affects _only_ the
         [google.maps.addressvalidation.v1.ValidationResult.usps_data] field of
         [google.maps.addressvalidation.v1.ValidationResult]. Note: for USPS CASS
         enabled requests for addresses in Puerto Rico, a
         [google.type.PostalAddress.region_code] of the `address` must be provided
         as "PR", or an [google.type.PostalAddress.administrative_area] of the
         `address` must be provided as "Puerto Rico" (case-insensitive) or "PR".
        
         It's recommended to use a componentized `address`, or alternatively specify
         at least two [google.type.PostalAddress.address_lines] where the first line
         contains the street number and name and the second line contains the city,
         state, and zip code.
         
        bool enable_usps_cass = 3;
        Specified by:
        getEnableUspsCass in interface ValidateAddressRequestOrBuilder
        Returns:
        The enableUspsCass.
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static ValidateAddressRequest parseFrom​(ByteBuffer data)
                                                throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ValidateAddressRequest parseFrom​(ByteBuffer data,
                                                       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ValidateAddressRequest parseFrom​(com.google.protobuf.ByteString data)
                                                throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ValidateAddressRequest parseFrom​(com.google.protobuf.ByteString data,
                                                       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ValidateAddressRequest parseFrom​(byte[] data)
                                                throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ValidateAddressRequest parseFrom​(byte[] data,
                                                       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • newBuilderForType

        public ValidateAddressRequest.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public ValidateAddressRequest.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected ValidateAddressRequest.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getParserForType

        public com.google.protobuf.Parser<ValidateAddressRequest> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public ValidateAddressRequest getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder