Package com.google.rpc
Class BadRequest.FieldViolation
java.lang.Object
com.google.protobuf.AbstractMessageLite<MessageType,BuilderType>
com.google.protobuf.GeneratedMessageLite<BadRequest.FieldViolation,BadRequest.FieldViolation.Builder>
com.google.rpc.BadRequest.FieldViolation
- All Implemented Interfaces:
com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,BadRequest.FieldViolationOrBuilder
- Enclosing class:
- BadRequest
public static final class BadRequest.FieldViolation
extends com.google.protobuf.GeneratedMessageLite<BadRequest.FieldViolation,BadRequest.FieldViolation.Builder>
implements BadRequest.FieldViolationOrBuilder
A message type used to describe a single bad request field.Protobuf type
google.rpc.BadRequest.FieldViolation-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA message type used to describe a single bad request field.Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageLite
com.google.protobuf.GeneratedMessageLite.DefaultInstanceBasedParser<T extends com.google.protobuf.GeneratedMessageLite<T,?>>, com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.GeneratedExtension<ContainingType extends com.google.protobuf.MessageLite, Type extends Object>, com.google.protobuf.GeneratedMessageLite.MethodToInvoke, com.google.protobuf.GeneratedMessageLite.SerializedForm Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessageLite
unknownFieldsFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionprotected final ObjectdynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) static BadRequest.FieldViolationA description of why the request element is bad.com.google.protobuf.ByteStringA description of why the request element is bad.getField()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.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.newBuilder(BadRequest.FieldViolation prototype) static BadRequest.FieldViolationparseDelimitedFrom(InputStream input) static BadRequest.FieldViolationparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static BadRequest.FieldViolationparseFrom(byte[] data) static BadRequest.FieldViolationparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static BadRequest.FieldViolationparseFrom(com.google.protobuf.ByteString data) static BadRequest.FieldViolationparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static BadRequest.FieldViolationparseFrom(com.google.protobuf.CodedInputStream input) static BadRequest.FieldViolationparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static BadRequest.FieldViolationparseFrom(InputStream input) static BadRequest.FieldViolationparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static BadRequest.FieldViolationparseFrom(ByteBuffer data) static BadRequest.FieldViolationparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<BadRequest.FieldViolation>parser()Methods inherited from class com.google.protobuf.GeneratedMessageLite
createBuilder, createBuilder, dynamicMethod, dynamicMethod, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, emptyProtobufList, equals, getDefaultInstanceForType, getParserForType, getSerializedSize, hashCode, isInitialized, isInitialized, makeImmutable, mergeLengthDelimitedField, mergeUnknownFields, mergeVarintField, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBuilderForType, newMessageInfo, newRepeatedGeneratedExtension, newSingularGeneratedExtension, parseDelimitedFrom, parseDelimitedFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parsePartialFrom, parseUnknownField, registerDefaultInstance, toBuilder, toString, writeToMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Field Details
-
FIELD_FIELD_NUMBER
public static final int FIELD_FIELD_NUMBER- See Also:
-
DESCRIPTION_FIELD_NUMBER
public static final int DESCRIPTION_FIELD_NUMBER- See Also:
-
REASON_FIELD_NUMBER
public static final int REASON_FIELD_NUMBER- See Also:
-
LOCALIZED_MESSAGE_FIELD_NUMBER
public static final int LOCALIZED_MESSAGE_FIELD_NUMBER- See Also:
-
-
Method Details
-
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 [json_name = "field"];- 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 [json_name = "field"];- Specified by:
getFieldBytesin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The bytes for field.
-
getDescription
A description of why the request element is bad.
string description = 2 [json_name = "description"];- 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 [json_name = "description"];- Specified by:
getDescriptionBytesin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The bytes for description.
-
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 [json_name = "reason"];- 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 [json_name = "reason"];- Specified by:
getReasonBytesin interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The bytes for reason.
-
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 [json_name = "localizedMessage"];- 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 [json_name = "localizedMessage"];- Specified by:
getLocalizedMessagein interfaceBadRequest.FieldViolationOrBuilder- Returns:
- The localizedMessage.
-
parseFrom
public static BadRequest.FieldViolation parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static BadRequest.FieldViolation parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static BadRequest.FieldViolation parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static BadRequest.FieldViolation parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static BadRequest.FieldViolation parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static BadRequest.FieldViolation parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static BadRequest.FieldViolation parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static BadRequest.FieldViolation parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
public static BadRequest.FieldViolation parseFrom(com.google.protobuf.CodedInputStream input) throws IOException - Throws:
IOException
-
parseFrom
public static BadRequest.FieldViolation parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilder
-
newBuilder
-
dynamicMethod
protected final Object dynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) - Specified by:
dynamicMethodin classcom.google.protobuf.GeneratedMessageLite<BadRequest.FieldViolation,BadRequest.FieldViolation.Builder>
-
getDefaultInstance
-
parser
-