Package com.google.rpc
Class BadRequest.FieldViolation.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
com.google.rpc.BadRequest.FieldViolation.Builder
- All Implemented Interfaces:
com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,BadRequest.FieldViolationOrBuilder,Cloneable
- Enclosing class:
- BadRequest.FieldViolation
public static final class BadRequest.FieldViolation.Builder
extends com.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
implements BadRequest.FieldViolationOrBuilder
A message type used to describe a single bad request field.Protobuf type
google.rpc.BadRequest.FieldViolation-
Method Summary
Modifier and TypeMethodDescriptionaddRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) build()clear()A description of why the request element is bad.A path that leads to a field in the request body.clearField(com.google.protobuf.Descriptors.FieldDescriptor field) Provides a localized error message for field-level errors that is safe to return to the API consumer.clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) The reason of the field-level error.clone()A description of why the request element is bad.com.google.protobuf.ByteStringA description of why the request element is bad.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorgetField()A path that leads to a field in the request body.com.google.protobuf.ByteStringA path that leads to a field in the request body.Provides a localized error message for field-level errors that is safe to return to the API consumer.Provides a localized error message for field-level errors that is safe to return to the API consumer.Provides a localized error message for field-level errors that is safe to return to the API consumer.The reason of the field-level error.com.google.protobuf.ByteStringThe reason of the field-level error.booleanProvides a localized error message for field-level errors that is safe to return to the API consumer.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleanmergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) Provides a localized error message for field-level errors that is safe to return to the API consumer.mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) setDescription(String value) A description of why the request element is bad.setDescriptionBytes(com.google.protobuf.ByteString value) A description of why the request element is bad.A path that leads to a field in the request body.setFieldBytes(com.google.protobuf.ByteString value) A path that leads to a field in the request body.Provides a localized error message for field-level errors that is safe to return to the API consumer.setLocalizedMessage(LocalizedMessage.Builder builderForValue) Provides a localized error message for field-level errors that is safe to return to the API consumer.The reason of the field-level error.setReasonBytes(com.google.protobuf.ByteString value) The reason of the field-level error.setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
clone
- Specified by:
clonein interfacecom.google.protobuf.Message.Builder- Specified by:
clonein interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clonein classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
setField
public BadRequest.FieldViolation.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
setFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
clearField
public BadRequest.FieldViolation.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) - Specified by:
clearFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
clearFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
clearOneof
public BadRequest.FieldViolation.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) - Specified by:
clearOneofin interfacecom.google.protobuf.Message.Builder- Overrides:
clearOneofin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
setRepeatedField
public BadRequest.FieldViolation.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) - Specified by:
setRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
addRepeatedField
public BadRequest.FieldViolation.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
addRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
addRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<BadRequest.FieldViolation.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
mergeFrom
public BadRequest.FieldViolation.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<BadRequest.FieldViolation.Builder>- Throws:
IOException
-
getField
A path that leads to a field in the request body. The value will be a sequence of dot-separated identifiers that identify a protocol buffer field. Consider the following: message CreateContactRequest { message EmailAddress { enum Type { TYPE_UNSPECIFIED = 0; HOME = 1; WORK = 2; } optional string email = 1; repeated EmailType type = 2; } string full_name = 1; repeated EmailAddress email_addresses = 2; } In this example, in proto `field` could take one of the following values: * `full_name` for a violation in the `full_name` value * `email_addresses[1].email` for a violation in the `email` field of the first `email_addresses` message * `email_addresses[3].type[2]` for a violation in the second `type` value in the third `email_addresses` message. In JSON, the same values are represented as: * `fullName` for a violation in the `fullName` value * `emailAddresses[1].email` for a violation in the `email` field of the first `emailAddresses` message * `emailAddresses[3].type[2]` for a violation in the second `type` value in the third `emailAddresses` message.string field = 1;- Specified by:
getFieldin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The field.
-
getFieldBytes
public com.google.protobuf.ByteString getFieldBytes()A path that leads to a field in the request body. The value will be a sequence of dot-separated identifiers that identify a protocol buffer field. Consider the following: message CreateContactRequest { message EmailAddress { enum Type { TYPE_UNSPECIFIED = 0; HOME = 1; WORK = 2; } optional string email = 1; repeated EmailType type = 2; } string full_name = 1; repeated EmailAddress email_addresses = 2; } In this example, in proto `field` could take one of the following values: * `full_name` for a violation in the `full_name` value * `email_addresses[1].email` for a violation in the `email` field of the first `email_addresses` message * `email_addresses[3].type[2]` for a violation in the second `type` value in the third `email_addresses` message. In JSON, the same values are represented as: * `fullName` for a violation in the `fullName` value * `emailAddresses[1].email` for a violation in the `email` field of the first `emailAddresses` message * `emailAddresses[3].type[2]` for a violation in the second `type` value in the third `emailAddresses` message.string field = 1;- Specified by:
getFieldBytesin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The bytes for field.
-
setField
A path that leads to a field in the request body. The value will be a sequence of dot-separated identifiers that identify a protocol buffer field. Consider the following: message CreateContactRequest { message EmailAddress { enum Type { TYPE_UNSPECIFIED = 0; HOME = 1; WORK = 2; } optional string email = 1; repeated EmailType type = 2; } string full_name = 1; repeated EmailAddress email_addresses = 2; } In this example, in proto `field` could take one of the following values: * `full_name` for a violation in the `full_name` value * `email_addresses[1].email` for a violation in the `email` field of the first `email_addresses` message * `email_addresses[3].type[2]` for a violation in the second `type` value in the third `email_addresses` message. In JSON, the same values are represented as: * `fullName` for a violation in the `fullName` value * `emailAddresses[1].email` for a violation in the `email` field of the first `emailAddresses` message * `emailAddresses[3].type[2]` for a violation in the second `type` value in the third `emailAddresses` message.string field = 1;- Parameters:
value- The field to set.- Returns:
- This builder for chaining.
-
clearField
A path that leads to a field in the request body. The value will be a sequence of dot-separated identifiers that identify a protocol buffer field. Consider the following: message CreateContactRequest { message EmailAddress { enum Type { TYPE_UNSPECIFIED = 0; HOME = 1; WORK = 2; } optional string email = 1; repeated EmailType type = 2; } string full_name = 1; repeated EmailAddress email_addresses = 2; } In this example, in proto `field` could take one of the following values: * `full_name` for a violation in the `full_name` value * `email_addresses[1].email` for a violation in the `email` field of the first `email_addresses` message * `email_addresses[3].type[2]` for a violation in the second `type` value in the third `email_addresses` message. In JSON, the same values are represented as: * `fullName` for a violation in the `fullName` value * `emailAddresses[1].email` for a violation in the `email` field of the first `emailAddresses` message * `emailAddresses[3].type[2]` for a violation in the second `type` value in the third `emailAddresses` message.string field = 1;- Returns:
- This builder for chaining.
-
setFieldBytes
A path that leads to a field in the request body. The value will be a sequence of dot-separated identifiers that identify a protocol buffer field. Consider the following: message CreateContactRequest { message EmailAddress { enum Type { TYPE_UNSPECIFIED = 0; HOME = 1; WORK = 2; } optional string email = 1; repeated EmailType type = 2; } string full_name = 1; repeated EmailAddress email_addresses = 2; } In this example, in proto `field` could take one of the following values: * `full_name` for a violation in the `full_name` value * `email_addresses[1].email` for a violation in the `email` field of the first `email_addresses` message * `email_addresses[3].type[2]` for a violation in the second `type` value in the third `email_addresses` message. In JSON, the same values are represented as: * `fullName` for a violation in the `fullName` value * `emailAddresses[1].email` for a violation in the `email` field of the first `emailAddresses` message * `emailAddresses[3].type[2]` for a violation in the second `type` value in the third `emailAddresses` message.string field = 1;- Parameters:
value- The bytes for field to set.- Returns:
- This builder for chaining.
-
getDescription
A description of why the request element is bad.
string description = 2;- Specified by:
getDescriptionin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The description.
-
getDescriptionBytes
public com.google.protobuf.ByteString getDescriptionBytes()A description of why the request element is bad.
string description = 2;- Specified by:
getDescriptionBytesin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The bytes for description.
-
setDescription
A description of why the request element is bad.
string description = 2;- Parameters:
value- The description to set.- Returns:
- This builder for chaining.
-
clearDescription
A description of why the request element is bad.
string description = 2;- Returns:
- This builder for chaining.
-
setDescriptionBytes
A description of why the request element is bad.
string description = 2;- Parameters:
value- The bytes for description to set.- Returns:
- This builder for chaining.
-
getReason
The reason of the field-level error. This is a constant value that identifies the proximate cause of the field-level error. It should uniquely identify the type of the FieldViolation within the scope of the google.rpc.ErrorInfo.domain. This should be at most 63 characters and match a regular expression of `[A-Z][A-Z0-9_]+[A-Z0-9]`, which represents UPPER_SNAKE_CASE.
string reason = 3;- Specified by:
getReasonin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The reason.
-
getReasonBytes
public com.google.protobuf.ByteString getReasonBytes()The reason of the field-level error. This is a constant value that identifies the proximate cause of the field-level error. It should uniquely identify the type of the FieldViolation within the scope of the google.rpc.ErrorInfo.domain. This should be at most 63 characters and match a regular expression of `[A-Z][A-Z0-9_]+[A-Z0-9]`, which represents UPPER_SNAKE_CASE.
string reason = 3;- Specified by:
getReasonBytesin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The bytes for reason.
-
setReason
The reason of the field-level error. This is a constant value that identifies the proximate cause of the field-level error. It should uniquely identify the type of the FieldViolation within the scope of the google.rpc.ErrorInfo.domain. This should be at most 63 characters and match a regular expression of `[A-Z][A-Z0-9_]+[A-Z0-9]`, which represents UPPER_SNAKE_CASE.
string reason = 3;- Parameters:
value- The reason to set.- Returns:
- This builder for chaining.
-
clearReason
The reason of the field-level error. This is a constant value that identifies the proximate cause of the field-level error. It should uniquely identify the type of the FieldViolation within the scope of the google.rpc.ErrorInfo.domain. This should be at most 63 characters and match a regular expression of `[A-Z][A-Z0-9_]+[A-Z0-9]`, which represents UPPER_SNAKE_CASE.
string reason = 3;- Returns:
- This builder for chaining.
-
setReasonBytes
The reason of the field-level error. This is a constant value that identifies the proximate cause of the field-level error. It should uniquely identify the type of the FieldViolation within the scope of the google.rpc.ErrorInfo.domain. This should be at most 63 characters and match a regular expression of `[A-Z][A-Z0-9_]+[A-Z0-9]`, which represents UPPER_SNAKE_CASE.
string reason = 3;- Parameters:
value- The bytes for reason to set.- Returns:
- This builder for chaining.
-
hasLocalizedMessage
public boolean hasLocalizedMessage()Provides a localized error message for field-level errors that is safe to return to the API consumer.
.google.rpc.LocalizedMessage localized_message = 4;- Specified by:
hasLocalizedMessagein interfaceBadRequest.FieldViolationOrBuilder- Returns:
- Whether the localizedMessage field is set.
-
getLocalizedMessage
Provides a localized error message for field-level errors that is safe to return to the API consumer.
.google.rpc.LocalizedMessage localized_message = 4;- Specified by:
getLocalizedMessagein interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The localizedMessage.
-
setLocalizedMessage
Provides a localized error message for field-level errors that is safe to return to the API consumer.
.google.rpc.LocalizedMessage localized_message = 4; -
setLocalizedMessage
public BadRequest.FieldViolation.Builder setLocalizedMessage(LocalizedMessage.Builder builderForValue) Provides a localized error message for field-level errors that is safe to return to the API consumer.
.google.rpc.LocalizedMessage localized_message = 4; -
mergeLocalizedMessage
Provides a localized error message for field-level errors that is safe to return to the API consumer.
.google.rpc.LocalizedMessage localized_message = 4; -
clearLocalizedMessage
Provides a localized error message for field-level errors that is safe to return to the API consumer.
.google.rpc.LocalizedMessage localized_message = 4; -
getLocalizedMessageBuilder
Provides a localized error message for field-level errors that is safe to return to the API consumer.
.google.rpc.LocalizedMessage localized_message = 4; -
getLocalizedMessageOrBuilder
Provides a localized error message for field-level errors that is safe to return to the API consumer.
.google.rpc.LocalizedMessage localized_message = 4;- Specified by:
getLocalizedMessageOrBuilderin interfaceBadRequest.FieldViolationOrBuilder
-
setUnknownFields
public final BadRequest.FieldViolation.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) - Specified by:
setUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
setUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-
mergeUnknownFields
public final BadRequest.FieldViolation.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) - Specified by:
mergeUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<BadRequest.FieldViolation.Builder>
-