Class AttributeContext.HttpRequest.Builder

    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetMapField

        protected com.google.protobuf.MapField internalGetMapField​(int number)
        Overrides:
        internalGetMapField in class com.google.protobuf.GeneratedMessageV3.Builder<AttributeContext.HttpRequest.Builder>
      • internalGetMutableMapField

        protected com.google.protobuf.MapField internalGetMutableMapField​(int number)
        Overrides:
        internalGetMutableMapField in class com.google.protobuf.GeneratedMessageV3.Builder<AttributeContext.HttpRequest.Builder>
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<AttributeContext.HttpRequest.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<AttributeContext.HttpRequest.Builder>
      • getDefaultInstanceForType

        public AttributeContext.HttpRequest getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public AttributeContext.HttpRequest build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public AttributeContext.HttpRequest buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<AttributeContext.HttpRequest.Builder>
      • mergeFrom

        public AttributeContext.HttpRequest.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                       throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<AttributeContext.HttpRequest.Builder>
        Throws:
        IOException
      • getId

        public String 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.
         For HTTP requests, it should be X-Request-ID or equivalent.
         
        string id = 1;
        Specified by:
        getId in interface AttributeContext.HttpRequestOrBuilder
        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.
         For HTTP requests, it should be X-Request-ID or equivalent.
         
        string id = 1;
        Specified by:
        getIdBytes in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The bytes for id.
      • setId

        public AttributeContext.HttpRequest.Builder setId​(String value)
         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.
         For HTTP requests, it should be X-Request-ID or equivalent.
         
        string id = 1;
        Parameters:
        value - The id to set.
        Returns:
        This builder for chaining.
      • clearId

        public AttributeContext.HttpRequest.Builder clearId()
         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.
         For HTTP requests, it should be X-Request-ID or equivalent.
         
        string id = 1;
        Returns:
        This builder for chaining.
      • setIdBytes

        public AttributeContext.HttpRequest.Builder setIdBytes​(com.google.protobuf.ByteString value)
         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.
         For HTTP requests, it should be X-Request-ID or equivalent.
         
        string id = 1;
        Parameters:
        value - The bytes for id to set.
        Returns:
        This builder for chaining.
      • getMethodBytes

        public com.google.protobuf.ByteString getMethodBytes()
         The HTTP request method, such as ``GET``, ``POST``.
         
        string method = 2;
        Specified by:
        getMethodBytes in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The bytes for method.
      • setMethod

        public AttributeContext.HttpRequest.Builder setMethod​(String value)
         The HTTP request method, such as ``GET``, ``POST``.
         
        string method = 2;
        Parameters:
        value - The method to set.
        Returns:
        This builder for chaining.
      • clearMethod

        public AttributeContext.HttpRequest.Builder clearMethod()
         The HTTP request method, such as ``GET``, ``POST``.
         
        string method = 2;
        Returns:
        This builder for chaining.
      • setMethodBytes

        public AttributeContext.HttpRequest.Builder setMethodBytes​(com.google.protobuf.ByteString value)
         The HTTP request method, such as ``GET``, ``POST``.
         
        string method = 2;
        Parameters:
        value - The bytes for method to set.
        Returns:
        This builder for chaining.
      • containsHeaders

        public boolean containsHeaders​(String key)
         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
         lower-cased, because HTTP header keys are case-insensitive.
         
        map<string, string> headers = 3;
        Specified by:
        containsHeaders in interface AttributeContext.HttpRequestOrBuilder
      • getHeadersMap

        public Map<String,​String> 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
         lower-cased, because HTTP header keys are case-insensitive.
         
        map<string, string> headers = 3;
        Specified by:
        getHeadersMap in interface AttributeContext.HttpRequestOrBuilder
      • getHeadersOrDefault

        public String getHeadersOrDefault​(String key,
                                          String defaultValue)
         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
         lower-cased, because HTTP header keys are case-insensitive.
         
        map<string, string> headers = 3;
        Specified by:
        getHeadersOrDefault in interface AttributeContext.HttpRequestOrBuilder
      • getHeadersOrThrow

        public String getHeadersOrThrow​(String key)
         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
         lower-cased, because HTTP header keys are case-insensitive.
         
        map<string, string> headers = 3;
        Specified by:
        getHeadersOrThrow in interface AttributeContext.HttpRequestOrBuilder
      • removeHeaders

        public AttributeContext.HttpRequest.Builder removeHeaders​(String key)
         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
         lower-cased, because HTTP header keys are case-insensitive.
         
        map<string, string> headers = 3;
      • getMutableHeaders

        @Deprecated
        public Map<String,​String> getMutableHeaders()
        Deprecated.
        Use alternate mutation accessors instead.
      • putHeaders

        public AttributeContext.HttpRequest.Builder putHeaders​(String key,
                                                               String value)
         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
         lower-cased, because HTTP header keys are case-insensitive.
         
        map<string, string> headers = 3;
      • putAllHeaders

        public AttributeContext.HttpRequest.Builder putAllHeaders​(Map<String,​String> values)
         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
         lower-cased, because HTTP header keys are case-insensitive.
         
        map<string, string> headers = 3;
      • getPath

        public String getPath()
         The request target, as it appears in the first line of the HTTP request. This includes
         the URL path and query-string. No decoding is performed.
         
        string path = 4;
        Specified by:
        getPath in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The path.
      • getPathBytes

        public com.google.protobuf.ByteString getPathBytes()
         The request target, as it appears in the first line of the HTTP request. This includes
         the URL path and query-string. No decoding is performed.
         
        string path = 4;
        Specified by:
        getPathBytes in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The bytes for path.
      • setPath

        public AttributeContext.HttpRequest.Builder setPath​(String value)
         The request target, as it appears in the first line of the HTTP request. This includes
         the URL path and query-string. No decoding is performed.
         
        string path = 4;
        Parameters:
        value - The path to set.
        Returns:
        This builder for chaining.
      • clearPath

        public AttributeContext.HttpRequest.Builder clearPath()
         The request target, as it appears in the first line of the HTTP request. This includes
         the URL path and query-string. No decoding is performed.
         
        string path = 4;
        Returns:
        This builder for chaining.
      • setPathBytes

        public AttributeContext.HttpRequest.Builder setPathBytes​(com.google.protobuf.ByteString value)
         The request target, as it appears in the first line of the HTTP request. This includes
         the URL path and query-string. No decoding is performed.
         
        string path = 4;
        Parameters:
        value - The bytes for path to set.
        Returns:
        This builder for chaining.
      • getHostBytes

        public com.google.protobuf.ByteString getHostBytes()
         The HTTP request ``Host`` or '`Authority`` header value.
         
        string host = 5;
        Specified by:
        getHostBytes in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The bytes for host.
      • setHost

        public AttributeContext.HttpRequest.Builder setHost​(String value)
         The HTTP request ``Host`` or '`Authority`` header value.
         
        string host = 5;
        Parameters:
        value - The host to set.
        Returns:
        This builder for chaining.
      • setHostBytes

        public AttributeContext.HttpRequest.Builder setHostBytes​(com.google.protobuf.ByteString value)
         The HTTP request ``Host`` or '`Authority`` header value.
         
        string host = 5;
        Parameters:
        value - The bytes for host to set.
        Returns:
        This builder for chaining.
      • getSchemeBytes

        public com.google.protobuf.ByteString getSchemeBytes()
         The HTTP URL scheme, such as ``http`` and ``https``.
         
        string scheme = 6;
        Specified by:
        getSchemeBytes in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The bytes for scheme.
      • setScheme

        public AttributeContext.HttpRequest.Builder setScheme​(String value)
         The HTTP URL scheme, such as ``http`` and ``https``.
         
        string scheme = 6;
        Parameters:
        value - The scheme to set.
        Returns:
        This builder for chaining.
      • clearScheme

        public AttributeContext.HttpRequest.Builder clearScheme()
         The HTTP URL scheme, such as ``http`` and ``https``.
         
        string scheme = 6;
        Returns:
        This builder for chaining.
      • setSchemeBytes

        public AttributeContext.HttpRequest.Builder setSchemeBytes​(com.google.protobuf.ByteString value)
         The HTTP URL scheme, such as ``http`` and ``https``.
         
        string scheme = 6;
        Parameters:
        value - The bytes for scheme to set.
        Returns:
        This builder for chaining.
      • getQuery

        public String getQuery()
         This field is always empty, and exists for compatibility reasons. The HTTP URL query is
         included in ``path`` field.
         
        string query = 7;
        Specified by:
        getQuery in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The query.
      • getQueryBytes

        public com.google.protobuf.ByteString getQueryBytes()
         This field is always empty, and exists for compatibility reasons. The HTTP URL query is
         included in ``path`` field.
         
        string query = 7;
        Specified by:
        getQueryBytes in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The bytes for query.
      • setQuery

        public AttributeContext.HttpRequest.Builder setQuery​(String value)
         This field is always empty, and exists for compatibility reasons. The HTTP URL query is
         included in ``path`` field.
         
        string query = 7;
        Parameters:
        value - The query to set.
        Returns:
        This builder for chaining.
      • clearQuery

        public AttributeContext.HttpRequest.Builder clearQuery()
         This field is always empty, and exists for compatibility reasons. The HTTP URL query is
         included in ``path`` field.
         
        string query = 7;
        Returns:
        This builder for chaining.
      • setQueryBytes

        public AttributeContext.HttpRequest.Builder setQueryBytes​(com.google.protobuf.ByteString value)
         This field is always empty, and exists for compatibility reasons. The HTTP URL query is
         included in ``path`` field.
         
        string query = 7;
        Parameters:
        value - The bytes for query to set.
        Returns:
        This builder for chaining.
      • getFragment

        public String getFragment()
         This field is always empty, and exists for compatibility reasons. The URL fragment is
         not submitted as part of HTTP requests; it is unknowable.
         
        string fragment = 8;
        Specified by:
        getFragment in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The fragment.
      • getFragmentBytes

        public com.google.protobuf.ByteString getFragmentBytes()
         This field is always empty, and exists for compatibility reasons. The URL fragment is
         not submitted as part of HTTP requests; it is unknowable.
         
        string fragment = 8;
        Specified by:
        getFragmentBytes in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The bytes for fragment.
      • setFragment

        public AttributeContext.HttpRequest.Builder setFragment​(String value)
         This field is always empty, and exists for compatibility reasons. The URL fragment is
         not submitted as part of HTTP requests; it is unknowable.
         
        string fragment = 8;
        Parameters:
        value - The fragment to set.
        Returns:
        This builder for chaining.
      • clearFragment

        public AttributeContext.HttpRequest.Builder clearFragment()
         This field is always empty, and exists for compatibility reasons. The URL fragment is
         not submitted as part of HTTP requests; it is unknowable.
         
        string fragment = 8;
        Returns:
        This builder for chaining.
      • setFragmentBytes

        public AttributeContext.HttpRequest.Builder setFragmentBytes​(com.google.protobuf.ByteString value)
         This field is always empty, and exists for compatibility reasons. The URL fragment is
         not submitted as part of HTTP requests; it is unknowable.
         
        string fragment = 8;
        Parameters:
        value - The bytes for fragment to set.
        Returns:
        This builder for chaining.
      • setSize

        public AttributeContext.HttpRequest.Builder setSize​(long value)
         The HTTP request size in bytes. If unknown, it must be -1.
         
        int64 size = 9;
        Parameters:
        value - The size to set.
        Returns:
        This builder for chaining.
      • clearSize

        public AttributeContext.HttpRequest.Builder clearSize()
         The HTTP request size in bytes. If unknown, it must be -1.
         
        int64 size = 9;
        Returns:
        This builder for chaining.
      • getProtocol

        public String getProtocol()
         The network protocol used with the request, such as "HTTP/1.0", "HTTP/1.1", or "HTTP/2".
         See :repo:`headers.h:ProtocolStrings <source/common/http/headers.h>` for a list of all
         possible values.
         
        string protocol = 10;
        Specified by:
        getProtocol in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The protocol.
      • getProtocolBytes

        public com.google.protobuf.ByteString getProtocolBytes()
         The network protocol used with the request, such as "HTTP/1.0", "HTTP/1.1", or "HTTP/2".
         See :repo:`headers.h:ProtocolStrings <source/common/http/headers.h>` for a list of all
         possible values.
         
        string protocol = 10;
        Specified by:
        getProtocolBytes in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The bytes for protocol.
      • setProtocol

        public AttributeContext.HttpRequest.Builder setProtocol​(String value)
         The network protocol used with the request, such as "HTTP/1.0", "HTTP/1.1", or "HTTP/2".
         See :repo:`headers.h:ProtocolStrings <source/common/http/headers.h>` for a list of all
         possible values.
         
        string protocol = 10;
        Parameters:
        value - The protocol to set.
        Returns:
        This builder for chaining.
      • clearProtocol

        public AttributeContext.HttpRequest.Builder clearProtocol()
         The network protocol used with the request, such as "HTTP/1.0", "HTTP/1.1", or "HTTP/2".
         See :repo:`headers.h:ProtocolStrings <source/common/http/headers.h>` for a list of all
         possible values.
         
        string protocol = 10;
        Returns:
        This builder for chaining.
      • setProtocolBytes

        public AttributeContext.HttpRequest.Builder setProtocolBytes​(com.google.protobuf.ByteString value)
         The network protocol used with the request, such as "HTTP/1.0", "HTTP/1.1", or "HTTP/2".
         See :repo:`headers.h:ProtocolStrings <source/common/http/headers.h>` for a list of all
         possible values.
         
        string protocol = 10;
        Parameters:
        value - The bytes for protocol to set.
        Returns:
        This builder for chaining.
      • setBodyBytes

        public AttributeContext.HttpRequest.Builder setBodyBytes​(com.google.protobuf.ByteString value)
         The HTTP request body.
         
        string body = 11;
        Parameters:
        value - The bytes for body to set.
        Returns:
        This builder for chaining.
      • getRawBody

        public com.google.protobuf.ByteString getRawBody()
         The HTTP request body in bytes. This is used instead of
         :ref:`body <envoy_v3_api_field_service.auth.v3.AttributeContext.HttpRequest.body>` when
         :ref:`pack_as_bytes <envoy_v3_api_field_extensions.filters.http.ext_authz.v3.BufferSettings.pack_as_bytes>`
         is set to true.
         
        bytes raw_body = 12;
        Specified by:
        getRawBody in interface AttributeContext.HttpRequestOrBuilder
        Returns:
        The rawBody.
      • setRawBody

        public AttributeContext.HttpRequest.Builder setRawBody​(com.google.protobuf.ByteString value)
         The HTTP request body in bytes. This is used instead of
         :ref:`body <envoy_v3_api_field_service.auth.v3.AttributeContext.HttpRequest.body>` when
         :ref:`pack_as_bytes <envoy_v3_api_field_extensions.filters.http.ext_authz.v3.BufferSettings.pack_as_bytes>`
         is set to true.
         
        bytes raw_body = 12;
        Parameters:
        value - The rawBody to set.
        Returns:
        This builder for chaining.
      • clearRawBody

        public AttributeContext.HttpRequest.Builder clearRawBody()
         The HTTP request body in bytes. This is used instead of
         :ref:`body <envoy_v3_api_field_service.auth.v3.AttributeContext.HttpRequest.body>` when
         :ref:`pack_as_bytes <envoy_v3_api_field_extensions.filters.http.ext_authz.v3.BufferSettings.pack_as_bytes>`
         is set to true.
         
        bytes raw_body = 12;
        Returns:
        This builder for chaining.