Package com.google.rpc.context
Class AttributeContext.Request
java.lang.Object
com.google.protobuf.AbstractMessageLite<MessageType,BuilderType>
com.google.protobuf.GeneratedMessageLite<AttributeContext.Request,AttributeContext.Request.Builder>
com.google.rpc.context.AttributeContext.Request
- All Implemented Interfaces:
com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,AttributeContext.RequestOrBuilder
- Enclosing class:
- AttributeContext
public static final class AttributeContext.Request
extends com.google.protobuf.GeneratedMessageLite<AttributeContext.Request,AttributeContext.Request.Builder>
implements AttributeContext.RequestOrBuilder
This message defines attributes for an HTTP request. If the actual request is not an HTTP request, the runtime system should try to map the actual request to an equivalent HTTP request.Protobuf type
google.rpc.context.AttributeContext.Request-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classThis message defines attributes for an HTTP request.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 intstatic final intstatic final intstatic final intstatic final intstatic 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 TypeMethodDescriptionbooleancontainsHeaders(String key) The HTTP request headers.protected final ObjectdynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) getAuth()The request authentication.static AttributeContext.RequestDeprecated.intThe HTTP request headers.The HTTP request headers.getHeadersOrDefault(String key, String defaultValue) The HTTP request headers.getHeadersOrThrow(String key) The HTTP request headers.getHost()The HTTP request `Host` header value.com.google.protobuf.ByteStringThe HTTP request `Host` header value.getId()The unique ID for a request, which can be propagated to downstream systems.com.google.protobuf.ByteStringThe unique ID for a request, which can be propagated to downstream systems.The HTTP request method, such as `GET`, `POST`.com.google.protobuf.ByteStringThe HTTP request method, such as `GET`, `POST`.getPath()The HTTP URL path, excluding the query parameters.com.google.protobuf.ByteStringThe HTTP URL path, excluding the query parameters.The network protocol used with the request, such as "http/1.1", "spdy/3", "h2", "h2c", "webrtc", "tcp", "udp", "quic".com.google.protobuf.ByteStringThe network protocol used with the request, such as "http/1.1", "spdy/3", "h2", "h2c", "webrtc", "tcp", "udp", "quic".getQuery()The HTTP URL query in the format of `name1=value1&name2=value2`, as it appears in the first line of the HTTP request.com.google.protobuf.ByteStringThe HTTP URL query in the format of `name1=value1&name2=value2`, as it appears in the first line of the HTTP request.A special parameter for request reason.com.google.protobuf.ByteStringA special parameter for request reason.The HTTP URL scheme, such as `http` and `https`.com.google.protobuf.ByteStringThe HTTP URL scheme, such as `http` and `https`.longgetSize()The HTTP request size in bytes.com.google.protobuf.TimestampgetTime()The timestamp when the `destination` service receives the last byte of the request.booleanhasAuth()The request authentication.booleanhasTime()The timestamp when the `destination` service receives the last byte of the request.newBuilder(AttributeContext.Request prototype) static AttributeContext.RequestparseDelimitedFrom(InputStream input) static AttributeContext.RequestparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static AttributeContext.RequestparseFrom(byte[] data) static AttributeContext.RequestparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static AttributeContext.RequestparseFrom(com.google.protobuf.ByteString data) static AttributeContext.RequestparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static AttributeContext.RequestparseFrom(com.google.protobuf.CodedInputStream input) static AttributeContext.RequestparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static AttributeContext.RequestparseFrom(InputStream input) static AttributeContext.RequestparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static AttributeContext.RequestparseFrom(ByteBuffer data) static AttributeContext.RequestparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<AttributeContext.Request>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
-
ID_FIELD_NUMBER
public static final int ID_FIELD_NUMBER- See Also:
-
METHOD_FIELD_NUMBER
public static final int METHOD_FIELD_NUMBER- See Also:
-
HEADERS_FIELD_NUMBER
public static final int HEADERS_FIELD_NUMBER- See Also:
-
PATH_FIELD_NUMBER
public static final int PATH_FIELD_NUMBER- See Also:
-
HOST_FIELD_NUMBER
public static final int HOST_FIELD_NUMBER- See Also:
-
SCHEME_FIELD_NUMBER
public static final int SCHEME_FIELD_NUMBER- See Also:
-
QUERY_FIELD_NUMBER
public static final int QUERY_FIELD_NUMBER- See Also:
-
TIME_FIELD_NUMBER
public static final int TIME_FIELD_NUMBER- See Also:
-
SIZE_FIELD_NUMBER
public static final int SIZE_FIELD_NUMBER- See Also:
-
PROTOCOL_FIELD_NUMBER
public static final int PROTOCOL_FIELD_NUMBER- See Also:
-
REASON_FIELD_NUMBER
public static final int REASON_FIELD_NUMBER- See Also:
-
AUTH_FIELD_NUMBER
public static final int AUTH_FIELD_NUMBER- See Also:
-
-
Method Details
-
getId
The unique ID for a request, which can be propagated to downstream systems. The ID should have low probability of collision within a single day for a specific service.
string id = 1 [json_name = "id"];- Specified by:
getIdin interfaceAttributeContext.RequestOrBuilder- Returns:
- The id.
-
getIdBytes
public com.google.protobuf.ByteString getIdBytes()The unique ID for a request, which can be propagated to downstream systems. The ID should have low probability of collision within a single day for a specific service.
string id = 1 [json_name = "id"];- Specified by:
getIdBytesin interfaceAttributeContext.RequestOrBuilder- Returns:
- The bytes for id.
-
getMethod
The HTTP request method, such as `GET`, `POST`.
string method = 2 [json_name = "method"];- Specified by:
getMethodin interfaceAttributeContext.RequestOrBuilder- Returns:
- The method.
-
getMethodBytes
public com.google.protobuf.ByteString getMethodBytes()The HTTP request method, such as `GET`, `POST`.
string method = 2 [json_name = "method"];- Specified by:
getMethodBytesin interfaceAttributeContext.RequestOrBuilder- Returns:
- The bytes for method.
-
getHeadersCount
public int getHeadersCount()Description copied from interface:AttributeContext.RequestOrBuilderThe HTTP request headers. If multiple headers share the same key, they must be merged according to the HTTP spec. All header keys must be lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3 [json_name = "headers"];- Specified by:
getHeadersCountin interfaceAttributeContext.RequestOrBuilder
-
containsHeaders
The HTTP request headers. If multiple headers share the same key, they must be merged according to the HTTP spec. All header keys must be lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3 [json_name = "headers"];- Specified by:
containsHeadersin interfaceAttributeContext.RequestOrBuilder
-
getHeaders
Deprecated.UsegetHeadersMap()instead.- Specified by:
getHeadersin interfaceAttributeContext.RequestOrBuilder
-
getHeadersMap
The HTTP request headers. If multiple headers share the same key, they must be merged according to the HTTP spec. All header keys must be lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3 [json_name = "headers"];- Specified by:
getHeadersMapin interfaceAttributeContext.RequestOrBuilder
-
getHeadersOrDefault
The HTTP request headers. If multiple headers share the same key, they must be merged according to the HTTP spec. All header keys must be lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3 [json_name = "headers"];- Specified by:
getHeadersOrDefaultin interfaceAttributeContext.RequestOrBuilder
-
getHeadersOrThrow
The HTTP request headers. If multiple headers share the same key, they must be merged according to the HTTP spec. All header keys must be lowercased, because HTTP header keys are case-insensitive.
map<string, string> headers = 3 [json_name = "headers"];- Specified by:
getHeadersOrThrowin interfaceAttributeContext.RequestOrBuilder
-
getPath
The HTTP URL path, excluding the query parameters.
string path = 4 [json_name = "path"];- Specified by:
getPathin interfaceAttributeContext.RequestOrBuilder- Returns:
- The path.
-
getPathBytes
public com.google.protobuf.ByteString getPathBytes()The HTTP URL path, excluding the query parameters.
string path = 4 [json_name = "path"];- Specified by:
getPathBytesin interfaceAttributeContext.RequestOrBuilder- Returns:
- The bytes for path.
-
getHost
The HTTP request `Host` header value.
string host = 5 [json_name = "host"];- Specified by:
getHostin interfaceAttributeContext.RequestOrBuilder- Returns:
- The host.
-
getHostBytes
public com.google.protobuf.ByteString getHostBytes()The HTTP request `Host` header value.
string host = 5 [json_name = "host"];- Specified by:
getHostBytesin interfaceAttributeContext.RequestOrBuilder- Returns:
- The bytes for host.
-
getScheme
The HTTP URL scheme, such as `http` and `https`.
string scheme = 6 [json_name = "scheme"];- Specified by:
getSchemein interfaceAttributeContext.RequestOrBuilder- Returns:
- The scheme.
-
getSchemeBytes
public com.google.protobuf.ByteString getSchemeBytes()The HTTP URL scheme, such as `http` and `https`.
string scheme = 6 [json_name = "scheme"];- Specified by:
getSchemeBytesin interfaceAttributeContext.RequestOrBuilder- Returns:
- The bytes for scheme.
-
getQuery
The HTTP URL query in the format of `name1=value1&name2=value2`, as it appears in the first line of the HTTP request. No decoding is performed.
string query = 7 [json_name = "query"];- Specified by:
getQueryin interfaceAttributeContext.RequestOrBuilder- Returns:
- The query.
-
getQueryBytes
public com.google.protobuf.ByteString getQueryBytes()The HTTP URL query in the format of `name1=value1&name2=value2`, as it appears in the first line of the HTTP request. No decoding is performed.
string query = 7 [json_name = "query"];- Specified by:
getQueryBytesin interfaceAttributeContext.RequestOrBuilder- Returns:
- The bytes for query.
-
hasTime
public boolean hasTime()The timestamp when the `destination` service receives the last byte of the request.
.google.protobuf.Timestamp time = 9 [json_name = "time"];- Specified by:
hasTimein interfaceAttributeContext.RequestOrBuilder- Returns:
- Whether the time field is set.
-
getTime
public com.google.protobuf.Timestamp getTime()The timestamp when the `destination` service receives the last byte of the request.
.google.protobuf.Timestamp time = 9 [json_name = "time"];- Specified by:
getTimein interfaceAttributeContext.RequestOrBuilder- Returns:
- The time.
-
getSize
public long getSize()The HTTP request size in bytes. If unknown, it must be -1.
int64 size = 10 [json_name = "size"];- Specified by:
getSizein interfaceAttributeContext.RequestOrBuilder- Returns:
- The size.
-
getProtocol
The network protocol used with the request, such as "http/1.1", "spdy/3", "h2", "h2c", "webrtc", "tcp", "udp", "quic". See https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids for details.
string protocol = 11 [json_name = "protocol"];- Specified by:
getProtocolin interfaceAttributeContext.RequestOrBuilder- Returns:
- The protocol.
-
getProtocolBytes
public com.google.protobuf.ByteString getProtocolBytes()The network protocol used with the request, such as "http/1.1", "spdy/3", "h2", "h2c", "webrtc", "tcp", "udp", "quic". See https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids for details.
string protocol = 11 [json_name = "protocol"];- Specified by:
getProtocolBytesin interfaceAttributeContext.RequestOrBuilder- Returns:
- The bytes for protocol.
-
getReason
A special parameter for request reason. It is used by security systems to associate auditing information with a request.
string reason = 12 [json_name = "reason"];- Specified by:
getReasonin interfaceAttributeContext.RequestOrBuilder- Returns:
- The reason.
-
getReasonBytes
public com.google.protobuf.ByteString getReasonBytes()A special parameter for request reason. It is used by security systems to associate auditing information with a request.
string reason = 12 [json_name = "reason"];- Specified by:
getReasonBytesin interfaceAttributeContext.RequestOrBuilder- Returns:
- The bytes for reason.
-
hasAuth
public boolean hasAuth()The request authentication. May be absent for unauthenticated requests. Derived from the HTTP request `Authorization` header or equivalent.
.google.rpc.context.AttributeContext.Auth auth = 13 [json_name = "auth"];- Specified by:
hasAuthin interfaceAttributeContext.RequestOrBuilder- Returns:
- Whether the auth field is set.
-
getAuth
The request authentication. May be absent for unauthenticated requests. Derived from the HTTP request `Authorization` header or equivalent.
.google.rpc.context.AttributeContext.Auth auth = 13 [json_name = "auth"];- Specified by:
getAuthin interfaceAttributeContext.RequestOrBuilder- Returns:
- The auth.
-
parseFrom
public static AttributeContext.Request parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Request parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Request parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Request parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Request parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Request parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static AttributeContext.Request parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static AttributeContext.Request parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
public static AttributeContext.Request parseFrom(com.google.protobuf.CodedInputStream input) throws IOException - Throws:
IOException
-
parseFrom
public static AttributeContext.Request 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<AttributeContext.Request,AttributeContext.Request.Builder>
-
getDefaultInstance
-
parser
-