Package com.google.rpc.context
Class AttributeContext.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder<MessageType,BuilderType>
com.google.protobuf.GeneratedMessageLite.Builder<AttributeContext,AttributeContext.Builder>
com.google.rpc.context.AttributeContext.Builder
- All Implemented Interfaces:
com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,AttributeContextOrBuilder
,Cloneable
- Enclosing class:
- AttributeContext
public static final class AttributeContext.Builder
extends com.google.protobuf.GeneratedMessageLite.Builder<AttributeContext,AttributeContext.Builder>
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
-
Field Summary
Fields inherited from class com.google.protobuf.GeneratedMessageLite.Builder
instance
-
Method Summary
Modifier and TypeMethodDescriptionaddAllExtensions
(Iterable<? extends com.google.protobuf.Any> values) Supports extensions for advanced use cases, such as logs and metrics.addExtensions
(int index, com.google.protobuf.Any value) Supports extensions for advanced use cases, such as logs and metrics.addExtensions
(int index, com.google.protobuf.Any.Builder builderForValue) Supports extensions for advanced use cases, such as logs and metrics.addExtensions
(com.google.protobuf.Any value) Supports extensions for advanced use cases, such as logs and metrics.addExtensions
(com.google.protobuf.Any.Builder builderForValue) Supports extensions for advanced use cases, such as logs and metrics.clearApi()
Represents an API operation that is involved to a network activity.The destination of a network activity, such as accepting a TCP connection.Supports extensions for advanced use cases, such as logs and metrics.The origin of a network activity.Represents a network request, such as an HTTP request.Represents a target resource that is involved with a network activity.Represents a network response, such as an HTTP response.The source of a network activity, such as starting a TCP connection.getApi()
Represents an API operation that is involved to a network activity.The destination of a network activity, such as accepting a TCP connection.com.google.protobuf.Any
getExtensions
(int index) Supports extensions for advanced use cases, such as logs and metrics.int
Supports extensions for advanced use cases, such as logs and metrics.List<com.google.protobuf.Any>
Supports extensions for advanced use cases, such as logs and metrics.The origin of a network activity.Represents a network request, such as an HTTP request.Represents a target resource that is involved with a network activity.Represents a network response, such as an HTTP response.The source of a network activity, such as starting a TCP connection.boolean
hasApi()
Represents an API operation that is involved to a network activity.boolean
The destination of a network activity, such as accepting a TCP connection.boolean
The origin of a network activity.boolean
Represents a network request, such as an HTTP request.boolean
Represents a target resource that is involved with a network activity.boolean
Represents a network response, such as an HTTP response.boolean
The source of a network activity, such as starting a TCP connection.mergeApi
(AttributeContext.Api value) Represents an API operation that is involved to a network activity.The destination of a network activity, such as accepting a TCP connection.mergeOrigin
(AttributeContext.Peer value) The origin of a network activity.Represents a network request, such as an HTTP request.Represents a target resource that is involved with a network activity.Represents a network response, such as an HTTP response.mergeSource
(AttributeContext.Peer value) The source of a network activity, such as starting a TCP connection.removeExtensions
(int index) Supports extensions for advanced use cases, such as logs and metrics.setApi
(AttributeContext.Api value) Represents an API operation that is involved to a network activity.setApi
(AttributeContext.Api.Builder builderForValue) Represents an API operation that is involved to a network activity.The destination of a network activity, such as accepting a TCP connection.setDestination
(AttributeContext.Peer.Builder builderForValue) The destination of a network activity, such as accepting a TCP connection.setExtensions
(int index, com.google.protobuf.Any value) Supports extensions for advanced use cases, such as logs and metrics.setExtensions
(int index, com.google.protobuf.Any.Builder builderForValue) Supports extensions for advanced use cases, such as logs and metrics.setOrigin
(AttributeContext.Peer value) The origin of a network activity.setOrigin
(AttributeContext.Peer.Builder builderForValue) The origin of a network activity.Represents a network request, such as an HTTP request.setRequest
(AttributeContext.Request.Builder builderForValue) Represents a network request, such as an HTTP request.Represents a target resource that is involved with a network activity.setResource
(AttributeContext.Resource.Builder builderForValue) Represents a target resource that is involved with a network activity.Represents a network response, such as an HTTP response.setResponse
(AttributeContext.Response.Builder builderForValue) Represents a network response, such as an HTTP response.setSource
(AttributeContext.Peer value) The source of a network activity, such as starting a TCP connection.setSource
(AttributeContext.Peer.Builder builderForValue) The source of a network activity, such as starting a TCP connection.Methods inherited from class com.google.protobuf.GeneratedMessageLite.Builder
build, buildPartial, clear, clone, copyOnWrite, copyOnWriteInternal, getDefaultInstanceForType, internalMergeFrom, isInitialized, mergeFrom, mergeFrom, mergeFrom, mergeFrom
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Method Details
-
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 [json_name = "origin"];
- Specified by:
hasOrigin
in interfaceAttributeContextOrBuilder
- Returns:
- Whether the origin field is set.
-
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 [json_name = "origin"];
- Specified by:
getOrigin
in interfaceAttributeContextOrBuilder
- Returns:
- The origin.
-
setOrigin
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 [json_name = "origin"];
-
setOrigin
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 [json_name = "origin"];
-
mergeOrigin
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 [json_name = "origin"];
-
clearOrigin
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 [json_name = "origin"];
-
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 [json_name = "source"];
- Specified by:
hasSource
in interfaceAttributeContextOrBuilder
- Returns:
- Whether the source field is set.
-
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 [json_name = "source"];
- Specified by:
getSource
in interfaceAttributeContextOrBuilder
- Returns:
- The source.
-
setSource
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 [json_name = "source"];
-
setSource
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 [json_name = "source"];
-
mergeSource
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 [json_name = "source"];
-
clearSource
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 [json_name = "source"];
-
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 [json_name = "destination"];
- Specified by:
hasDestination
in interfaceAttributeContextOrBuilder
- Returns:
- Whether the destination field is set.
-
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 [json_name = "destination"];
- Specified by:
getDestination
in interfaceAttributeContextOrBuilder
- Returns:
- The destination.
-
setDestination
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 [json_name = "destination"];
-
setDestination
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 [json_name = "destination"];
-
mergeDestination
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 [json_name = "destination"];
-
clearDestination
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 [json_name = "destination"];
-
hasRequest
public boolean hasRequest()Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3 [json_name = "request"];
- Specified by:
hasRequest
in interfaceAttributeContextOrBuilder
- Returns:
- Whether the request field is set.
-
getRequest
Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3 [json_name = "request"];
- Specified by:
getRequest
in interfaceAttributeContextOrBuilder
- Returns:
- The request.
-
setRequest
Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3 [json_name = "request"];
-
setRequest
Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3 [json_name = "request"];
-
mergeRequest
Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3 [json_name = "request"];
-
clearRequest
Represents a network request, such as an HTTP request.
.google.rpc.context.AttributeContext.Request request = 3 [json_name = "request"];
-
hasResponse
public boolean hasResponse()Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4 [json_name = "response"];
- Specified by:
hasResponse
in interfaceAttributeContextOrBuilder
- Returns:
- Whether the response field is set.
-
getResponse
Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4 [json_name = "response"];
- Specified by:
getResponse
in interfaceAttributeContextOrBuilder
- Returns:
- The response.
-
setResponse
Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4 [json_name = "response"];
-
setResponse
Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4 [json_name = "response"];
-
mergeResponse
Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4 [json_name = "response"];
-
clearResponse
Represents a network response, such as an HTTP response.
.google.rpc.context.AttributeContext.Response response = 4 [json_name = "response"];
-
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 [json_name = "resource"];
- Specified by:
hasResource
in interfaceAttributeContextOrBuilder
- Returns:
- Whether the resource field is set.
-
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 [json_name = "resource"];
- Specified by:
getResource
in interfaceAttributeContextOrBuilder
- Returns:
- The resource.
-
setResource
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 [json_name = "resource"];
-
setResource
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 [json_name = "resource"];
-
mergeResource
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 [json_name = "resource"];
-
clearResource
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 [json_name = "resource"];
-
hasApi
public boolean hasApi()Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6 [json_name = "api"];
- Specified by:
hasApi
in interfaceAttributeContextOrBuilder
- Returns:
- Whether the api field is set.
-
getApi
Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6 [json_name = "api"];
- Specified by:
getApi
in interfaceAttributeContextOrBuilder
- Returns:
- The api.
-
setApi
Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6 [json_name = "api"];
-
setApi
Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6 [json_name = "api"];
-
mergeApi
Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6 [json_name = "api"];
-
clearApi
Represents an API operation that is involved to a network activity.
.google.rpc.context.AttributeContext.Api api = 6 [json_name = "api"];
-
getExtensionsList
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
- Specified by:
getExtensionsList
in interfaceAttributeContextOrBuilder
-
getExtensionsCount
public int getExtensionsCount()Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
- Specified by:
getExtensionsCount
in interfaceAttributeContextOrBuilder
-
getExtensions
public com.google.protobuf.Any getExtensions(int index) Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
- Specified by:
getExtensions
in interfaceAttributeContextOrBuilder
-
setExtensions
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-
setExtensions
public AttributeContext.Builder setExtensions(int index, com.google.protobuf.Any.Builder builderForValue) Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-
addExtensions
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-
addExtensions
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-
addExtensions
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-
addExtensions
public AttributeContext.Builder addExtensions(int index, com.google.protobuf.Any.Builder builderForValue) Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-
addAllExtensions
public AttributeContext.Builder addAllExtensions(Iterable<? extends com.google.protobuf.Any> values) Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-
clearExtensions
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-
removeExtensions
Supports extensions for advanced use cases, such as logs and metrics.
repeated .google.protobuf.Any extensions = 8 [json_name = "extensions"];
-