Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: [java-maps-addressvalidation] Document that PREMISE_PROXIMITY is a valid value for an address granularity #8883

Merged
merged 2 commits into from
Dec 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -74,12 +74,13 @@ public class HttpJsonAddressValidationStub extends AddressValidationStub {
Map<String, List<String>> fields = new HashMap<>();
ProtoRestSerializer<ValidateAddressRequest> serializer =
ProtoRestSerializer.create();
serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int");
return fields;
})
.setRequestBodyExtractor(
request ->
ProtoRestSerializer.create()
.toBody("*", request.toBuilder().build(), false))
.toBody("*", request.toBuilder().build(), true))
.build())
.setResponseParser(
ProtoMessageResponseParser.<ValidateAddressResponse>newBuilder()
Expand Down Expand Up @@ -112,12 +113,13 @@ public class HttpJsonAddressValidationStub extends AddressValidationStub {
Map<String, List<String>> fields = new HashMap<>();
ProtoRestSerializer<ProvideValidationFeedbackRequest> serializer =
ProtoRestSerializer.create();
serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int");
return fields;
})
.setRequestBodyExtractor(
request ->
ProtoRestSerializer.create()
.toBody("*", request.toBuilder().build(), false))
.toBody("*", request.toBuilder().build(), true))
.build())
.setResponseParser(
ProtoMessageResponseParser.<ProvideValidationFeedbackResponse>newBuilder()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,8 @@ public int getConclusionValue() {
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand All @@ -370,7 +371,8 @@ public java.lang.String getResponseId() {
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand Down Expand Up @@ -882,7 +884,8 @@ public Builder clearConclusion() {
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand All @@ -906,7 +909,8 @@ public java.lang.String getResponseId() {
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand All @@ -930,7 +934,8 @@ public com.google.protobuf.ByteString getResponseIdBytes() {
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand All @@ -953,7 +958,8 @@ public Builder setResponseId(java.lang.String value) {
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand All @@ -972,7 +978,8 @@ public Builder clearResponseId() {
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ public interface ProvideValidationFeedbackRequestOrBuilder
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand All @@ -75,7 +76,8 @@ public interface ProvideValidationFeedbackRequestOrBuilder
*
*
* <pre>
* Required. The ID of the response that this feedback is for. This should be the
* Required. The ID of the response that this feedback is for. This should be
* the
* [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
* from the first response in a series of address validation attempts.
* </pre>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ public enum Granularity implements com.google.protobuf.ProtocolMessageEnum {
*
* <pre>
* A geocode that should be very close to the building-level location of
* the address. Only used for geocodes and not for addresses.
* the address.
* </pre>
*
* <code>PREMISE_PROXIMITY = 3;</code>
Expand Down Expand Up @@ -198,7 +198,7 @@ public enum Granularity implements com.google.protobuf.ProtocolMessageEnum {
*
* <pre>
* A geocode that should be very close to the building-level location of
* the address. Only used for geocodes and not for addresses.
* the address.
* </pre>
*
* <code>PREMISE_PROXIMITY = 3;</code>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ service AddressValidation {
option (google.api.default_host) = "addressvalidation.googleapis.com";

// Validates an address.
rpc ValidateAddress(ValidateAddressRequest) returns (ValidateAddressResponse) {
rpc ValidateAddress(ValidateAddressRequest)
returns (ValidateAddressResponse) {
option (google.api.http) = {
post: "/v1:validateAddress"
body: "*"
Expand All @@ -52,7 +53,8 @@ service AddressValidation {
// same address, and should be called once the transaction is concluded. This
// should only be sent once for the sequence of `ValidateAddress` requests
// needed to validate an address fully.
rpc ProvideValidationFeedback(ProvideValidationFeedbackRequest) returns (ProvideValidationFeedbackResponse) {
rpc ProvideValidationFeedback(ProvideValidationFeedbackRequest)
returns (ProvideValidationFeedbackResponse) {
option (google.api.http) = {
post: "/v1:provideValidationFeedback"
body: "*"
Expand Down Expand Up @@ -80,7 +82,8 @@ message ValidateAddressRequest {
// [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];
google.type.PostalAddress address = 1
[(google.api.field_behavior) = REQUIRED];

// This field must be empty for the first address validation request. If
// more requests are necessary to fully validate a single address (for
Expand Down Expand Up @@ -149,7 +152,8 @@ message ProvideValidationFeedbackRequest {
// `INVALID_ARGUMENT` error will be returned.
ValidationConclusion conclusion = 1 [(google.api.field_behavior) = REQUIRED];

// Required. The ID of the response that this feedback is for. This should be the
// Required. The ID of the response that this feedback is for. This should be
// the
// [response_id][google.maps.addressvalidation.v1.ValidateAddressRequest.response_id]
// from the first response in a series of address validation attempts.
string response_id = 2 [(google.api.field_behavior) = REQUIRED];
Expand All @@ -158,9 +162,7 @@ message ProvideValidationFeedbackRequest {
// The response for validation feedback.
//
// The response is empty if the feedback is sent successfully.
message ProvideValidationFeedbackResponse {

}
message ProvideValidationFeedbackResponse {}

// The result of validating an address.
message ValidationResult {
Expand Down Expand Up @@ -202,7 +204,7 @@ message Verdict {
PREMISE = 2;

// A geocode that should be very close to the building-level location of
// the address. Only used for geocodes and not for addresses.
// the address.
PREMISE_PROXIMITY = 3;

// The address or geocode indicates a block. Only used in regions which
Expand Down