All Downloads are FREE. Search and download functionalities are using the official Maven repository.
Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
io.stigg.sidecar.proto.v1.RedisOptions Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: stigg/sidecar/v1/sidecar.proto
package io.stigg.sidecar.proto.v1;
/** Protobuf type {@code stigg.sidecar.v1.RedisOptions} */
public final class RedisOptions extends com.google.protobuf.GeneratedMessageV3
implements
// @@protoc_insertion_point(message_implements:stigg.sidecar.v1.RedisOptions)
RedisOptionsOrBuilder {
private static final long serialVersionUID = 0L;
// Use RedisOptions.newBuilder() to construct.
private RedisOptions(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RedisOptions() {
environmentPrefix_ = "";
host_ = "";
username_ = "";
password_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
return new RedisOptions();
}
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
return io.stigg.sidecar.proto.v1.SidecarProto
.internal_static_stigg_sidecar_v1_RedisOptions_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.stigg.sidecar.proto.v1.SidecarProto
.internal_static_stigg_sidecar_v1_RedisOptions_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.stigg.sidecar.proto.v1.RedisOptions.class,
io.stigg.sidecar.proto.v1.RedisOptions.Builder.class);
}
private int bitField0_;
public static final int ENVIRONMENT_PREFIX_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object environmentPrefix_ = "";
/**
* string environment_prefix = 1 [json_name = "environmentPrefix"];
*
* @return The environmentPrefix.
*/
@java.lang.Override
public java.lang.String getEnvironmentPrefix() {
java.lang.Object ref = environmentPrefix_;
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();
environmentPrefix_ = s;
return s;
}
}
/**
* string environment_prefix = 1 [json_name = "environmentPrefix"];
*
* @return The bytes for environmentPrefix.
*/
@java.lang.Override
public com.google.protobuf.ByteString getEnvironmentPrefixBytes() {
java.lang.Object ref = environmentPrefix_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
environmentPrefix_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int HOST_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object host_ = "";
/**
* optional string host = 2 [json_name = "host"];
*
* @return Whether the host field is set.
*/
@java.lang.Override
public boolean hasHost() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
* optional string host = 2 [json_name = "host"];
*
* @return The host.
*/
@java.lang.Override
public java.lang.String getHost() {
java.lang.Object ref = host_;
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();
host_ = s;
return s;
}
}
/**
* optional string host = 2 [json_name = "host"];
*
* @return The bytes for host.
*/
@java.lang.Override
public com.google.protobuf.ByteString getHostBytes() {
java.lang.Object ref = host_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
host_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PORT_FIELD_NUMBER = 3;
private int port_ = 0;
/**
* optional int32 port = 3 [json_name = "port"];
*
* @return Whether the port field is set.
*/
@java.lang.Override
public boolean hasPort() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
* optional int32 port = 3 [json_name = "port"];
*
* @return The port.
*/
@java.lang.Override
public int getPort() {
return port_;
}
public static final int DB_FIELD_NUMBER = 4;
private int db_ = 0;
/**
* optional int32 db = 4 [json_name = "db"];
*
* @return Whether the db field is set.
*/
@java.lang.Override
public boolean hasDb() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
* optional int32 db = 4 [json_name = "db"];
*
* @return The db.
*/
@java.lang.Override
public int getDb() {
return db_;
}
public static final int USERNAME_FIELD_NUMBER = 5;
@SuppressWarnings("serial")
private volatile java.lang.Object username_ = "";
/**
* optional string username = 5 [json_name = "username"];
*
* @return Whether the username field is set.
*/
@java.lang.Override
public boolean hasUsername() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
* optional string username = 5 [json_name = "username"];
*
* @return The username.
*/
@java.lang.Override
public java.lang.String getUsername() {
java.lang.Object ref = username_;
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();
username_ = s;
return s;
}
}
/**
* optional string username = 5 [json_name = "username"];
*
* @return The bytes for username.
*/
@java.lang.Override
public com.google.protobuf.ByteString getUsernameBytes() {
java.lang.Object ref = username_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
username_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PASSWORD_FIELD_NUMBER = 6;
@SuppressWarnings("serial")
private volatile java.lang.Object password_ = "";
/**
* optional string password = 6 [json_name = "password"];
*
* @return Whether the password field is set.
*/
@java.lang.Override
public boolean hasPassword() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
* optional string password = 6 [json_name = "password"];
*
* @return The password.
*/
@java.lang.Override
public java.lang.String getPassword() {
java.lang.Object ref = password_;
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();
password_ = s;
return s;
}
}
/**
* optional string password = 6 [json_name = "password"];
*
* @return The bytes for password.
*/
@java.lang.Override
public com.google.protobuf.ByteString getPasswordBytes() {
java.lang.Object ref = password_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
password_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int TTL_FIELD_NUMBER = 7;
private int ttl_ = 0;
/**
* optional int32 ttl = 7 [json_name = "ttl"];
*
* @return Whether the ttl field is set.
*/
@java.lang.Override
public boolean hasTtl() {
return ((bitField0_ & 0x00000020) != 0);
}
/**
* optional int32 ttl = 7 [json_name = "ttl"];
*
* @return The ttl.
*/
@java.lang.Override
public int getTtl() {
return ttl_;
}
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 (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(environmentPrefix_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, environmentPrefix_);
}
if (((bitField0_ & 0x00000001) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, host_);
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeInt32(3, port_);
}
if (((bitField0_ & 0x00000004) != 0)) {
output.writeInt32(4, db_);
}
if (((bitField0_ & 0x00000008) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 5, username_);
}
if (((bitField0_ & 0x00000010) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 6, password_);
}
if (((bitField0_ & 0x00000020) != 0)) {
output.writeInt32(7, ttl_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(environmentPrefix_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, environmentPrefix_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, host_);
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, port_);
}
if (((bitField0_ & 0x00000004) != 0)) {
size += com.google.protobuf.CodedOutputStream.computeInt32Size(4, db_);
}
if (((bitField0_ & 0x00000008) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, username_);
}
if (((bitField0_ & 0x00000010) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, password_);
}
if (((bitField0_ & 0x00000020) != 0)) {
size += com.google.protobuf.CodedOutputStream.computeInt32Size(7, ttl_);
}
size += getUnknownFields().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.stigg.sidecar.proto.v1.RedisOptions)) {
return super.equals(obj);
}
io.stigg.sidecar.proto.v1.RedisOptions other = (io.stigg.sidecar.proto.v1.RedisOptions) obj;
if (!getEnvironmentPrefix().equals(other.getEnvironmentPrefix())) return false;
if (hasHost() != other.hasHost()) return false;
if (hasHost()) {
if (!getHost().equals(other.getHost())) return false;
}
if (hasPort() != other.hasPort()) return false;
if (hasPort()) {
if (getPort() != other.getPort()) return false;
}
if (hasDb() != other.hasDb()) return false;
if (hasDb()) {
if (getDb() != other.getDb()) return false;
}
if (hasUsername() != other.hasUsername()) return false;
if (hasUsername()) {
if (!getUsername().equals(other.getUsername())) return false;
}
if (hasPassword() != other.hasPassword()) return false;
if (hasPassword()) {
if (!getPassword().equals(other.getPassword())) return false;
}
if (hasTtl() != other.hasTtl()) return false;
if (hasTtl()) {
if (getTtl() != other.getTtl()) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) 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) + ENVIRONMENT_PREFIX_FIELD_NUMBER;
hash = (53 * hash) + getEnvironmentPrefix().hashCode();
if (hasHost()) {
hash = (37 * hash) + HOST_FIELD_NUMBER;
hash = (53 * hash) + getHost().hashCode();
}
if (hasPort()) {
hash = (37 * hash) + PORT_FIELD_NUMBER;
hash = (53 * hash) + getPort();
}
if (hasDb()) {
hash = (37 * hash) + DB_FIELD_NUMBER;
hash = (53 * hash) + getDb();
}
if (hasUsername()) {
hash = (37 * hash) + USERNAME_FIELD_NUMBER;
hash = (53 * hash) + getUsername().hashCode();
}
if (hasPassword()) {
hash = (37 * hash) + PASSWORD_FIELD_NUMBER;
hash = (53 * hash) + getPassword().hashCode();
}
if (hasTtl()) {
hash = (37 * hash) + TTL_FIELD_NUMBER;
hash = (53 * hash) + getTtl();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.stigg.sidecar.proto.v1.RedisOptions parseFrom(java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.stigg.sidecar.proto.v1.RedisOptions parseFrom(
java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.stigg.sidecar.proto.v1.RedisOptions parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.stigg.sidecar.proto.v1.RedisOptions parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.stigg.sidecar.proto.v1.RedisOptions parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.stigg.sidecar.proto.v1.RedisOptions parseFrom(
byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.stigg.sidecar.proto.v1.RedisOptions parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
}
public static io.stigg.sidecar.proto.v1.RedisOptions 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.stigg.sidecar.proto.v1.RedisOptions parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
}
public static io.stigg.sidecar.proto.v1.RedisOptions 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.stigg.sidecar.proto.v1.RedisOptions parseFrom(
com.google.protobuf.CodedInputStream input) throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
}
public static io.stigg.sidecar.proto.v1.RedisOptions 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.stigg.sidecar.proto.v1.RedisOptions 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 stigg.sidecar.v1.RedisOptions} */
public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
implements
// @@protoc_insertion_point(builder_implements:stigg.sidecar.v1.RedisOptions)
io.stigg.sidecar.proto.v1.RedisOptionsOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
return io.stigg.sidecar.proto.v1.SidecarProto
.internal_static_stigg_sidecar_v1_RedisOptions_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.stigg.sidecar.proto.v1.SidecarProto
.internal_static_stigg_sidecar_v1_RedisOptions_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.stigg.sidecar.proto.v1.RedisOptions.class,
io.stigg.sidecar.proto.v1.RedisOptions.Builder.class);
}
// Construct using io.stigg.sidecar.proto.v1.RedisOptions.newBuilder()
private Builder() {}
private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
environmentPrefix_ = "";
host_ = "";
port_ = 0;
db_ = 0;
username_ = "";
password_ = "";
ttl_ = 0;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
return io.stigg.sidecar.proto.v1.SidecarProto
.internal_static_stigg_sidecar_v1_RedisOptions_descriptor;
}
@java.lang.Override
public io.stigg.sidecar.proto.v1.RedisOptions getDefaultInstanceForType() {
return io.stigg.sidecar.proto.v1.RedisOptions.getDefaultInstance();
}
@java.lang.Override
public io.stigg.sidecar.proto.v1.RedisOptions build() {
io.stigg.sidecar.proto.v1.RedisOptions result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.stigg.sidecar.proto.v1.RedisOptions buildPartial() {
io.stigg.sidecar.proto.v1.RedisOptions result =
new io.stigg.sidecar.proto.v1.RedisOptions(this);
if (bitField0_ != 0) {
buildPartial0(result);
}
onBuilt();
return result;
}
private void buildPartial0(io.stigg.sidecar.proto.v1.RedisOptions result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.environmentPrefix_ = environmentPrefix_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.host_ = host_;
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.port_ = port_;
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.db_ = db_;
to_bitField0_ |= 0x00000004;
}
if (((from_bitField0_ & 0x00000010) != 0)) {
result.username_ = username_;
to_bitField0_ |= 0x00000008;
}
if (((from_bitField0_ & 0x00000020) != 0)) {
result.password_ = password_;
to_bitField0_ |= 0x00000010;
}
if (((from_bitField0_ & 0x00000040) != 0)) {
result.ttl_ = ttl_;
to_bitField0_ |= 0x00000020;
}
result.bitField0_ |= to_bitField0_;
}
@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.stigg.sidecar.proto.v1.RedisOptions) {
return mergeFrom((io.stigg.sidecar.proto.v1.RedisOptions) other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.stigg.sidecar.proto.v1.RedisOptions other) {
if (other == io.stigg.sidecar.proto.v1.RedisOptions.getDefaultInstance()) return this;
if (!other.getEnvironmentPrefix().isEmpty()) {
environmentPrefix_ = other.environmentPrefix_;
bitField0_ |= 0x00000001;
onChanged();
}
if (other.hasHost()) {
host_ = other.host_;
bitField0_ |= 0x00000002;
onChanged();
}
if (other.hasPort()) {
setPort(other.getPort());
}
if (other.hasDb()) {
setDb(other.getDb());
}
if (other.hasUsername()) {
username_ = other.username_;
bitField0_ |= 0x00000010;
onChanged();
}
if (other.hasPassword()) {
password_ = other.password_;
bitField0_ |= 0x00000020;
onChanged();
}
if (other.hasTtl()) {
setTtl(other.getTtl());
}
this.mergeUnknownFields(other.getUnknownFields());
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 {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10:
{
environmentPrefix_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18:
{
host_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 24:
{
port_ = input.readInt32();
bitField0_ |= 0x00000004;
break;
} // case 24
case 32:
{
db_ = input.readInt32();
bitField0_ |= 0x00000008;
break;
} // case 32
case 42:
{
username_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000010;
break;
} // case 42
case 50:
{
password_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000020;
break;
} // case 50
case 56:
{
ttl_ = input.readInt32();
bitField0_ |= 0x00000040;
break;
} // case 56
default:
{
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object environmentPrefix_ = "";
/**
* string environment_prefix = 1 [json_name = "environmentPrefix"];
*
* @return The environmentPrefix.
*/
public java.lang.String getEnvironmentPrefix() {
java.lang.Object ref = environmentPrefix_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
environmentPrefix_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string environment_prefix = 1 [json_name = "environmentPrefix"];
*
* @return The bytes for environmentPrefix.
*/
public com.google.protobuf.ByteString getEnvironmentPrefixBytes() {
java.lang.Object ref = environmentPrefix_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
environmentPrefix_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string environment_prefix = 1 [json_name = "environmentPrefix"];
*
* @param value The environmentPrefix to set.
* @return This builder for chaining.
*/
public Builder setEnvironmentPrefix(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
environmentPrefix_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* string environment_prefix = 1 [json_name = "environmentPrefix"];
*
* @return This builder for chaining.
*/
public Builder clearEnvironmentPrefix() {
environmentPrefix_ = getDefaultInstance().getEnvironmentPrefix();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
* string environment_prefix = 1 [json_name = "environmentPrefix"];
*
* @param value The bytes for environmentPrefix to set.
* @return This builder for chaining.
*/
public Builder setEnvironmentPrefixBytes(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
environmentPrefix_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private java.lang.Object host_ = "";
/**
* optional string host = 2 [json_name = "host"];
*
* @return Whether the host field is set.
*/
public boolean hasHost() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
* optional string host = 2 [json_name = "host"];
*
* @return The host.
*/
public java.lang.String getHost() {
java.lang.Object ref = host_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
host_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* optional string host = 2 [json_name = "host"];
*
* @return The bytes for host.
*/
public com.google.protobuf.ByteString getHostBytes() {
java.lang.Object ref = host_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
host_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* optional string host = 2 [json_name = "host"];
*
* @param value The host to set.
* @return This builder for chaining.
*/
public Builder setHost(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
host_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
* optional string host = 2 [json_name = "host"];
*
* @return This builder for chaining.
*/
public Builder clearHost() {
host_ = getDefaultInstance().getHost();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
* optional string host = 2 [json_name = "host"];
*
* @param value The bytes for host to set.
* @return This builder for chaining.
*/
public Builder setHostBytes(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
host_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private int port_;
/**
* optional int32 port = 3 [json_name = "port"];
*
* @return Whether the port field is set.
*/
@java.lang.Override
public boolean hasPort() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
* optional int32 port = 3 [json_name = "port"];
*
* @return The port.
*/
@java.lang.Override
public int getPort() {
return port_;
}
/**
* optional int32 port = 3 [json_name = "port"];
*
* @param value The port to set.
* @return This builder for chaining.
*/
public Builder setPort(int value) {
port_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
* optional int32 port = 3 [json_name = "port"];
*
* @return This builder for chaining.
*/
public Builder clearPort() {
bitField0_ = (bitField0_ & ~0x00000004);
port_ = 0;
onChanged();
return this;
}
private int db_;
/**
* optional int32 db = 4 [json_name = "db"];
*
* @return Whether the db field is set.
*/
@java.lang.Override
public boolean hasDb() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
* optional int32 db = 4 [json_name = "db"];
*
* @return The db.
*/
@java.lang.Override
public int getDb() {
return db_;
}
/**
* optional int32 db = 4 [json_name = "db"];
*
* @param value The db to set.
* @return This builder for chaining.
*/
public Builder setDb(int value) {
db_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
* optional int32 db = 4 [json_name = "db"];
*
* @return This builder for chaining.
*/
public Builder clearDb() {
bitField0_ = (bitField0_ & ~0x00000008);
db_ = 0;
onChanged();
return this;
}
private java.lang.Object username_ = "";
/**
* optional string username = 5 [json_name = "username"];
*
* @return Whether the username field is set.
*/
public boolean hasUsername() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
* optional string username = 5 [json_name = "username"];
*
* @return The username.
*/
public java.lang.String getUsername() {
java.lang.Object ref = username_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
username_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* optional string username = 5 [json_name = "username"];
*
* @return The bytes for username.
*/
public com.google.protobuf.ByteString getUsernameBytes() {
java.lang.Object ref = username_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
username_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* optional string username = 5 [json_name = "username"];
*
* @param value The username to set.
* @return This builder for chaining.
*/
public Builder setUsername(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
username_ = value;
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
* optional string username = 5 [json_name = "username"];
*
* @return This builder for chaining.
*/
public Builder clearUsername() {
username_ = getDefaultInstance().getUsername();
bitField0_ = (bitField0_ & ~0x00000010);
onChanged();
return this;
}
/**
* optional string username = 5 [json_name = "username"];
*
* @param value The bytes for username to set.
* @return This builder for chaining.
*/
public Builder setUsernameBytes(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
username_ = value;
bitField0_ |= 0x00000010;
onChanged();
return this;
}
private java.lang.Object password_ = "";
/**
* optional string password = 6 [json_name = "password"];
*
* @return Whether the password field is set.
*/
public boolean hasPassword() {
return ((bitField0_ & 0x00000020) != 0);
}
/**
* optional string password = 6 [json_name = "password"];
*
* @return The password.
*/
public java.lang.String getPassword() {
java.lang.Object ref = password_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
password_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* optional string password = 6 [json_name = "password"];
*
* @return The bytes for password.
*/
public com.google.protobuf.ByteString getPasswordBytes() {
java.lang.Object ref = password_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
password_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* optional string password = 6 [json_name = "password"];
*
* @param value The password to set.
* @return This builder for chaining.
*/
public Builder setPassword(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
password_ = value;
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
* optional string password = 6 [json_name = "password"];
*
* @return This builder for chaining.
*/
public Builder clearPassword() {
password_ = getDefaultInstance().getPassword();
bitField0_ = (bitField0_ & ~0x00000020);
onChanged();
return this;
}
/**
* optional string password = 6 [json_name = "password"];
*
* @param value The bytes for password to set.
* @return This builder for chaining.
*/
public Builder setPasswordBytes(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
password_ = value;
bitField0_ |= 0x00000020;
onChanged();
return this;
}
private int ttl_;
/**
* optional int32 ttl = 7 [json_name = "ttl"];
*
* @return Whether the ttl field is set.
*/
@java.lang.Override
public boolean hasTtl() {
return ((bitField0_ & 0x00000040) != 0);
}
/**
* optional int32 ttl = 7 [json_name = "ttl"];
*
* @return The ttl.
*/
@java.lang.Override
public int getTtl() {
return ttl_;
}
/**
* optional int32 ttl = 7 [json_name = "ttl"];
*
* @param value The ttl to set.
* @return This builder for chaining.
*/
public Builder setTtl(int value) {
ttl_ = value;
bitField0_ |= 0x00000040;
onChanged();
return this;
}
/**
* optional int32 ttl = 7 [json_name = "ttl"];
*
* @return This builder for chaining.
*/
public Builder clearTtl() {
bitField0_ = (bitField0_ & ~0x00000040);
ttl_ = 0;
onChanged();
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:stigg.sidecar.v1.RedisOptions)
}
// @@protoc_insertion_point(class_scope:stigg.sidecar.v1.RedisOptions)
private static final io.stigg.sidecar.proto.v1.RedisOptions DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.stigg.sidecar.proto.v1.RedisOptions();
}
public static io.stigg.sidecar.proto.v1.RedisOptions getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser PARSER =
new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RedisOptions parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
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.stigg.sidecar.proto.v1.RedisOptions getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}