All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.finos.tracdap.config.PluginConfig Maven / Gradle / Ivy

Go to download

TRAC D.A.P. config library, contains data structures used for config files (and other config sources)

The newest version!
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// NO CHECKED-IN PROTOBUF GENCODE
// source: tracdap/config/common.proto
// Protobuf Java Version: 4.28.2

package org.finos.tracdap.config;

/**
 * Protobuf type {@code tracdap.config.PluginConfig}
 */
public final class PluginConfig extends
    com.google.protobuf.GeneratedMessage implements
    // @@protoc_insertion_point(message_implements:tracdap.config.PluginConfig)
    PluginConfigOrBuilder {
private static final long serialVersionUID = 0L;
  static {
    com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
      com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
      /* major= */ 4,
      /* minor= */ 28,
      /* patch= */ 2,
      /* suffix= */ "",
      PluginConfig.class.getName());
  }
  // Use PluginConfig.newBuilder() to construct.
  private PluginConfig(com.google.protobuf.GeneratedMessage.Builder builder) {
    super(builder);
  }
  private PluginConfig() {
    protocol_ = "";
  }

  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return org.finos.tracdap.config.Common.internal_static_tracdap_config_PluginConfig_descriptor;
  }

  @SuppressWarnings({"rawtypes"})
  @java.lang.Override
  protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(
      int number) {
    switch (number) {
      case 4:
        return internalGetPublicProperties();
      case 2:
        return internalGetProperties();
      case 3:
        return internalGetSecrets();
      default:
        throw new RuntimeException(
            "Invalid map field number: " + number);
    }
  }
  @java.lang.Override
  protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return org.finos.tracdap.config.Common.internal_static_tracdap_config_PluginConfig_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            org.finos.tracdap.config.PluginConfig.class, org.finos.tracdap.config.PluginConfig.Builder.class);
  }

  public static final int PROTOCOL_FIELD_NUMBER = 1;
  @SuppressWarnings("serial")
  private volatile java.lang.Object protocol_ = "";
  /**
   * string protocol = 1;
   * @return The protocol.
   */
  @java.lang.Override
  public java.lang.String getProtocol() {
    java.lang.Object ref = protocol_;
    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();
      protocol_ = s;
      return s;
    }
  }
  /**
   * string protocol = 1;
   * @return The bytes for protocol.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getProtocolBytes() {
    java.lang.Object ref = protocol_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      protocol_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int PUBLICPROPERTIES_FIELD_NUMBER = 4;
  private static final class PublicPropertiesDefaultEntryHolder {
    static final com.google.protobuf.MapEntry<
        java.lang.String, java.lang.String> defaultEntry =
            com.google.protobuf.MapEntry
            .newDefaultInstance(
                org.finos.tracdap.config.Common.internal_static_tracdap_config_PluginConfig_PublicPropertiesEntry_descriptor, 
                com.google.protobuf.WireFormat.FieldType.STRING,
                "",
                com.google.protobuf.WireFormat.FieldType.STRING,
                "");
  }
  @SuppressWarnings("serial")
  private com.google.protobuf.MapField<
      java.lang.String, java.lang.String> publicProperties_;
  private com.google.protobuf.MapField
  internalGetPublicProperties() {
    if (publicProperties_ == null) {
      return com.google.protobuf.MapField.emptyMapField(
          PublicPropertiesDefaultEntryHolder.defaultEntry);
    }
    return publicProperties_;
  }
  public int getPublicPropertiesCount() {
    return internalGetPublicProperties().getMap().size();
  }
  /**
   * map<string, string> publicProperties = 4;
   */
  @java.lang.Override
  public boolean containsPublicProperties(
      java.lang.String key) {
    if (key == null) { throw new NullPointerException("map key"); }
    return internalGetPublicProperties().getMap().containsKey(key);
  }
  /**
   * Use {@link #getPublicPropertiesMap()} instead.
   */
  @java.lang.Override
  @java.lang.Deprecated
  public java.util.Map getPublicProperties() {
    return getPublicPropertiesMap();
  }
  /**
   * map<string, string> publicProperties = 4;
   */
  @java.lang.Override
  public java.util.Map getPublicPropertiesMap() {
    return internalGetPublicProperties().getMap();
  }
  /**
   * map<string, string> publicProperties = 4;
   */
  @java.lang.Override
  public /* nullable */
java.lang.String getPublicPropertiesOrDefault(
      java.lang.String key,
      /* nullable */
java.lang.String defaultValue) {
    if (key == null) { throw new NullPointerException("map key"); }
    java.util.Map map =
        internalGetPublicProperties().getMap();
    return map.containsKey(key) ? map.get(key) : defaultValue;
  }
  /**
   * map<string, string> publicProperties = 4;
   */
  @java.lang.Override
  public java.lang.String getPublicPropertiesOrThrow(
      java.lang.String key) {
    if (key == null) { throw new NullPointerException("map key"); }
    java.util.Map map =
        internalGetPublicProperties().getMap();
    if (!map.containsKey(key)) {
      throw new java.lang.IllegalArgumentException();
    }
    return map.get(key);
  }

  public static final int PROPERTIES_FIELD_NUMBER = 2;
  private static final class PropertiesDefaultEntryHolder {
    static final com.google.protobuf.MapEntry<
        java.lang.String, java.lang.String> defaultEntry =
            com.google.protobuf.MapEntry
            .newDefaultInstance(
                org.finos.tracdap.config.Common.internal_static_tracdap_config_PluginConfig_PropertiesEntry_descriptor, 
                com.google.protobuf.WireFormat.FieldType.STRING,
                "",
                com.google.protobuf.WireFormat.FieldType.STRING,
                "");
  }
  @SuppressWarnings("serial")
  private com.google.protobuf.MapField<
      java.lang.String, java.lang.String> properties_;
  private com.google.protobuf.MapField
  internalGetProperties() {
    if (properties_ == null) {
      return com.google.protobuf.MapField.emptyMapField(
          PropertiesDefaultEntryHolder.defaultEntry);
    }
    return properties_;
  }
  public int getPropertiesCount() {
    return internalGetProperties().getMap().size();
  }
  /**
   * map<string, string> properties = 2;
   */
  @java.lang.Override
  public boolean containsProperties(
      java.lang.String key) {
    if (key == null) { throw new NullPointerException("map key"); }
    return internalGetProperties().getMap().containsKey(key);
  }
  /**
   * Use {@link #getPropertiesMap()} instead.
   */
  @java.lang.Override
  @java.lang.Deprecated
  public java.util.Map getProperties() {
    return getPropertiesMap();
  }
  /**
   * map<string, string> properties = 2;
   */
  @java.lang.Override
  public java.util.Map getPropertiesMap() {
    return internalGetProperties().getMap();
  }
  /**
   * map<string, string> properties = 2;
   */
  @java.lang.Override
  public /* nullable */
java.lang.String getPropertiesOrDefault(
      java.lang.String key,
      /* nullable */
java.lang.String defaultValue) {
    if (key == null) { throw new NullPointerException("map key"); }
    java.util.Map map =
        internalGetProperties().getMap();
    return map.containsKey(key) ? map.get(key) : defaultValue;
  }
  /**
   * map<string, string> properties = 2;
   */
  @java.lang.Override
  public java.lang.String getPropertiesOrThrow(
      java.lang.String key) {
    if (key == null) { throw new NullPointerException("map key"); }
    java.util.Map map =
        internalGetProperties().getMap();
    if (!map.containsKey(key)) {
      throw new java.lang.IllegalArgumentException();
    }
    return map.get(key);
  }

  public static final int SECRETS_FIELD_NUMBER = 3;
  private static final class SecretsDefaultEntryHolder {
    static final com.google.protobuf.MapEntry<
        java.lang.String, java.lang.String> defaultEntry =
            com.google.protobuf.MapEntry
            .newDefaultInstance(
                org.finos.tracdap.config.Common.internal_static_tracdap_config_PluginConfig_SecretsEntry_descriptor, 
                com.google.protobuf.WireFormat.FieldType.STRING,
                "",
                com.google.protobuf.WireFormat.FieldType.STRING,
                "");
  }
  @SuppressWarnings("serial")
  private com.google.protobuf.MapField<
      java.lang.String, java.lang.String> secrets_;
  private com.google.protobuf.MapField
  internalGetSecrets() {
    if (secrets_ == null) {
      return com.google.protobuf.MapField.emptyMapField(
          SecretsDefaultEntryHolder.defaultEntry);
    }
    return secrets_;
  }
  public int getSecretsCount() {
    return internalGetSecrets().getMap().size();
  }
  /**
   * map<string, string> secrets = 3;
   */
  @java.lang.Override
  public boolean containsSecrets(
      java.lang.String key) {
    if (key == null) { throw new NullPointerException("map key"); }
    return internalGetSecrets().getMap().containsKey(key);
  }
  /**
   * Use {@link #getSecretsMap()} instead.
   */
  @java.lang.Override
  @java.lang.Deprecated
  public java.util.Map getSecrets() {
    return getSecretsMap();
  }
  /**
   * map<string, string> secrets = 3;
   */
  @java.lang.Override
  public java.util.Map getSecretsMap() {
    return internalGetSecrets().getMap();
  }
  /**
   * map<string, string> secrets = 3;
   */
  @java.lang.Override
  public /* nullable */
java.lang.String getSecretsOrDefault(
      java.lang.String key,
      /* nullable */
java.lang.String defaultValue) {
    if (key == null) { throw new NullPointerException("map key"); }
    java.util.Map map =
        internalGetSecrets().getMap();
    return map.containsKey(key) ? map.get(key) : defaultValue;
  }
  /**
   * map<string, string> secrets = 3;
   */
  @java.lang.Override
  public java.lang.String getSecretsOrThrow(
      java.lang.String key) {
    if (key == null) { throw new NullPointerException("map key"); }
    java.util.Map map =
        internalGetSecrets().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 (!com.google.protobuf.GeneratedMessage.isStringEmpty(protocol_)) {
      com.google.protobuf.GeneratedMessage.writeString(output, 1, protocol_);
    }
    com.google.protobuf.GeneratedMessage
      .serializeStringMapTo(
        output,
        internalGetProperties(),
        PropertiesDefaultEntryHolder.defaultEntry,
        2);
    com.google.protobuf.GeneratedMessage
      .serializeStringMapTo(
        output,
        internalGetSecrets(),
        SecretsDefaultEntryHolder.defaultEntry,
        3);
    com.google.protobuf.GeneratedMessage
      .serializeStringMapTo(
        output,
        internalGetPublicProperties(),
        PublicPropertiesDefaultEntryHolder.defaultEntry,
        4);
    getUnknownFields().writeTo(output);
  }

  @java.lang.Override
  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    if (!com.google.protobuf.GeneratedMessage.isStringEmpty(protocol_)) {
      size += com.google.protobuf.GeneratedMessage.computeStringSize(1, protocol_);
    }
    for (java.util.Map.Entry entry
         : internalGetProperties().getMap().entrySet()) {
      com.google.protobuf.MapEntry
      properties__ = PropertiesDefaultEntryHolder.defaultEntry.newBuilderForType()
          .setKey(entry.getKey())
          .setValue(entry.getValue())
          .build();
      size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(2, properties__);
    }
    for (java.util.Map.Entry entry
         : internalGetSecrets().getMap().entrySet()) {
      com.google.protobuf.MapEntry
      secrets__ = SecretsDefaultEntryHolder.defaultEntry.newBuilderForType()
          .setKey(entry.getKey())
          .setValue(entry.getValue())
          .build();
      size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(3, secrets__);
    }
    for (java.util.Map.Entry entry
         : internalGetPublicProperties().getMap().entrySet()) {
      com.google.protobuf.MapEntry
      publicProperties__ = PublicPropertiesDefaultEntryHolder.defaultEntry.newBuilderForType()
          .setKey(entry.getKey())
          .setValue(entry.getValue())
          .build();
      size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(4, publicProperties__);
    }
    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 org.finos.tracdap.config.PluginConfig)) {
      return super.equals(obj);
    }
    org.finos.tracdap.config.PluginConfig other = (org.finos.tracdap.config.PluginConfig) obj;

    if (!getProtocol()
        .equals(other.getProtocol())) return false;
    if (!internalGetPublicProperties().equals(
        other.internalGetPublicProperties())) return false;
    if (!internalGetProperties().equals(
        other.internalGetProperties())) return false;
    if (!internalGetSecrets().equals(
        other.internalGetSecrets())) 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) + PROTOCOL_FIELD_NUMBER;
    hash = (53 * hash) + getProtocol().hashCode();
    if (!internalGetPublicProperties().getMap().isEmpty()) {
      hash = (37 * hash) + PUBLICPROPERTIES_FIELD_NUMBER;
      hash = (53 * hash) + internalGetPublicProperties().hashCode();
    }
    if (!internalGetProperties().getMap().isEmpty()) {
      hash = (37 * hash) + PROPERTIES_FIELD_NUMBER;
      hash = (53 * hash) + internalGetProperties().hashCode();
    }
    if (!internalGetSecrets().getMap().isEmpty()) {
      hash = (37 * hash) + SECRETS_FIELD_NUMBER;
      hash = (53 * hash) + internalGetSecrets().hashCode();
    }
    hash = (29 * hash) + getUnknownFields().hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static org.finos.tracdap.config.PluginConfig parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseWithIOException(PARSER, input);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  public static org.finos.tracdap.config.PluginConfig parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseDelimitedWithIOException(PARSER, input);
  }

  public static org.finos.tracdap.config.PluginConfig parseDelimitedFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseWithIOException(PARSER, input);
  }
  public static org.finos.tracdap.config.PluginConfig parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  @java.lang.Override
  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(org.finos.tracdap.config.PluginConfig 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.GeneratedMessage.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * Protobuf type {@code tracdap.config.PluginConfig}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessage.Builder implements
      // @@protoc_insertion_point(builder_implements:tracdap.config.PluginConfig)
      org.finos.tracdap.config.PluginConfigOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.finos.tracdap.config.Common.internal_static_tracdap_config_PluginConfig_descriptor;
    }

    @SuppressWarnings({"rawtypes"})
    protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(
        int number) {
      switch (number) {
        case 4:
          return internalGetPublicProperties();
        case 2:
          return internalGetProperties();
        case 3:
          return internalGetSecrets();
        default:
          throw new RuntimeException(
              "Invalid map field number: " + number);
      }
    }
    @SuppressWarnings({"rawtypes"})
    protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection(
        int number) {
      switch (number) {
        case 4:
          return internalGetMutablePublicProperties();
        case 2:
          return internalGetMutableProperties();
        case 3:
          return internalGetMutableSecrets();
        default:
          throw new RuntimeException(
              "Invalid map field number: " + number);
      }
    }
    @java.lang.Override
    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.finos.tracdap.config.Common.internal_static_tracdap_config_PluginConfig_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.finos.tracdap.config.PluginConfig.class, org.finos.tracdap.config.PluginConfig.Builder.class);
    }

    // Construct using org.finos.tracdap.config.PluginConfig.newBuilder()
    private Builder() {

    }

    private Builder(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      super(parent);

    }
    @java.lang.Override
    public Builder clear() {
      super.clear();
      bitField0_ = 0;
      protocol_ = "";
      internalGetMutablePublicProperties().clear();
      internalGetMutableProperties().clear();
      internalGetMutableSecrets().clear();
      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return org.finos.tracdap.config.Common.internal_static_tracdap_config_PluginConfig_descriptor;
    }

    @java.lang.Override
    public org.finos.tracdap.config.PluginConfig getDefaultInstanceForType() {
      return org.finos.tracdap.config.PluginConfig.getDefaultInstance();
    }

    @java.lang.Override
    public org.finos.tracdap.config.PluginConfig build() {
      org.finos.tracdap.config.PluginConfig result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public org.finos.tracdap.config.PluginConfig buildPartial() {
      org.finos.tracdap.config.PluginConfig result = new org.finos.tracdap.config.PluginConfig(this);
      if (bitField0_ != 0) { buildPartial0(result); }
      onBuilt();
      return result;
    }

    private void buildPartial0(org.finos.tracdap.config.PluginConfig result) {
      int from_bitField0_ = bitField0_;
      if (((from_bitField0_ & 0x00000001) != 0)) {
        result.protocol_ = protocol_;
      }
      if (((from_bitField0_ & 0x00000002) != 0)) {
        result.publicProperties_ = internalGetPublicProperties();
        result.publicProperties_.makeImmutable();
      }
      if (((from_bitField0_ & 0x00000004) != 0)) {
        result.properties_ = internalGetProperties();
        result.properties_.makeImmutable();
      }
      if (((from_bitField0_ & 0x00000008) != 0)) {
        result.secrets_ = internalGetSecrets();
        result.secrets_.makeImmutable();
      }
    }

    @java.lang.Override
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof org.finos.tracdap.config.PluginConfig) {
        return mergeFrom((org.finos.tracdap.config.PluginConfig)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(org.finos.tracdap.config.PluginConfig other) {
      if (other == org.finos.tracdap.config.PluginConfig.getDefaultInstance()) return this;
      if (!other.getProtocol().isEmpty()) {
        protocol_ = other.protocol_;
        bitField0_ |= 0x00000001;
        onChanged();
      }
      internalGetMutablePublicProperties().mergeFrom(
          other.internalGetPublicProperties());
      bitField0_ |= 0x00000002;
      internalGetMutableProperties().mergeFrom(
          other.internalGetProperties());
      bitField0_ |= 0x00000004;
      internalGetMutableSecrets().mergeFrom(
          other.internalGetSecrets());
      bitField0_ |= 0x00000008;
      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: {
              protocol_ = input.readStringRequireUtf8();
              bitField0_ |= 0x00000001;
              break;
            } // case 10
            case 18: {
              com.google.protobuf.MapEntry
              properties__ = input.readMessage(
                  PropertiesDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
              internalGetMutableProperties().getMutableMap().put(
                  properties__.getKey(), properties__.getValue());
              bitField0_ |= 0x00000004;
              break;
            } // case 18
            case 26: {
              com.google.protobuf.MapEntry
              secrets__ = input.readMessage(
                  SecretsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
              internalGetMutableSecrets().getMutableMap().put(
                  secrets__.getKey(), secrets__.getValue());
              bitField0_ |= 0x00000008;
              break;
            } // case 26
            case 34: {
              com.google.protobuf.MapEntry
              publicProperties__ = input.readMessage(
                  PublicPropertiesDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
              internalGetMutablePublicProperties().getMutableMap().put(
                  publicProperties__.getKey(), publicProperties__.getValue());
              bitField0_ |= 0x00000002;
              break;
            } // case 34
            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 protocol_ = "";
    /**
     * string protocol = 1;
     * @return The protocol.
     */
    public java.lang.String getProtocol() {
      java.lang.Object ref = protocol_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        protocol_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * string protocol = 1;
     * @return The bytes for protocol.
     */
    public com.google.protobuf.ByteString
        getProtocolBytes() {
      java.lang.Object ref = protocol_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        protocol_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * string protocol = 1;
     * @param value The protocol to set.
     * @return This builder for chaining.
     */
    public Builder setProtocol(
        java.lang.String value) {
      if (value == null) { throw new NullPointerException(); }
      protocol_ = value;
      bitField0_ |= 0x00000001;
      onChanged();
      return this;
    }
    /**
     * string protocol = 1;
     * @return This builder for chaining.
     */
    public Builder clearProtocol() {
      protocol_ = getDefaultInstance().getProtocol();
      bitField0_ = (bitField0_ & ~0x00000001);
      onChanged();
      return this;
    }
    /**
     * string protocol = 1;
     * @param value The bytes for protocol to set.
     * @return This builder for chaining.
     */
    public Builder setProtocolBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) { throw new NullPointerException(); }
      checkByteStringIsUtf8(value);
      protocol_ = value;
      bitField0_ |= 0x00000001;
      onChanged();
      return this;
    }

    private com.google.protobuf.MapField<
        java.lang.String, java.lang.String> publicProperties_;
    private com.google.protobuf.MapField
        internalGetPublicProperties() {
      if (publicProperties_ == null) {
        return com.google.protobuf.MapField.emptyMapField(
            PublicPropertiesDefaultEntryHolder.defaultEntry);
      }
      return publicProperties_;
    }
    private com.google.protobuf.MapField
        internalGetMutablePublicProperties() {
      if (publicProperties_ == null) {
        publicProperties_ = com.google.protobuf.MapField.newMapField(
            PublicPropertiesDefaultEntryHolder.defaultEntry);
      }
      if (!publicProperties_.isMutable()) {
        publicProperties_ = publicProperties_.copy();
      }
      bitField0_ |= 0x00000002;
      onChanged();
      return publicProperties_;
    }
    public int getPublicPropertiesCount() {
      return internalGetPublicProperties().getMap().size();
    }
    /**
     * map<string, string> publicProperties = 4;
     */
    @java.lang.Override
    public boolean containsPublicProperties(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      return internalGetPublicProperties().getMap().containsKey(key);
    }
    /**
     * Use {@link #getPublicPropertiesMap()} instead.
     */
    @java.lang.Override
    @java.lang.Deprecated
    public java.util.Map getPublicProperties() {
      return getPublicPropertiesMap();
    }
    /**
     * map<string, string> publicProperties = 4;
     */
    @java.lang.Override
    public java.util.Map getPublicPropertiesMap() {
      return internalGetPublicProperties().getMap();
    }
    /**
     * map<string, string> publicProperties = 4;
     */
    @java.lang.Override
    public /* nullable */
java.lang.String getPublicPropertiesOrDefault(
        java.lang.String key,
        /* nullable */
java.lang.String defaultValue) {
      if (key == null) { throw new NullPointerException("map key"); }
      java.util.Map map =
          internalGetPublicProperties().getMap();
      return map.containsKey(key) ? map.get(key) : defaultValue;
    }
    /**
     * map<string, string> publicProperties = 4;
     */
    @java.lang.Override
    public java.lang.String getPublicPropertiesOrThrow(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      java.util.Map map =
          internalGetPublicProperties().getMap();
      if (!map.containsKey(key)) {
        throw new java.lang.IllegalArgumentException();
      }
      return map.get(key);
    }
    public Builder clearPublicProperties() {
      bitField0_ = (bitField0_ & ~0x00000002);
      internalGetMutablePublicProperties().getMutableMap()
          .clear();
      return this;
    }
    /**
     * map<string, string> publicProperties = 4;
     */
    public Builder removePublicProperties(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      internalGetMutablePublicProperties().getMutableMap()
          .remove(key);
      return this;
    }
    /**
     * Use alternate mutation accessors instead.
     */
    @java.lang.Deprecated
    public java.util.Map
        getMutablePublicProperties() {
      bitField0_ |= 0x00000002;
      return internalGetMutablePublicProperties().getMutableMap();
    }
    /**
     * map<string, string> publicProperties = 4;
     */
    public Builder putPublicProperties(
        java.lang.String key,
        java.lang.String value) {
      if (key == null) { throw new NullPointerException("map key"); }
      if (value == null) { throw new NullPointerException("map value"); }
      internalGetMutablePublicProperties().getMutableMap()
          .put(key, value);
      bitField0_ |= 0x00000002;
      return this;
    }
    /**
     * map<string, string> publicProperties = 4;
     */
    public Builder putAllPublicProperties(
        java.util.Map values) {
      internalGetMutablePublicProperties().getMutableMap()
          .putAll(values);
      bitField0_ |= 0x00000002;
      return this;
    }

    private com.google.protobuf.MapField<
        java.lang.String, java.lang.String> properties_;
    private com.google.protobuf.MapField
        internalGetProperties() {
      if (properties_ == null) {
        return com.google.protobuf.MapField.emptyMapField(
            PropertiesDefaultEntryHolder.defaultEntry);
      }
      return properties_;
    }
    private com.google.protobuf.MapField
        internalGetMutableProperties() {
      if (properties_ == null) {
        properties_ = com.google.protobuf.MapField.newMapField(
            PropertiesDefaultEntryHolder.defaultEntry);
      }
      if (!properties_.isMutable()) {
        properties_ = properties_.copy();
      }
      bitField0_ |= 0x00000004;
      onChanged();
      return properties_;
    }
    public int getPropertiesCount() {
      return internalGetProperties().getMap().size();
    }
    /**
     * map<string, string> properties = 2;
     */
    @java.lang.Override
    public boolean containsProperties(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      return internalGetProperties().getMap().containsKey(key);
    }
    /**
     * Use {@link #getPropertiesMap()} instead.
     */
    @java.lang.Override
    @java.lang.Deprecated
    public java.util.Map getProperties() {
      return getPropertiesMap();
    }
    /**
     * map<string, string> properties = 2;
     */
    @java.lang.Override
    public java.util.Map getPropertiesMap() {
      return internalGetProperties().getMap();
    }
    /**
     * map<string, string> properties = 2;
     */
    @java.lang.Override
    public /* nullable */
java.lang.String getPropertiesOrDefault(
        java.lang.String key,
        /* nullable */
java.lang.String defaultValue) {
      if (key == null) { throw new NullPointerException("map key"); }
      java.util.Map map =
          internalGetProperties().getMap();
      return map.containsKey(key) ? map.get(key) : defaultValue;
    }
    /**
     * map<string, string> properties = 2;
     */
    @java.lang.Override
    public java.lang.String getPropertiesOrThrow(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      java.util.Map map =
          internalGetProperties().getMap();
      if (!map.containsKey(key)) {
        throw new java.lang.IllegalArgumentException();
      }
      return map.get(key);
    }
    public Builder clearProperties() {
      bitField0_ = (bitField0_ & ~0x00000004);
      internalGetMutableProperties().getMutableMap()
          .clear();
      return this;
    }
    /**
     * map<string, string> properties = 2;
     */
    public Builder removeProperties(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      internalGetMutableProperties().getMutableMap()
          .remove(key);
      return this;
    }
    /**
     * Use alternate mutation accessors instead.
     */
    @java.lang.Deprecated
    public java.util.Map
        getMutableProperties() {
      bitField0_ |= 0x00000004;
      return internalGetMutableProperties().getMutableMap();
    }
    /**
     * map<string, string> properties = 2;
     */
    public Builder putProperties(
        java.lang.String key,
        java.lang.String value) {
      if (key == null) { throw new NullPointerException("map key"); }
      if (value == null) { throw new NullPointerException("map value"); }
      internalGetMutableProperties().getMutableMap()
          .put(key, value);
      bitField0_ |= 0x00000004;
      return this;
    }
    /**
     * map<string, string> properties = 2;
     */
    public Builder putAllProperties(
        java.util.Map values) {
      internalGetMutableProperties().getMutableMap()
          .putAll(values);
      bitField0_ |= 0x00000004;
      return this;
    }

    private com.google.protobuf.MapField<
        java.lang.String, java.lang.String> secrets_;
    private com.google.protobuf.MapField
        internalGetSecrets() {
      if (secrets_ == null) {
        return com.google.protobuf.MapField.emptyMapField(
            SecretsDefaultEntryHolder.defaultEntry);
      }
      return secrets_;
    }
    private com.google.protobuf.MapField
        internalGetMutableSecrets() {
      if (secrets_ == null) {
        secrets_ = com.google.protobuf.MapField.newMapField(
            SecretsDefaultEntryHolder.defaultEntry);
      }
      if (!secrets_.isMutable()) {
        secrets_ = secrets_.copy();
      }
      bitField0_ |= 0x00000008;
      onChanged();
      return secrets_;
    }
    public int getSecretsCount() {
      return internalGetSecrets().getMap().size();
    }
    /**
     * map<string, string> secrets = 3;
     */
    @java.lang.Override
    public boolean containsSecrets(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      return internalGetSecrets().getMap().containsKey(key);
    }
    /**
     * Use {@link #getSecretsMap()} instead.
     */
    @java.lang.Override
    @java.lang.Deprecated
    public java.util.Map getSecrets() {
      return getSecretsMap();
    }
    /**
     * map<string, string> secrets = 3;
     */
    @java.lang.Override
    public java.util.Map getSecretsMap() {
      return internalGetSecrets().getMap();
    }
    /**
     * map<string, string> secrets = 3;
     */
    @java.lang.Override
    public /* nullable */
java.lang.String getSecretsOrDefault(
        java.lang.String key,
        /* nullable */
java.lang.String defaultValue) {
      if (key == null) { throw new NullPointerException("map key"); }
      java.util.Map map =
          internalGetSecrets().getMap();
      return map.containsKey(key) ? map.get(key) : defaultValue;
    }
    /**
     * map<string, string> secrets = 3;
     */
    @java.lang.Override
    public java.lang.String getSecretsOrThrow(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      java.util.Map map =
          internalGetSecrets().getMap();
      if (!map.containsKey(key)) {
        throw new java.lang.IllegalArgumentException();
      }
      return map.get(key);
    }
    public Builder clearSecrets() {
      bitField0_ = (bitField0_ & ~0x00000008);
      internalGetMutableSecrets().getMutableMap()
          .clear();
      return this;
    }
    /**
     * map<string, string> secrets = 3;
     */
    public Builder removeSecrets(
        java.lang.String key) {
      if (key == null) { throw new NullPointerException("map key"); }
      internalGetMutableSecrets().getMutableMap()
          .remove(key);
      return this;
    }
    /**
     * Use alternate mutation accessors instead.
     */
    @java.lang.Deprecated
    public java.util.Map
        getMutableSecrets() {
      bitField0_ |= 0x00000008;
      return internalGetMutableSecrets().getMutableMap();
    }
    /**
     * map<string, string> secrets = 3;
     */
    public Builder putSecrets(
        java.lang.String key,
        java.lang.String value) {
      if (key == null) { throw new NullPointerException("map key"); }
      if (value == null) { throw new NullPointerException("map value"); }
      internalGetMutableSecrets().getMutableMap()
          .put(key, value);
      bitField0_ |= 0x00000008;
      return this;
    }
    /**
     * map<string, string> secrets = 3;
     */
    public Builder putAllSecrets(
        java.util.Map values) {
      internalGetMutableSecrets().getMutableMap()
          .putAll(values);
      bitField0_ |= 0x00000008;
      return this;
    }

    // @@protoc_insertion_point(builder_scope:tracdap.config.PluginConfig)
  }

  // @@protoc_insertion_point(class_scope:tracdap.config.PluginConfig)
  private static final org.finos.tracdap.config.PluginConfig DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new org.finos.tracdap.config.PluginConfig();
  }

  public static org.finos.tracdap.config.PluginConfig getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser
      PARSER = new com.google.protobuf.AbstractParser() {
    @java.lang.Override
    public PluginConfig 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 org.finos.tracdap.config.PluginConfig getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy