io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: envoy/data/accesslog/v3alpha/accesslog.proto
package io.envoyproxy.envoy.data.accesslog.v3alpha;
/**
* Protobuf type {@code envoy.data.accesslog.v3alpha.HTTPRequestProperties}
*/
public final class HTTPRequestProperties extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.data.accesslog.v3alpha.HTTPRequestProperties)
HTTPRequestPropertiesOrBuilder {
private static final long serialVersionUID = 0L;
// Use HTTPRequestProperties.newBuilder() to construct.
private HTTPRequestProperties(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private HTTPRequestProperties() {
requestMethod_ = 0;
scheme_ = "";
authority_ = "";
path_ = "";
userAgent_ = "";
referer_ = "";
forwardedFor_ = "";
requestId_ = "";
originalPath_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new HTTPRequestProperties();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private HTTPRequestProperties(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
int rawValue = input.readEnum();
requestMethod_ = rawValue;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
scheme_ = s;
break;
}
case 26: {
java.lang.String s = input.readStringRequireUtf8();
authority_ = s;
break;
}
case 34: {
com.google.protobuf.UInt32Value.Builder subBuilder = null;
if (port_ != null) {
subBuilder = port_.toBuilder();
}
port_ = input.readMessage(com.google.protobuf.UInt32Value.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(port_);
port_ = subBuilder.buildPartial();
}
break;
}
case 42: {
java.lang.String s = input.readStringRequireUtf8();
path_ = s;
break;
}
case 50: {
java.lang.String s = input.readStringRequireUtf8();
userAgent_ = s;
break;
}
case 58: {
java.lang.String s = input.readStringRequireUtf8();
referer_ = s;
break;
}
case 66: {
java.lang.String s = input.readStringRequireUtf8();
forwardedFor_ = s;
break;
}
case 74: {
java.lang.String s = input.readStringRequireUtf8();
requestId_ = s;
break;
}
case 82: {
java.lang.String s = input.readStringRequireUtf8();
originalPath_ = s;
break;
}
case 88: {
requestHeadersBytes_ = input.readUInt64();
break;
}
case 96: {
requestBodyBytes_ = input.readUInt64();
break;
}
case 106: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
requestHeaders_ = com.google.protobuf.MapField.newMapField(
RequestHeadersDefaultEntryHolder.defaultEntry);
mutable_bitField0_ |= 0x00000001;
}
com.google.protobuf.MapEntry
requestHeaders__ = input.readMessage(
RequestHeadersDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
requestHeaders_.getMutableMap().put(
requestHeaders__.getKey(), requestHeaders__.getValue());
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.data.accesslog.v3alpha.AccesslogProto.internal_static_envoy_data_accesslog_v3alpha_HTTPRequestProperties_descriptor;
}
@SuppressWarnings({"rawtypes"})
@java.lang.Override
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 13:
return internalGetRequestHeaders();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.data.accesslog.v3alpha.AccesslogProto.internal_static_envoy_data_accesslog_v3alpha_HTTPRequestProperties_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties.class, io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties.Builder.class);
}
public static final int REQUEST_METHOD_FIELD_NUMBER = 1;
private int requestMethod_;
/**
*
* The request method (RFC 7231/2616).
* [#comment:TODO(htuch): add (validate.rules).enum.defined_only = true once
* https://github.com/lyft/protoc-gen-validate/issues/42 is resolved.]
*
*
* .envoy.api.v3alpha.core.RequestMethod request_method = 1;
*/
public int getRequestMethodValue() {
return requestMethod_;
}
/**
*
* The request method (RFC 7231/2616).
* [#comment:TODO(htuch): add (validate.rules).enum.defined_only = true once
* https://github.com/lyft/protoc-gen-validate/issues/42 is resolved.]
*
*
* .envoy.api.v3alpha.core.RequestMethod request_method = 1;
*/
public io.envoyproxy.envoy.api.v3alpha.core.RequestMethod getRequestMethod() {
@SuppressWarnings("deprecation")
io.envoyproxy.envoy.api.v3alpha.core.RequestMethod result = io.envoyproxy.envoy.api.v3alpha.core.RequestMethod.valueOf(requestMethod_);
return result == null ? io.envoyproxy.envoy.api.v3alpha.core.RequestMethod.UNRECOGNIZED : result;
}
public static final int SCHEME_FIELD_NUMBER = 2;
private volatile java.lang.Object scheme_;
/**
*
* The scheme portion of the incoming request URI.
*
*
* string scheme = 2;
*/
public java.lang.String getScheme() {
java.lang.Object ref = scheme_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
scheme_ = s;
return s;
}
}
/**
*
* The scheme portion of the incoming request URI.
*
*
* string scheme = 2;
*/
public com.google.protobuf.ByteString
getSchemeBytes() {
java.lang.Object ref = scheme_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
scheme_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int AUTHORITY_FIELD_NUMBER = 3;
private volatile java.lang.Object authority_;
/**
*
* HTTP/2 ``:authority`` or HTTP/1.1 ``Host`` header value.
*
*
* string authority = 3;
*/
public java.lang.String getAuthority() {
java.lang.Object ref = authority_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
authority_ = s;
return s;
}
}
/**
*
* HTTP/2 ``:authority`` or HTTP/1.1 ``Host`` header value.
*
*
* string authority = 3;
*/
public com.google.protobuf.ByteString
getAuthorityBytes() {
java.lang.Object ref = authority_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
authority_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PORT_FIELD_NUMBER = 4;
private com.google.protobuf.UInt32Value port_;
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public boolean hasPort() {
return port_ != null;
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public com.google.protobuf.UInt32Value getPort() {
return port_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : port_;
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public com.google.protobuf.UInt32ValueOrBuilder getPortOrBuilder() {
return getPort();
}
public static final int PATH_FIELD_NUMBER = 5;
private volatile java.lang.Object path_;
/**
*
* The path portion from the incoming request URI.
*
*
* string path = 5;
*/
public java.lang.String getPath() {
java.lang.Object ref = path_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
path_ = s;
return s;
}
}
/**
*
* The path portion from the incoming request URI.
*
*
* string path = 5;
*/
public com.google.protobuf.ByteString
getPathBytes() {
java.lang.Object ref = path_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
path_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int USER_AGENT_FIELD_NUMBER = 6;
private volatile java.lang.Object userAgent_;
/**
*
* Value of the ``User-Agent`` request header.
*
*
* string user_agent = 6;
*/
public java.lang.String getUserAgent() {
java.lang.Object ref = userAgent_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
userAgent_ = s;
return s;
}
}
/**
*
* Value of the ``User-Agent`` request header.
*
*
* string user_agent = 6;
*/
public com.google.protobuf.ByteString
getUserAgentBytes() {
java.lang.Object ref = userAgent_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
userAgent_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int REFERER_FIELD_NUMBER = 7;
private volatile java.lang.Object referer_;
/**
*
* Value of the ``Referer`` request header.
*
*
* string referer = 7;
*/
public java.lang.String getReferer() {
java.lang.Object ref = referer_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
referer_ = s;
return s;
}
}
/**
*
* Value of the ``Referer`` request header.
*
*
* string referer = 7;
*/
public com.google.protobuf.ByteString
getRefererBytes() {
java.lang.Object ref = referer_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
referer_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int FORWARDED_FOR_FIELD_NUMBER = 8;
private volatile java.lang.Object forwardedFor_;
/**
*
* Value of the ``X-Forwarded-For`` request header.
*
*
* string forwarded_for = 8;
*/
public java.lang.String getForwardedFor() {
java.lang.Object ref = forwardedFor_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
forwardedFor_ = s;
return s;
}
}
/**
*
* Value of the ``X-Forwarded-For`` request header.
*
*
* string forwarded_for = 8;
*/
public com.google.protobuf.ByteString
getForwardedForBytes() {
java.lang.Object ref = forwardedFor_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
forwardedFor_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int REQUEST_ID_FIELD_NUMBER = 9;
private volatile java.lang.Object requestId_;
/**
*
* Value of the ``X-Request-Id`` request header
* This header is used by Envoy to uniquely identify a request.
* It will be generated for all external requests and internal requests that
* do not already have a request ID.
*
*
* string request_id = 9;
*/
public java.lang.String getRequestId() {
java.lang.Object ref = requestId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
requestId_ = s;
return s;
}
}
/**
*
* Value of the ``X-Request-Id`` request header
* This header is used by Envoy to uniquely identify a request.
* It will be generated for all external requests and internal requests that
* do not already have a request ID.
*
*
* string request_id = 9;
*/
public com.google.protobuf.ByteString
getRequestIdBytes() {
java.lang.Object ref = requestId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
requestId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int ORIGINAL_PATH_FIELD_NUMBER = 10;
private volatile java.lang.Object originalPath_;
/**
*
* Value of the ``X-Envoy-Original-Path`` request header.
*
*
* string original_path = 10;
*/
public java.lang.String getOriginalPath() {
java.lang.Object ref = originalPath_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
originalPath_ = s;
return s;
}
}
/**
*
* Value of the ``X-Envoy-Original-Path`` request header.
*
*
* string original_path = 10;
*/
public com.google.protobuf.ByteString
getOriginalPathBytes() {
java.lang.Object ref = originalPath_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
originalPath_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int REQUEST_HEADERS_BYTES_FIELD_NUMBER = 11;
private long requestHeadersBytes_;
/**
*
* Size of the HTTP request headers in bytes.
* This value is captured from the OSI layer 7 perspective, i.e. it does not
* include overhead from framing or encoding at other networking layers.
*
*
* uint64 request_headers_bytes = 11;
*/
public long getRequestHeadersBytes() {
return requestHeadersBytes_;
}
public static final int REQUEST_BODY_BYTES_FIELD_NUMBER = 12;
private long requestBodyBytes_;
/**
*
* Size of the HTTP request body in bytes.
* This value is captured from the OSI layer 7 perspective, i.e. it does not
* include overhead from framing or encoding at other networking layers.
*
*
* uint64 request_body_bytes = 12;
*/
public long getRequestBodyBytes() {
return requestBodyBytes_;
}
public static final int REQUEST_HEADERS_FIELD_NUMBER = 13;
private static final class RequestHeadersDefaultEntryHolder {
static final com.google.protobuf.MapEntry<
java.lang.String, java.lang.String> defaultEntry =
com.google.protobuf.MapEntry
.newDefaultInstance(
io.envoyproxy.envoy.data.accesslog.v3alpha.AccesslogProto.internal_static_envoy_data_accesslog_v3alpha_HTTPRequestProperties_RequestHeadersEntry_descriptor,
com.google.protobuf.WireFormat.FieldType.STRING,
"",
com.google.protobuf.WireFormat.FieldType.STRING,
"");
}
private com.google.protobuf.MapField<
java.lang.String, java.lang.String> requestHeaders_;
private com.google.protobuf.MapField
internalGetRequestHeaders() {
if (requestHeaders_ == null) {
return com.google.protobuf.MapField.emptyMapField(
RequestHeadersDefaultEntryHolder.defaultEntry);
}
return requestHeaders_;
}
public int getRequestHeadersCount() {
return internalGetRequestHeaders().getMap().size();
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public boolean containsRequestHeaders(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
return internalGetRequestHeaders().getMap().containsKey(key);
}
/**
* Use {@link #getRequestHeadersMap()} instead.
*/
@java.lang.Deprecated
public java.util.Map getRequestHeaders() {
return getRequestHeadersMap();
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public java.util.Map getRequestHeadersMap() {
return internalGetRequestHeaders().getMap();
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public java.lang.String getRequestHeadersOrDefault(
java.lang.String key,
java.lang.String defaultValue) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetRequestHeaders().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public java.lang.String getRequestHeadersOrThrow(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetRequestHeaders().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (requestMethod_ != io.envoyproxy.envoy.api.v3alpha.core.RequestMethod.METHOD_UNSPECIFIED.getNumber()) {
output.writeEnum(1, requestMethod_);
}
if (!getSchemeBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, scheme_);
}
if (!getAuthorityBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, authority_);
}
if (port_ != null) {
output.writeMessage(4, getPort());
}
if (!getPathBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 5, path_);
}
if (!getUserAgentBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 6, userAgent_);
}
if (!getRefererBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 7, referer_);
}
if (!getForwardedForBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 8, forwardedFor_);
}
if (!getRequestIdBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 9, requestId_);
}
if (!getOriginalPathBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 10, originalPath_);
}
if (requestHeadersBytes_ != 0L) {
output.writeUInt64(11, requestHeadersBytes_);
}
if (requestBodyBytes_ != 0L) {
output.writeUInt64(12, requestBodyBytes_);
}
com.google.protobuf.GeneratedMessageV3
.serializeStringMapTo(
output,
internalGetRequestHeaders(),
RequestHeadersDefaultEntryHolder.defaultEntry,
13);
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (requestMethod_ != io.envoyproxy.envoy.api.v3alpha.core.RequestMethod.METHOD_UNSPECIFIED.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, requestMethod_);
}
if (!getSchemeBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, scheme_);
}
if (!getAuthorityBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, authority_);
}
if (port_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, getPort());
}
if (!getPathBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, path_);
}
if (!getUserAgentBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, userAgent_);
}
if (!getRefererBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, referer_);
}
if (!getForwardedForBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, forwardedFor_);
}
if (!getRequestIdBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, requestId_);
}
if (!getOriginalPathBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, originalPath_);
}
if (requestHeadersBytes_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeUInt64Size(11, requestHeadersBytes_);
}
if (requestBodyBytes_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeUInt64Size(12, requestBodyBytes_);
}
for (java.util.Map.Entry entry
: internalGetRequestHeaders().getMap().entrySet()) {
com.google.protobuf.MapEntry
requestHeaders__ = RequestHeadersDefaultEntryHolder.defaultEntry.newBuilderForType()
.setKey(entry.getKey())
.setValue(entry.getValue())
.build();
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(13, requestHeaders__);
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties)) {
return super.equals(obj);
}
io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties other = (io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties) obj;
if (requestMethod_ != other.requestMethod_) return false;
if (!getScheme()
.equals(other.getScheme())) return false;
if (!getAuthority()
.equals(other.getAuthority())) return false;
if (hasPort() != other.hasPort()) return false;
if (hasPort()) {
if (!getPort()
.equals(other.getPort())) return false;
}
if (!getPath()
.equals(other.getPath())) return false;
if (!getUserAgent()
.equals(other.getUserAgent())) return false;
if (!getReferer()
.equals(other.getReferer())) return false;
if (!getForwardedFor()
.equals(other.getForwardedFor())) return false;
if (!getRequestId()
.equals(other.getRequestId())) return false;
if (!getOriginalPath()
.equals(other.getOriginalPath())) return false;
if (getRequestHeadersBytes()
!= other.getRequestHeadersBytes()) return false;
if (getRequestBodyBytes()
!= other.getRequestBodyBytes()) return false;
if (!internalGetRequestHeaders().equals(
other.internalGetRequestHeaders())) return false;
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + REQUEST_METHOD_FIELD_NUMBER;
hash = (53 * hash) + requestMethod_;
hash = (37 * hash) + SCHEME_FIELD_NUMBER;
hash = (53 * hash) + getScheme().hashCode();
hash = (37 * hash) + AUTHORITY_FIELD_NUMBER;
hash = (53 * hash) + getAuthority().hashCode();
if (hasPort()) {
hash = (37 * hash) + PORT_FIELD_NUMBER;
hash = (53 * hash) + getPort().hashCode();
}
hash = (37 * hash) + PATH_FIELD_NUMBER;
hash = (53 * hash) + getPath().hashCode();
hash = (37 * hash) + USER_AGENT_FIELD_NUMBER;
hash = (53 * hash) + getUserAgent().hashCode();
hash = (37 * hash) + REFERER_FIELD_NUMBER;
hash = (53 * hash) + getReferer().hashCode();
hash = (37 * hash) + FORWARDED_FOR_FIELD_NUMBER;
hash = (53 * hash) + getForwardedFor().hashCode();
hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER;
hash = (53 * hash) + getRequestId().hashCode();
hash = (37 * hash) + ORIGINAL_PATH_FIELD_NUMBER;
hash = (53 * hash) + getOriginalPath().hashCode();
hash = (37 * hash) + REQUEST_HEADERS_BYTES_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getRequestHeadersBytes());
hash = (37 * hash) + REQUEST_BODY_BYTES_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getRequestBodyBytes());
if (!internalGetRequestHeaders().getMap().isEmpty()) {
hash = (37 * hash) + REQUEST_HEADERS_FIELD_NUMBER;
hash = (53 * hash) + internalGetRequestHeaders().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code envoy.data.accesslog.v3alpha.HTTPRequestProperties}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.data.accesslog.v3alpha.HTTPRequestProperties)
io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestPropertiesOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.data.accesslog.v3alpha.AccesslogProto.internal_static_envoy_data_accesslog_v3alpha_HTTPRequestProperties_descriptor;
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 13:
return internalGetRequestHeaders();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMutableMapField(
int number) {
switch (number) {
case 13:
return internalGetMutableRequestHeaders();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.data.accesslog.v3alpha.AccesslogProto.internal_static_envoy_data_accesslog_v3alpha_HTTPRequestProperties_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties.class, io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties.Builder.class);
}
// Construct using io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
requestMethod_ = 0;
scheme_ = "";
authority_ = "";
if (portBuilder_ == null) {
port_ = null;
} else {
port_ = null;
portBuilder_ = null;
}
path_ = "";
userAgent_ = "";
referer_ = "";
forwardedFor_ = "";
requestId_ = "";
originalPath_ = "";
requestHeadersBytes_ = 0L;
requestBodyBytes_ = 0L;
internalGetMutableRequestHeaders().clear();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.data.accesslog.v3alpha.AccesslogProto.internal_static_envoy_data_accesslog_v3alpha_HTTPRequestProperties_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties getDefaultInstanceForType() {
return io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties build() {
io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties buildPartial() {
io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties result = new io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties(this);
int from_bitField0_ = bitField0_;
result.requestMethod_ = requestMethod_;
result.scheme_ = scheme_;
result.authority_ = authority_;
if (portBuilder_ == null) {
result.port_ = port_;
} else {
result.port_ = portBuilder_.build();
}
result.path_ = path_;
result.userAgent_ = userAgent_;
result.referer_ = referer_;
result.forwardedFor_ = forwardedFor_;
result.requestId_ = requestId_;
result.originalPath_ = originalPath_;
result.requestHeadersBytes_ = requestHeadersBytes_;
result.requestBodyBytes_ = requestBodyBytes_;
result.requestHeaders_ = internalGetRequestHeaders();
result.requestHeaders_.makeImmutable();
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties) {
return mergeFrom((io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties other) {
if (other == io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties.getDefaultInstance()) return this;
if (other.requestMethod_ != 0) {
setRequestMethodValue(other.getRequestMethodValue());
}
if (!other.getScheme().isEmpty()) {
scheme_ = other.scheme_;
onChanged();
}
if (!other.getAuthority().isEmpty()) {
authority_ = other.authority_;
onChanged();
}
if (other.hasPort()) {
mergePort(other.getPort());
}
if (!other.getPath().isEmpty()) {
path_ = other.path_;
onChanged();
}
if (!other.getUserAgent().isEmpty()) {
userAgent_ = other.userAgent_;
onChanged();
}
if (!other.getReferer().isEmpty()) {
referer_ = other.referer_;
onChanged();
}
if (!other.getForwardedFor().isEmpty()) {
forwardedFor_ = other.forwardedFor_;
onChanged();
}
if (!other.getRequestId().isEmpty()) {
requestId_ = other.requestId_;
onChanged();
}
if (!other.getOriginalPath().isEmpty()) {
originalPath_ = other.originalPath_;
onChanged();
}
if (other.getRequestHeadersBytes() != 0L) {
setRequestHeadersBytes(other.getRequestHeadersBytes());
}
if (other.getRequestBodyBytes() != 0L) {
setRequestBodyBytes(other.getRequestBodyBytes());
}
internalGetMutableRequestHeaders().mergeFrom(
other.internalGetRequestHeaders());
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private int requestMethod_ = 0;
/**
*
* The request method (RFC 7231/2616).
* [#comment:TODO(htuch): add (validate.rules).enum.defined_only = true once
* https://github.com/lyft/protoc-gen-validate/issues/42 is resolved.]
*
*
* .envoy.api.v3alpha.core.RequestMethod request_method = 1;
*/
public int getRequestMethodValue() {
return requestMethod_;
}
/**
*
* The request method (RFC 7231/2616).
* [#comment:TODO(htuch): add (validate.rules).enum.defined_only = true once
* https://github.com/lyft/protoc-gen-validate/issues/42 is resolved.]
*
*
* .envoy.api.v3alpha.core.RequestMethod request_method = 1;
*/
public Builder setRequestMethodValue(int value) {
requestMethod_ = value;
onChanged();
return this;
}
/**
*
* The request method (RFC 7231/2616).
* [#comment:TODO(htuch): add (validate.rules).enum.defined_only = true once
* https://github.com/lyft/protoc-gen-validate/issues/42 is resolved.]
*
*
* .envoy.api.v3alpha.core.RequestMethod request_method = 1;
*/
public io.envoyproxy.envoy.api.v3alpha.core.RequestMethod getRequestMethod() {
@SuppressWarnings("deprecation")
io.envoyproxy.envoy.api.v3alpha.core.RequestMethod result = io.envoyproxy.envoy.api.v3alpha.core.RequestMethod.valueOf(requestMethod_);
return result == null ? io.envoyproxy.envoy.api.v3alpha.core.RequestMethod.UNRECOGNIZED : result;
}
/**
*
* The request method (RFC 7231/2616).
* [#comment:TODO(htuch): add (validate.rules).enum.defined_only = true once
* https://github.com/lyft/protoc-gen-validate/issues/42 is resolved.]
*
*
* .envoy.api.v3alpha.core.RequestMethod request_method = 1;
*/
public Builder setRequestMethod(io.envoyproxy.envoy.api.v3alpha.core.RequestMethod value) {
if (value == null) {
throw new NullPointerException();
}
requestMethod_ = value.getNumber();
onChanged();
return this;
}
/**
*
* The request method (RFC 7231/2616).
* [#comment:TODO(htuch): add (validate.rules).enum.defined_only = true once
* https://github.com/lyft/protoc-gen-validate/issues/42 is resolved.]
*
*
* .envoy.api.v3alpha.core.RequestMethod request_method = 1;
*/
public Builder clearRequestMethod() {
requestMethod_ = 0;
onChanged();
return this;
}
private java.lang.Object scheme_ = "";
/**
*
* The scheme portion of the incoming request URI.
*
*
* string scheme = 2;
*/
public java.lang.String getScheme() {
java.lang.Object ref = scheme_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
scheme_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The scheme portion of the incoming request URI.
*
*
* string scheme = 2;
*/
public com.google.protobuf.ByteString
getSchemeBytes() {
java.lang.Object ref = scheme_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
scheme_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The scheme portion of the incoming request URI.
*
*
* string scheme = 2;
*/
public Builder setScheme(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
scheme_ = value;
onChanged();
return this;
}
/**
*
* The scheme portion of the incoming request URI.
*
*
* string scheme = 2;
*/
public Builder clearScheme() {
scheme_ = getDefaultInstance().getScheme();
onChanged();
return this;
}
/**
*
* The scheme portion of the incoming request URI.
*
*
* string scheme = 2;
*/
public Builder setSchemeBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
scheme_ = value;
onChanged();
return this;
}
private java.lang.Object authority_ = "";
/**
*
* HTTP/2 ``:authority`` or HTTP/1.1 ``Host`` header value.
*
*
* string authority = 3;
*/
public java.lang.String getAuthority() {
java.lang.Object ref = authority_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
authority_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* HTTP/2 ``:authority`` or HTTP/1.1 ``Host`` header value.
*
*
* string authority = 3;
*/
public com.google.protobuf.ByteString
getAuthorityBytes() {
java.lang.Object ref = authority_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
authority_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* HTTP/2 ``:authority`` or HTTP/1.1 ``Host`` header value.
*
*
* string authority = 3;
*/
public Builder setAuthority(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
authority_ = value;
onChanged();
return this;
}
/**
*
* HTTP/2 ``:authority`` or HTTP/1.1 ``Host`` header value.
*
*
* string authority = 3;
*/
public Builder clearAuthority() {
authority_ = getDefaultInstance().getAuthority();
onChanged();
return this;
}
/**
*
* HTTP/2 ``:authority`` or HTTP/1.1 ``Host`` header value.
*
*
* string authority = 3;
*/
public Builder setAuthorityBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
authority_ = value;
onChanged();
return this;
}
private com.google.protobuf.UInt32Value port_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> portBuilder_;
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public boolean hasPort() {
return portBuilder_ != null || port_ != null;
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public com.google.protobuf.UInt32Value getPort() {
if (portBuilder_ == null) {
return port_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : port_;
} else {
return portBuilder_.getMessage();
}
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public Builder setPort(com.google.protobuf.UInt32Value value) {
if (portBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
port_ = value;
onChanged();
} else {
portBuilder_.setMessage(value);
}
return this;
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public Builder setPort(
com.google.protobuf.UInt32Value.Builder builderForValue) {
if (portBuilder_ == null) {
port_ = builderForValue.build();
onChanged();
} else {
portBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public Builder mergePort(com.google.protobuf.UInt32Value value) {
if (portBuilder_ == null) {
if (port_ != null) {
port_ =
com.google.protobuf.UInt32Value.newBuilder(port_).mergeFrom(value).buildPartial();
} else {
port_ = value;
}
onChanged();
} else {
portBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public Builder clearPort() {
if (portBuilder_ == null) {
port_ = null;
onChanged();
} else {
port_ = null;
portBuilder_ = null;
}
return this;
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public com.google.protobuf.UInt32Value.Builder getPortBuilder() {
onChanged();
return getPortFieldBuilder().getBuilder();
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
public com.google.protobuf.UInt32ValueOrBuilder getPortOrBuilder() {
if (portBuilder_ != null) {
return portBuilder_.getMessageOrBuilder();
} else {
return port_ == null ?
com.google.protobuf.UInt32Value.getDefaultInstance() : port_;
}
}
/**
*
* The port of the incoming request URI
* (unused currently, as port is composed onto authority).
*
*
* .google.protobuf.UInt32Value port = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>
getPortFieldBuilder() {
if (portBuilder_ == null) {
portBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>(
getPort(),
getParentForChildren(),
isClean());
port_ = null;
}
return portBuilder_;
}
private java.lang.Object path_ = "";
/**
*
* The path portion from the incoming request URI.
*
*
* string path = 5;
*/
public java.lang.String getPath() {
java.lang.Object ref = path_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
path_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The path portion from the incoming request URI.
*
*
* string path = 5;
*/
public com.google.protobuf.ByteString
getPathBytes() {
java.lang.Object ref = path_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
path_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The path portion from the incoming request URI.
*
*
* string path = 5;
*/
public Builder setPath(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
path_ = value;
onChanged();
return this;
}
/**
*
* The path portion from the incoming request URI.
*
*
* string path = 5;
*/
public Builder clearPath() {
path_ = getDefaultInstance().getPath();
onChanged();
return this;
}
/**
*
* The path portion from the incoming request URI.
*
*
* string path = 5;
*/
public Builder setPathBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
path_ = value;
onChanged();
return this;
}
private java.lang.Object userAgent_ = "";
/**
*
* Value of the ``User-Agent`` request header.
*
*
* string user_agent = 6;
*/
public java.lang.String getUserAgent() {
java.lang.Object ref = userAgent_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
userAgent_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Value of the ``User-Agent`` request header.
*
*
* string user_agent = 6;
*/
public com.google.protobuf.ByteString
getUserAgentBytes() {
java.lang.Object ref = userAgent_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
userAgent_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Value of the ``User-Agent`` request header.
*
*
* string user_agent = 6;
*/
public Builder setUserAgent(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
userAgent_ = value;
onChanged();
return this;
}
/**
*
* Value of the ``User-Agent`` request header.
*
*
* string user_agent = 6;
*/
public Builder clearUserAgent() {
userAgent_ = getDefaultInstance().getUserAgent();
onChanged();
return this;
}
/**
*
* Value of the ``User-Agent`` request header.
*
*
* string user_agent = 6;
*/
public Builder setUserAgentBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
userAgent_ = value;
onChanged();
return this;
}
private java.lang.Object referer_ = "";
/**
*
* Value of the ``Referer`` request header.
*
*
* string referer = 7;
*/
public java.lang.String getReferer() {
java.lang.Object ref = referer_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
referer_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Value of the ``Referer`` request header.
*
*
* string referer = 7;
*/
public com.google.protobuf.ByteString
getRefererBytes() {
java.lang.Object ref = referer_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
referer_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Value of the ``Referer`` request header.
*
*
* string referer = 7;
*/
public Builder setReferer(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
referer_ = value;
onChanged();
return this;
}
/**
*
* Value of the ``Referer`` request header.
*
*
* string referer = 7;
*/
public Builder clearReferer() {
referer_ = getDefaultInstance().getReferer();
onChanged();
return this;
}
/**
*
* Value of the ``Referer`` request header.
*
*
* string referer = 7;
*/
public Builder setRefererBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
referer_ = value;
onChanged();
return this;
}
private java.lang.Object forwardedFor_ = "";
/**
*
* Value of the ``X-Forwarded-For`` request header.
*
*
* string forwarded_for = 8;
*/
public java.lang.String getForwardedFor() {
java.lang.Object ref = forwardedFor_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
forwardedFor_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Value of the ``X-Forwarded-For`` request header.
*
*
* string forwarded_for = 8;
*/
public com.google.protobuf.ByteString
getForwardedForBytes() {
java.lang.Object ref = forwardedFor_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
forwardedFor_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Value of the ``X-Forwarded-For`` request header.
*
*
* string forwarded_for = 8;
*/
public Builder setForwardedFor(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
forwardedFor_ = value;
onChanged();
return this;
}
/**
*
* Value of the ``X-Forwarded-For`` request header.
*
*
* string forwarded_for = 8;
*/
public Builder clearForwardedFor() {
forwardedFor_ = getDefaultInstance().getForwardedFor();
onChanged();
return this;
}
/**
*
* Value of the ``X-Forwarded-For`` request header.
*
*
* string forwarded_for = 8;
*/
public Builder setForwardedForBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
forwardedFor_ = value;
onChanged();
return this;
}
private java.lang.Object requestId_ = "";
/**
*
* Value of the ``X-Request-Id`` request header
* This header is used by Envoy to uniquely identify a request.
* It will be generated for all external requests and internal requests that
* do not already have a request ID.
*
*
* string request_id = 9;
*/
public java.lang.String getRequestId() {
java.lang.Object ref = requestId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
requestId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Value of the ``X-Request-Id`` request header
* This header is used by Envoy to uniquely identify a request.
* It will be generated for all external requests and internal requests that
* do not already have a request ID.
*
*
* string request_id = 9;
*/
public com.google.protobuf.ByteString
getRequestIdBytes() {
java.lang.Object ref = requestId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
requestId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Value of the ``X-Request-Id`` request header
* This header is used by Envoy to uniquely identify a request.
* It will be generated for all external requests and internal requests that
* do not already have a request ID.
*
*
* string request_id = 9;
*/
public Builder setRequestId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
requestId_ = value;
onChanged();
return this;
}
/**
*
* Value of the ``X-Request-Id`` request header
* This header is used by Envoy to uniquely identify a request.
* It will be generated for all external requests and internal requests that
* do not already have a request ID.
*
*
* string request_id = 9;
*/
public Builder clearRequestId() {
requestId_ = getDefaultInstance().getRequestId();
onChanged();
return this;
}
/**
*
* Value of the ``X-Request-Id`` request header
* This header is used by Envoy to uniquely identify a request.
* It will be generated for all external requests and internal requests that
* do not already have a request ID.
*
*
* string request_id = 9;
*/
public Builder setRequestIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
requestId_ = value;
onChanged();
return this;
}
private java.lang.Object originalPath_ = "";
/**
*
* Value of the ``X-Envoy-Original-Path`` request header.
*
*
* string original_path = 10;
*/
public java.lang.String getOriginalPath() {
java.lang.Object ref = originalPath_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
originalPath_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Value of the ``X-Envoy-Original-Path`` request header.
*
*
* string original_path = 10;
*/
public com.google.protobuf.ByteString
getOriginalPathBytes() {
java.lang.Object ref = originalPath_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
originalPath_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Value of the ``X-Envoy-Original-Path`` request header.
*
*
* string original_path = 10;
*/
public Builder setOriginalPath(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
originalPath_ = value;
onChanged();
return this;
}
/**
*
* Value of the ``X-Envoy-Original-Path`` request header.
*
*
* string original_path = 10;
*/
public Builder clearOriginalPath() {
originalPath_ = getDefaultInstance().getOriginalPath();
onChanged();
return this;
}
/**
*
* Value of the ``X-Envoy-Original-Path`` request header.
*
*
* string original_path = 10;
*/
public Builder setOriginalPathBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
originalPath_ = value;
onChanged();
return this;
}
private long requestHeadersBytes_ ;
/**
*
* Size of the HTTP request headers in bytes.
* This value is captured from the OSI layer 7 perspective, i.e. it does not
* include overhead from framing or encoding at other networking layers.
*
*
* uint64 request_headers_bytes = 11;
*/
public long getRequestHeadersBytes() {
return requestHeadersBytes_;
}
/**
*
* Size of the HTTP request headers in bytes.
* This value is captured from the OSI layer 7 perspective, i.e. it does not
* include overhead from framing or encoding at other networking layers.
*
*
* uint64 request_headers_bytes = 11;
*/
public Builder setRequestHeadersBytes(long value) {
requestHeadersBytes_ = value;
onChanged();
return this;
}
/**
*
* Size of the HTTP request headers in bytes.
* This value is captured from the OSI layer 7 perspective, i.e. it does not
* include overhead from framing or encoding at other networking layers.
*
*
* uint64 request_headers_bytes = 11;
*/
public Builder clearRequestHeadersBytes() {
requestHeadersBytes_ = 0L;
onChanged();
return this;
}
private long requestBodyBytes_ ;
/**
*
* Size of the HTTP request body in bytes.
* This value is captured from the OSI layer 7 perspective, i.e. it does not
* include overhead from framing or encoding at other networking layers.
*
*
* uint64 request_body_bytes = 12;
*/
public long getRequestBodyBytes() {
return requestBodyBytes_;
}
/**
*
* Size of the HTTP request body in bytes.
* This value is captured from the OSI layer 7 perspective, i.e. it does not
* include overhead from framing or encoding at other networking layers.
*
*
* uint64 request_body_bytes = 12;
*/
public Builder setRequestBodyBytes(long value) {
requestBodyBytes_ = value;
onChanged();
return this;
}
/**
*
* Size of the HTTP request body in bytes.
* This value is captured from the OSI layer 7 perspective, i.e. it does not
* include overhead from framing or encoding at other networking layers.
*
*
* uint64 request_body_bytes = 12;
*/
public Builder clearRequestBodyBytes() {
requestBodyBytes_ = 0L;
onChanged();
return this;
}
private com.google.protobuf.MapField<
java.lang.String, java.lang.String> requestHeaders_;
private com.google.protobuf.MapField
internalGetRequestHeaders() {
if (requestHeaders_ == null) {
return com.google.protobuf.MapField.emptyMapField(
RequestHeadersDefaultEntryHolder.defaultEntry);
}
return requestHeaders_;
}
private com.google.protobuf.MapField
internalGetMutableRequestHeaders() {
onChanged();;
if (requestHeaders_ == null) {
requestHeaders_ = com.google.protobuf.MapField.newMapField(
RequestHeadersDefaultEntryHolder.defaultEntry);
}
if (!requestHeaders_.isMutable()) {
requestHeaders_ = requestHeaders_.copy();
}
return requestHeaders_;
}
public int getRequestHeadersCount() {
return internalGetRequestHeaders().getMap().size();
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public boolean containsRequestHeaders(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
return internalGetRequestHeaders().getMap().containsKey(key);
}
/**
* Use {@link #getRequestHeadersMap()} instead.
*/
@java.lang.Deprecated
public java.util.Map getRequestHeaders() {
return getRequestHeadersMap();
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public java.util.Map getRequestHeadersMap() {
return internalGetRequestHeaders().getMap();
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public java.lang.String getRequestHeadersOrDefault(
java.lang.String key,
java.lang.String defaultValue) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetRequestHeaders().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public java.lang.String getRequestHeadersOrThrow(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetRequestHeaders().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public Builder clearRequestHeaders() {
internalGetMutableRequestHeaders().getMutableMap()
.clear();
return this;
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public Builder removeRequestHeaders(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
internalGetMutableRequestHeaders().getMutableMap()
.remove(key);
return this;
}
/**
* Use alternate mutation accessors instead.
*/
@java.lang.Deprecated
public java.util.Map
getMutableRequestHeaders() {
return internalGetMutableRequestHeaders().getMutableMap();
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public Builder putRequestHeaders(
java.lang.String key,
java.lang.String value) {
if (key == null) { throw new java.lang.NullPointerException(); }
if (value == null) { throw new java.lang.NullPointerException(); }
internalGetMutableRequestHeaders().getMutableMap()
.put(key, value);
return this;
}
/**
*
* Map of additional headers that have been configured to be logged.
*
*
* map<string, string> request_headers = 13;
*/
public Builder putAllRequestHeaders(
java.util.Map values) {
internalGetMutableRequestHeaders().getMutableMap()
.putAll(values);
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.data.accesslog.v3alpha.HTTPRequestProperties)
}
// @@protoc_insertion_point(class_scope:envoy.data.accesslog.v3alpha.HTTPRequestProperties)
private static final io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties();
}
public static io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public HTTPRequestProperties parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new HTTPRequestProperties(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.data.accesslog.v3alpha.HTTPRequestProperties getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}