Class PreconditionFailure.Violation (2.14.3)

public static final class PreconditionFailure.Violation extends GeneratedMessageV3 implements PreconditionFailure.ViolationOrBuilder

A message type used to describe a single precondition failure.

Protobuf type google.rpc.PreconditionFailure.Violation

Static Fields

DESCRIPTION_FIELD_NUMBER

public static final int DESCRIPTION_FIELD_NUMBER
Field Value
TypeDescription
int

SUBJECT_FIELD_NUMBER

public static final int SUBJECT_FIELD_NUMBER
Field Value
TypeDescription
int

TYPE_FIELD_NUMBER

public static final int TYPE_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static PreconditionFailure.Violation getDefaultInstance()
Returns
TypeDescription
PreconditionFailure.Violation

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static PreconditionFailure.Violation.Builder newBuilder()
Returns
TypeDescription
PreconditionFailure.Violation.Builder

newBuilder(PreconditionFailure.Violation prototype)

public static PreconditionFailure.Violation.Builder newBuilder(PreconditionFailure.Violation prototype)
Parameter
NameDescription
prototypePreconditionFailure.Violation
Returns
TypeDescription
PreconditionFailure.Violation.Builder

parseDelimitedFrom(InputStream input)

public static PreconditionFailure.Violation parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static PreconditionFailure.Violation parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static PreconditionFailure.Violation parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static PreconditionFailure.Violation parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static PreconditionFailure.Violation parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static PreconditionFailure.Violation parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static PreconditionFailure.Violation parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static PreconditionFailure.Violation parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static PreconditionFailure.Violation parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static PreconditionFailure.Violation parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static PreconditionFailure.Violation parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static PreconditionFailure.Violation parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PreconditionFailure.Violation
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<PreconditionFailure.Violation> parser()
Returns
TypeDescription
Parser<Violation>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public PreconditionFailure.Violation getDefaultInstanceForType()
Returns
TypeDescription
PreconditionFailure.Violation

getDescription()

public String getDescription()

A description of how the precondition failed. Developers can use this description to understand how to fix the failure. For example: "Terms of service not accepted".

string description = 3;

Returns
TypeDescription
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

A description of how the precondition failed. Developers can use this description to understand how to fix the failure. For example: "Terms of service not accepted".

string description = 3;

Returns
TypeDescription
ByteString

The bytes for description.

getParserForType()

public Parser<PreconditionFailure.Violation> getParserForType()
Returns
TypeDescription
Parser<Violation>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getSubject()

public String getSubject()

The subject, relative to the type, that failed. For example, "google.com/cloud" relative to the "TOS" type would indicate which terms of service is being referenced.

string subject = 2;

Returns
TypeDescription
String

The subject.

getSubjectBytes()

public ByteString getSubjectBytes()

The subject, relative to the type, that failed. For example, "google.com/cloud" relative to the "TOS" type would indicate which terms of service is being referenced.

string subject = 2;

Returns
TypeDescription
ByteString

The bytes for subject.

getType()

public String getType()

The type of PreconditionFailure. We recommend using a service-specific enum type to define the supported precondition violation subjects. For example, "TOS" for "Terms of Service violation".

string type = 1;

Returns
TypeDescription
String

The type.

getTypeBytes()

public ByteString getTypeBytes()

The type of PreconditionFailure. We recommend using a service-specific enum type to define the supported precondition violation subjects. For example, "TOS" for "Terms of Service violation".

string type = 1;

Returns
TypeDescription
ByteString

The bytes for type.

getUnknownFields()

public final UnknownFieldSet getUnknownFields()
Returns
TypeDescription
UnknownFieldSet
Overrides

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public PreconditionFailure.Violation.Builder newBuilderForType()
Returns
TypeDescription
PreconditionFailure.Violation.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected PreconditionFailure.Violation.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
PreconditionFailure.Violation.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public PreconditionFailure.Violation.Builder toBuilder()
Returns
TypeDescription
PreconditionFailure.Violation.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides Exceptions
TypeDescription
IOException