public final class AttributeContext extends GeneratedMessageV3 implements AttributeContextOrBuilder
This message defines the standard attribute vocabulary for Google APIs.
An attribute is a piece of metadata that describes an activity on a network
service. For example, the size of an HTTP request, or the status code of
an HTTP response.
Each attribute has a type and a name, which is logically defined as
a proto message field in AttributeContext
. The field type becomes the
attribute type, and the field path becomes the attribute name. For example,
the attribute source.ip
maps to field AttributeContext.source.ip
.
This message definition is guaranteed not to have any wire breaking change.
So you can use it directly for passing attributes across different systems.
NOTE: Different system may generate different subset of attributes. Please
verify the system specification before relying on an attribute generated
a system.
Protobuf type google.rpc.context.AttributeContext
Inherited Members
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)
Static Fields
API_FIELD_NUMBER
public static final int API_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
DESTINATION_FIELD_NUMBER
public static final int DESTINATION_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
EXTENSIONS_FIELD_NUMBER
public static final int EXTENSIONS_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
ORIGIN_FIELD_NUMBER
public static final int ORIGIN_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
REQUEST_FIELD_NUMBER
public static final int REQUEST_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
RESOURCE_FIELD_NUMBER
public static final int RESOURCE_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
RESPONSE_FIELD_NUMBER
public static final int RESPONSE_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
SOURCE_FIELD_NUMBER
public static final int SOURCE_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
Static Methods
getDefaultInstance()
public static AttributeContext getDefaultInstance()
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static AttributeContext.Builder newBuilder()
newBuilder(AttributeContext prototype)
public static AttributeContext.Builder newBuilder(AttributeContext prototype)
parseDelimitedFrom(InputStream input)
public static AttributeContext parseDelimitedFrom(InputStream input)
parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
public static AttributeContext parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(byte[] data)
public static AttributeContext parseFrom(byte[] data)
Parameter |
---|
Name | Description |
data | byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static AttributeContext parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteString data)
public static AttributeContext parseFrom(ByteString data)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static AttributeContext parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
parseFrom(CodedInputStream input)
public static AttributeContext parseFrom(CodedInputStream input)
parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static AttributeContext parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(InputStream input)
public static AttributeContext parseFrom(InputStream input)
parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
public static AttributeContext parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteBuffer data)
public static AttributeContext parseFrom(ByteBuffer data)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static AttributeContext parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
parser()
public static Parser<AttributeContext> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter |
---|
Name | Description |
obj | Object
|
Overrides
getApi()
public AttributeContext.Api getApi()
Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6;
getApiOrBuilder()
public AttributeContext.ApiOrBuilder getApiOrBuilder()
Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6;
getDefaultInstanceForType()
public AttributeContext getDefaultInstanceForType()
getDestination()
public AttributeContext.Peer getDestination()
The destination of a network activity, such as accepting a TCP connection.
In a multi hop network activity, the destination represents the receiver of
the last hop.
.google.rpc.context.AttributeContext.Peer destination = 2;
getDestinationOrBuilder()
public AttributeContext.PeerOrBuilder getDestinationOrBuilder()
The destination of a network activity, such as accepting a TCP connection.
In a multi hop network activity, the destination represents the receiver of
the last hop.
.google.rpc.context.AttributeContext.Peer destination = 2;
getExtensions(int index)
public Any getExtensions(int index)
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8;
Parameter |
---|
Name | Description |
index | int
|
Returns |
---|
Type | Description |
Any | |
getExtensionsCount()
public int getExtensionsCount()
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8;
Returns |
---|
Type | Description |
int | |
getExtensionsList()
public List<Any> getExtensionsList()
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8;
getExtensionsOrBuilder(int index)
public AnyOrBuilder getExtensionsOrBuilder(int index)
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8;
Parameter |
---|
Name | Description |
index | int
|
getExtensionsOrBuilderList()
public List<? extends AnyOrBuilder> getExtensionsOrBuilderList()
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8;
Returns |
---|
Type | Description |
List<? extends com.google.protobuf.AnyOrBuilder> | |
getOrigin()
public AttributeContext.Peer getOrigin()
The origin of a network activity. In a multi hop network activity,
the origin represents the sender of the first hop. For the first hop,
the source
and the origin
must have the same content.
.google.rpc.context.AttributeContext.Peer origin = 7;
getOriginOrBuilder()
public AttributeContext.PeerOrBuilder getOriginOrBuilder()
The origin of a network activity. In a multi hop network activity,
the origin represents the sender of the first hop. For the first hop,
the source
and the origin
must have the same content.
.google.rpc.context.AttributeContext.Peer origin = 7;
getParserForType()
public Parser<AttributeContext> getParserForType()
Overrides
getRequest()
public AttributeContext.Request getRequest()
Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3;
getRequestOrBuilder()
public AttributeContext.RequestOrBuilder getRequestOrBuilder()
Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3;
getResource()
public AttributeContext.Resource getResource()
Represents a target resource that is involved with a network activity.
If multiple resources are involved with an activity, this must be the
primary one.
.google.rpc.context.AttributeContext.Resource resource = 5;
getResourceOrBuilder()
public AttributeContext.ResourceOrBuilder getResourceOrBuilder()
Represents a target resource that is involved with a network activity.
If multiple resources are involved with an activity, this must be the
primary one.
.google.rpc.context.AttributeContext.Resource resource = 5;
getResponse()
public AttributeContext.Response getResponse()
Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4;
getResponseOrBuilder()
public AttributeContext.ResponseOrBuilder getResponseOrBuilder()
Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4;
getSerializedSize()
public int getSerializedSize()
Returns |
---|
Type | Description |
int | |
Overrides
getSource()
public AttributeContext.Peer getSource()
The source of a network activity, such as starting a TCP connection.
In a multi hop network activity, the source represents the sender of the
last hop.
.google.rpc.context.AttributeContext.Peer source = 1;
getSourceOrBuilder()
public AttributeContext.PeerOrBuilder getSourceOrBuilder()
The source of a network activity, such as starting a TCP connection.
In a multi hop network activity, the source represents the sender of the
last hop.
.google.rpc.context.AttributeContext.Peer source = 1;
hasApi()
Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6;
Returns |
---|
Type | Description |
boolean | Whether the api field is set.
|
hasDestination()
public boolean hasDestination()
The destination of a network activity, such as accepting a TCP connection.
In a multi hop network activity, the destination represents the receiver of
the last hop.
.google.rpc.context.AttributeContext.Peer destination = 2;
Returns |
---|
Type | Description |
boolean | Whether the destination field is set.
|
hasOrigin()
public boolean hasOrigin()
The origin of a network activity. In a multi hop network activity,
the origin represents the sender of the first hop. For the first hop,
the source
and the origin
must have the same content.
.google.rpc.context.AttributeContext.Peer origin = 7;
Returns |
---|
Type | Description |
boolean | Whether the origin field is set.
|
hasRequest()
public boolean hasRequest()
Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3;
Returns |
---|
Type | Description |
boolean | Whether the request field is set.
|
hasResource()
public boolean hasResource()
Represents a target resource that is involved with a network activity.
If multiple resources are involved with an activity, this must be the
primary one.
.google.rpc.context.AttributeContext.Resource resource = 5;
Returns |
---|
Type | Description |
boolean | Whether the resource field is set.
|
hasResponse()
public boolean hasResponse()
Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4;
Returns |
---|
Type | Description |
boolean | Whether the response field is set.
|
hasSource()
public boolean hasSource()
The source of a network activity, such as starting a TCP connection.
In a multi hop network activity, the source represents the sender of the
last hop.
.google.rpc.context.AttributeContext.Peer source = 1;
Returns |
---|
Type | Description |
boolean | Whether the source field is set.
|
hashCode()
Returns |
---|
Type | Description |
int | |
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public AttributeContext.Builder newBuilderForType()
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected AttributeContext.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Overrides
toBuilder()
public AttributeContext.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides