public static final class AttributeContext.Response.Builder extends GeneratedMessageV3.Builder<AttributeContext.Response.Builder> implements AttributeContext.ResponseOrBuilder
This message defines attributes for a typical network response. It
generally models semantics of an HTTP response.
Protobuf type google.rpc.context.AttributeContext.Response
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public AttributeContext.Response.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
public AttributeContext.Response build()
Returns
buildPartial()
public AttributeContext.Response buildPartial()
Returns
clear()
public AttributeContext.Response.Builder clear()
Returns
Overrides
clearBackendLatency()
public AttributeContext.Response.Builder clearBackendLatency()
The length of time it takes the backend service to fully respond to a
request. Measured from when the destination service starts to send the
request to the backend until when the destination service receives the
complete response from the backend.
.google.protobuf.Duration backend_latency = 5;
Returns
clearCode()
public AttributeContext.Response.Builder clearCode()
The HTTP response status code, such as 200
and 404
.
int64 code = 1;
Returns
clearField(Descriptors.FieldDescriptor field)
public AttributeContext.Response.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
public AttributeContext.Response.Builder clearHeaders()
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public AttributeContext.Response.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clearSize()
public AttributeContext.Response.Builder clearSize()
The HTTP response size in bytes. If unknown, it must be -1.
int64 size = 2;
Returns
clearTime()
public AttributeContext.Response.Builder clearTime()
The timestamp when the destination
service sends the last byte of
the response.
.google.protobuf.Timestamp time = 4;
Returns
clone()
public AttributeContext.Response.Builder clone()
Returns
Overrides
public boolean containsHeaders(String key)
The HTTP response headers. If multiple headers share the same key, they
must be merged according to HTTP spec. All header keys must be
lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3;
Parameter
Returns
getBackendLatency()
public Duration getBackendLatency()
The length of time it takes the backend service to fully respond to a
request. Measured from when the destination service starts to send the
request to the backend until when the destination service receives the
complete response from the backend.
.google.protobuf.Duration backend_latency = 5;
Returns
Type | Description |
Duration | The backendLatency.
|
getBackendLatencyBuilder()
public Duration.Builder getBackendLatencyBuilder()
The length of time it takes the backend service to fully respond to a
request. Measured from when the destination service starts to send the
request to the backend until when the destination service receives the
complete response from the backend.
.google.protobuf.Duration backend_latency = 5;
Returns
getBackendLatencyOrBuilder()
public DurationOrBuilder getBackendLatencyOrBuilder()
The length of time it takes the backend service to fully respond to a
request. Measured from when the destination service starts to send the
request to the backend until when the destination service receives the
complete response from the backend.
.google.protobuf.Duration backend_latency = 5;
Returns
getCode()
The HTTP response status code, such as 200
and 404
.
int64 code = 1;
Returns
Type | Description |
long | The code.
|
getDefaultInstanceForType()
public AttributeContext.Response getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
public Map<String,String> getHeaders()
Returns
public int getHeadersCount()
The HTTP response headers. If multiple headers share the same key, they
must be merged according to HTTP spec. All header keys must be
lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3;
Returns
public Map<String,String> getHeadersMap()
The HTTP response headers. If multiple headers share the same key, they
must be merged according to HTTP spec. All header keys must be
lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3;
Returns
public String getHeadersOrDefault(String key, String defaultValue)
The HTTP response headers. If multiple headers share the same key, they
must be merged according to HTTP spec. All header keys must be
lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3;
Parameters
Returns
public String getHeadersOrThrow(String key)
The HTTP response headers. If multiple headers share the same key, they
must be merged according to HTTP spec. All header keys must be
lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3;
Parameter
Returns
public Map<String,String> getMutableHeaders()
Use alternate mutation accessors instead.
Returns
getSize()
The HTTP response size in bytes. If unknown, it must be -1.
int64 size = 2;
Returns
Type | Description |
long | The size.
|
getTime()
public Timestamp getTime()
The timestamp when the destination
service sends the last byte of
the response.
.google.protobuf.Timestamp time = 4;
Returns
getTimeBuilder()
public Timestamp.Builder getTimeBuilder()
The timestamp when the destination
service sends the last byte of
the response.
.google.protobuf.Timestamp time = 4;
Returns
getTimeOrBuilder()
public TimestampOrBuilder getTimeOrBuilder()
The timestamp when the destination
service sends the last byte of
the response.
.google.protobuf.Timestamp time = 4;
Returns
hasBackendLatency()
public boolean hasBackendLatency()
The length of time it takes the backend service to fully respond to a
request. Measured from when the destination service starts to send the
request to the backend until when the destination service receives the
complete response from the backend.
.google.protobuf.Duration backend_latency = 5;
Returns
Type | Description |
boolean | Whether the backendLatency field is set.
|
hasTime()
The timestamp when the destination
service sends the last byte of
the response.
.google.protobuf.Timestamp time = 4;
Returns
Type | Description |
boolean | Whether the time field is set.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Parameter
Returns
Overrides
internalGetMutableMapField(int number)
protected MapField internalGetMutableMapField(int number)
Parameter
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeBackendLatency(Duration value)
public AttributeContext.Response.Builder mergeBackendLatency(Duration value)
The length of time it takes the backend service to fully respond to a
request. Measured from when the destination service starts to send the
request to the backend until when the destination service receives the
complete response from the backend.
.google.protobuf.Duration backend_latency = 5;
Parameter
Returns
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public AttributeContext.Response.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public AttributeContext.Response.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeFrom(AttributeContext.Response other)
public AttributeContext.Response.Builder mergeFrom(AttributeContext.Response other)
Parameter
Returns
mergeTime(Timestamp value)
public AttributeContext.Response.Builder mergeTime(Timestamp value)
The timestamp when the destination
service sends the last byte of
the response.
.google.protobuf.Timestamp time = 4;
Parameter
Returns
mergeUnknownFields(UnknownFieldSet unknownFields)
public final AttributeContext.Response.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
public AttributeContext.Response.Builder putAllHeaders(Map<String,String> values)
The HTTP response headers. If multiple headers share the same key, they
must be merged according to HTTP spec. All header keys must be
lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3;
Parameter
Returns
public AttributeContext.Response.Builder putHeaders(String key, String value)
The HTTP response headers. If multiple headers share the same key, they
must be merged according to HTTP spec. All header keys must be
lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3;
Parameters
Returns
public AttributeContext.Response.Builder removeHeaders(String key)
The HTTP response headers. If multiple headers share the same key, they
must be merged according to HTTP spec. All header keys must be
lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3;
Parameter
Returns
setBackendLatency(Duration value)
public AttributeContext.Response.Builder setBackendLatency(Duration value)
The length of time it takes the backend service to fully respond to a
request. Measured from when the destination service starts to send the
request to the backend until when the destination service receives the
complete response from the backend.
.google.protobuf.Duration backend_latency = 5;
Parameter
Returns
setBackendLatency(Duration.Builder builderForValue)
public AttributeContext.Response.Builder setBackendLatency(Duration.Builder builderForValue)
The length of time it takes the backend service to fully respond to a
request. Measured from when the destination service starts to send the
request to the backend until when the destination service receives the
complete response from the backend.
.google.protobuf.Duration backend_latency = 5;
Parameter
Name | Description |
builderForValue | Builder
|
Returns
setCode(long value)
public AttributeContext.Response.Builder setCode(long value)
The HTTP response status code, such as 200
and 404
.
int64 code = 1;
Parameter
Name | Description |
value | long
The code to set.
|
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public AttributeContext.Response.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public AttributeContext.Response.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setSize(long value)
public AttributeContext.Response.Builder setSize(long value)
The HTTP response size in bytes. If unknown, it must be -1.
int64 size = 2;
Parameter
Name | Description |
value | long
The size to set.
|
Returns
setTime(Timestamp value)
public AttributeContext.Response.Builder setTime(Timestamp value)
The timestamp when the destination
service sends the last byte of
the response.
.google.protobuf.Timestamp time = 4;
Parameter
Returns
setTime(Timestamp.Builder builderForValue)
public AttributeContext.Response.Builder setTime(Timestamp.Builder builderForValue)
The timestamp when the destination
service sends the last byte of
the response.
.google.protobuf.Timestamp time = 4;
Parameter
Name | Description |
builderForValue | Builder
|
Returns
setUnknownFields(UnknownFieldSet unknownFields)
public final AttributeContext.Response.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides