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

com.google.cloud.datastream.v1alpha1.SourceConfig Maven / Gradle / Ivy

The newest version!
/*
 * Copyright 2024 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/cloud/datastream/v1alpha1/datastream_resources.proto

// Protobuf Java Version: 3.25.5
package com.google.cloud.datastream.v1alpha1;

/**
 *
 *
 * 
 * The configuration of the stream source.
 * 
* * Protobuf type {@code google.cloud.datastream.v1alpha1.SourceConfig} */ public final class SourceConfig extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.datastream.v1alpha1.SourceConfig) SourceConfigOrBuilder { private static final long serialVersionUID = 0L; // Use SourceConfig.newBuilder() to construct. private SourceConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private SourceConfig() { sourceConnectionProfileName_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new SourceConfig(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.datastream.v1alpha1.CloudDatastreamResourcesProto .internal_static_google_cloud_datastream_v1alpha1_SourceConfig_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.datastream.v1alpha1.CloudDatastreamResourcesProto .internal_static_google_cloud_datastream_v1alpha1_SourceConfig_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.datastream.v1alpha1.SourceConfig.class, com.google.cloud.datastream.v1alpha1.SourceConfig.Builder.class); } private int sourceStreamConfigCase_ = 0; @SuppressWarnings("serial") private java.lang.Object sourceStreamConfig_; public enum SourceStreamConfigCase implements com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { ORACLE_SOURCE_CONFIG(100), MYSQL_SOURCE_CONFIG(101), SOURCESTREAMCONFIG_NOT_SET(0); private final int value; private SourceStreamConfigCase(int value) { this.value = value; } /** * @param value The number of the enum to look for. * @return The enum associated with the given number. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static SourceStreamConfigCase valueOf(int value) { return forNumber(value); } public static SourceStreamConfigCase forNumber(int value) { switch (value) { case 100: return ORACLE_SOURCE_CONFIG; case 101: return MYSQL_SOURCE_CONFIG; case 0: return SOURCESTREAMCONFIG_NOT_SET; default: return null; } } public int getNumber() { return this.value; } }; public SourceStreamConfigCase getSourceStreamConfigCase() { return SourceStreamConfigCase.forNumber(sourceStreamConfigCase_); } public static final int SOURCE_CONNECTION_PROFILE_NAME_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object sourceConnectionProfileName_ = ""; /** * * *
   * Required. Source connection profile identifier.
   * 
* * string source_connection_profile_name = 1 [(.google.api.field_behavior) = REQUIRED]; * * * @return The sourceConnectionProfileName. */ @java.lang.Override public java.lang.String getSourceConnectionProfileName() { java.lang.Object ref = sourceConnectionProfileName_; 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(); sourceConnectionProfileName_ = s; return s; } } /** * * *
   * Required. Source connection profile identifier.
   * 
* * string source_connection_profile_name = 1 [(.google.api.field_behavior) = REQUIRED]; * * * @return The bytes for sourceConnectionProfileName. */ @java.lang.Override public com.google.protobuf.ByteString getSourceConnectionProfileNameBytes() { java.lang.Object ref = sourceConnectionProfileName_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); sourceConnectionProfileName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int ORACLE_SOURCE_CONFIG_FIELD_NUMBER = 100; /** * * *
   * Oracle data source configuration
   * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; * * @return Whether the oracleSourceConfig field is set. */ @java.lang.Override public boolean hasOracleSourceConfig() { return sourceStreamConfigCase_ == 100; } /** * * *
   * Oracle data source configuration
   * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; * * @return The oracleSourceConfig. */ @java.lang.Override public com.google.cloud.datastream.v1alpha1.OracleSourceConfig getOracleSourceConfig() { if (sourceStreamConfigCase_ == 100) { return (com.google.cloud.datastream.v1alpha1.OracleSourceConfig) sourceStreamConfig_; } return com.google.cloud.datastream.v1alpha1.OracleSourceConfig.getDefaultInstance(); } /** * * *
   * Oracle data source configuration
   * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; */ @java.lang.Override public com.google.cloud.datastream.v1alpha1.OracleSourceConfigOrBuilder getOracleSourceConfigOrBuilder() { if (sourceStreamConfigCase_ == 100) { return (com.google.cloud.datastream.v1alpha1.OracleSourceConfig) sourceStreamConfig_; } return com.google.cloud.datastream.v1alpha1.OracleSourceConfig.getDefaultInstance(); } public static final int MYSQL_SOURCE_CONFIG_FIELD_NUMBER = 101; /** * * *
   * MySQL data source configuration
   * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; * * @return Whether the mysqlSourceConfig field is set. */ @java.lang.Override public boolean hasMysqlSourceConfig() { return sourceStreamConfigCase_ == 101; } /** * * *
   * MySQL data source configuration
   * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; * * @return The mysqlSourceConfig. */ @java.lang.Override public com.google.cloud.datastream.v1alpha1.MysqlSourceConfig getMysqlSourceConfig() { if (sourceStreamConfigCase_ == 101) { return (com.google.cloud.datastream.v1alpha1.MysqlSourceConfig) sourceStreamConfig_; } return com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.getDefaultInstance(); } /** * * *
   * MySQL data source configuration
   * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; */ @java.lang.Override public com.google.cloud.datastream.v1alpha1.MysqlSourceConfigOrBuilder getMysqlSourceConfigOrBuilder() { if (sourceStreamConfigCase_ == 101) { return (com.google.cloud.datastream.v1alpha1.MysqlSourceConfig) sourceStreamConfig_; } return com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.getDefaultInstance(); } 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(sourceConnectionProfileName_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, sourceConnectionProfileName_); } if (sourceStreamConfigCase_ == 100) { output.writeMessage( 100, (com.google.cloud.datastream.v1alpha1.OracleSourceConfig) sourceStreamConfig_); } if (sourceStreamConfigCase_ == 101) { output.writeMessage( 101, (com.google.cloud.datastream.v1alpha1.MysqlSourceConfig) sourceStreamConfig_); } 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(sourceConnectionProfileName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, sourceConnectionProfileName_); } if (sourceStreamConfigCase_ == 100) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( 100, (com.google.cloud.datastream.v1alpha1.OracleSourceConfig) sourceStreamConfig_); } if (sourceStreamConfigCase_ == 101) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( 101, (com.google.cloud.datastream.v1alpha1.MysqlSourceConfig) sourceStreamConfig_); } 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 com.google.cloud.datastream.v1alpha1.SourceConfig)) { return super.equals(obj); } com.google.cloud.datastream.v1alpha1.SourceConfig other = (com.google.cloud.datastream.v1alpha1.SourceConfig) obj; if (!getSourceConnectionProfileName().equals(other.getSourceConnectionProfileName())) return false; if (!getSourceStreamConfigCase().equals(other.getSourceStreamConfigCase())) return false; switch (sourceStreamConfigCase_) { case 100: if (!getOracleSourceConfig().equals(other.getOracleSourceConfig())) return false; break; case 101: if (!getMysqlSourceConfig().equals(other.getMysqlSourceConfig())) return false; break; case 0: default: } 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) + SOURCE_CONNECTION_PROFILE_NAME_FIELD_NUMBER; hash = (53 * hash) + getSourceConnectionProfileName().hashCode(); switch (sourceStreamConfigCase_) { case 100: hash = (37 * hash) + ORACLE_SOURCE_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getOracleSourceConfig().hashCode(); break; case 101: hash = (37 * hash) + MYSQL_SOURCE_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getMysqlSourceConfig().hashCode(); break; case 0: default: } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.datastream.v1alpha1.SourceConfig parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.datastream.v1alpha1.SourceConfig parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.datastream.v1alpha1.SourceConfig parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.datastream.v1alpha1.SourceConfig parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.datastream.v1alpha1.SourceConfig parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.datastream.v1alpha1.SourceConfig parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.datastream.v1alpha1.SourceConfig parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.datastream.v1alpha1.SourceConfig 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 com.google.cloud.datastream.v1alpha1.SourceConfig parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.datastream.v1alpha1.SourceConfig 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 com.google.cloud.datastream.v1alpha1.SourceConfig parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.datastream.v1alpha1.SourceConfig 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(com.google.cloud.datastream.v1alpha1.SourceConfig 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; } /** * * *
   * The configuration of the stream source.
   * 
* * Protobuf type {@code google.cloud.datastream.v1alpha1.SourceConfig} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.datastream.v1alpha1.SourceConfig) com.google.cloud.datastream.v1alpha1.SourceConfigOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.datastream.v1alpha1.CloudDatastreamResourcesProto .internal_static_google_cloud_datastream_v1alpha1_SourceConfig_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.datastream.v1alpha1.CloudDatastreamResourcesProto .internal_static_google_cloud_datastream_v1alpha1_SourceConfig_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.datastream.v1alpha1.SourceConfig.class, com.google.cloud.datastream.v1alpha1.SourceConfig.Builder.class); } // Construct using com.google.cloud.datastream.v1alpha1.SourceConfig.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; sourceConnectionProfileName_ = ""; if (oracleSourceConfigBuilder_ != null) { oracleSourceConfigBuilder_.clear(); } if (mysqlSourceConfigBuilder_ != null) { mysqlSourceConfigBuilder_.clear(); } sourceStreamConfigCase_ = 0; sourceStreamConfig_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.datastream.v1alpha1.CloudDatastreamResourcesProto .internal_static_google_cloud_datastream_v1alpha1_SourceConfig_descriptor; } @java.lang.Override public com.google.cloud.datastream.v1alpha1.SourceConfig getDefaultInstanceForType() { return com.google.cloud.datastream.v1alpha1.SourceConfig.getDefaultInstance(); } @java.lang.Override public com.google.cloud.datastream.v1alpha1.SourceConfig build() { com.google.cloud.datastream.v1alpha1.SourceConfig result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.datastream.v1alpha1.SourceConfig buildPartial() { com.google.cloud.datastream.v1alpha1.SourceConfig result = new com.google.cloud.datastream.v1alpha1.SourceConfig(this); if (bitField0_ != 0) { buildPartial0(result); } buildPartialOneofs(result); onBuilt(); return result; } private void buildPartial0(com.google.cloud.datastream.v1alpha1.SourceConfig result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.sourceConnectionProfileName_ = sourceConnectionProfileName_; } } private void buildPartialOneofs(com.google.cloud.datastream.v1alpha1.SourceConfig result) { result.sourceStreamConfigCase_ = sourceStreamConfigCase_; result.sourceStreamConfig_ = this.sourceStreamConfig_; if (sourceStreamConfigCase_ == 100 && oracleSourceConfigBuilder_ != null) { result.sourceStreamConfig_ = oracleSourceConfigBuilder_.build(); } if (sourceStreamConfigCase_ == 101 && mysqlSourceConfigBuilder_ != null) { result.sourceStreamConfig_ = mysqlSourceConfigBuilder_.build(); } } @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 com.google.cloud.datastream.v1alpha1.SourceConfig) { return mergeFrom((com.google.cloud.datastream.v1alpha1.SourceConfig) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.datastream.v1alpha1.SourceConfig other) { if (other == com.google.cloud.datastream.v1alpha1.SourceConfig.getDefaultInstance()) return this; if (!other.getSourceConnectionProfileName().isEmpty()) { sourceConnectionProfileName_ = other.sourceConnectionProfileName_; bitField0_ |= 0x00000001; onChanged(); } switch (other.getSourceStreamConfigCase()) { case ORACLE_SOURCE_CONFIG: { mergeOracleSourceConfig(other.getOracleSourceConfig()); break; } case MYSQL_SOURCE_CONFIG: { mergeMysqlSourceConfig(other.getMysqlSourceConfig()); break; } case SOURCESTREAMCONFIG_NOT_SET: { break; } } 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: { sourceConnectionProfileName_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 802: { input.readMessage( getOracleSourceConfigFieldBuilder().getBuilder(), extensionRegistry); sourceStreamConfigCase_ = 100; break; } // case 802 case 810: { input.readMessage( getMysqlSourceConfigFieldBuilder().getBuilder(), extensionRegistry); sourceStreamConfigCase_ = 101; break; } // case 810 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 sourceStreamConfigCase_ = 0; private java.lang.Object sourceStreamConfig_; public SourceStreamConfigCase getSourceStreamConfigCase() { return SourceStreamConfigCase.forNumber(sourceStreamConfigCase_); } public Builder clearSourceStreamConfig() { sourceStreamConfigCase_ = 0; sourceStreamConfig_ = null; onChanged(); return this; } private int bitField0_; private java.lang.Object sourceConnectionProfileName_ = ""; /** * * *
     * Required. Source connection profile identifier.
     * 
* * string source_connection_profile_name = 1 [(.google.api.field_behavior) = REQUIRED]; * * * @return The sourceConnectionProfileName. */ public java.lang.String getSourceConnectionProfileName() { java.lang.Object ref = sourceConnectionProfileName_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); sourceConnectionProfileName_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Required. Source connection profile identifier.
     * 
* * string source_connection_profile_name = 1 [(.google.api.field_behavior) = REQUIRED]; * * * @return The bytes for sourceConnectionProfileName. */ public com.google.protobuf.ByteString getSourceConnectionProfileNameBytes() { java.lang.Object ref = sourceConnectionProfileName_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); sourceConnectionProfileName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Required. Source connection profile identifier.
     * 
* * string source_connection_profile_name = 1 [(.google.api.field_behavior) = REQUIRED]; * * * @param value The sourceConnectionProfileName to set. * @return This builder for chaining. */ public Builder setSourceConnectionProfileName(java.lang.String value) { if (value == null) { throw new NullPointerException(); } sourceConnectionProfileName_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
     * Required. Source connection profile identifier.
     * 
* * string source_connection_profile_name = 1 [(.google.api.field_behavior) = REQUIRED]; * * * @return This builder for chaining. */ public Builder clearSourceConnectionProfileName() { sourceConnectionProfileName_ = getDefaultInstance().getSourceConnectionProfileName(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * * *
     * Required. Source connection profile identifier.
     * 
* * string source_connection_profile_name = 1 [(.google.api.field_behavior) = REQUIRED]; * * * @param value The bytes for sourceConnectionProfileName to set. * @return This builder for chaining. */ public Builder setSourceConnectionProfileNameBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); sourceConnectionProfileName_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.datastream.v1alpha1.OracleSourceConfig, com.google.cloud.datastream.v1alpha1.OracleSourceConfig.Builder, com.google.cloud.datastream.v1alpha1.OracleSourceConfigOrBuilder> oracleSourceConfigBuilder_; /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; * * @return Whether the oracleSourceConfig field is set. */ @java.lang.Override public boolean hasOracleSourceConfig() { return sourceStreamConfigCase_ == 100; } /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; * * @return The oracleSourceConfig. */ @java.lang.Override public com.google.cloud.datastream.v1alpha1.OracleSourceConfig getOracleSourceConfig() { if (oracleSourceConfigBuilder_ == null) { if (sourceStreamConfigCase_ == 100) { return (com.google.cloud.datastream.v1alpha1.OracleSourceConfig) sourceStreamConfig_; } return com.google.cloud.datastream.v1alpha1.OracleSourceConfig.getDefaultInstance(); } else { if (sourceStreamConfigCase_ == 100) { return oracleSourceConfigBuilder_.getMessage(); } return com.google.cloud.datastream.v1alpha1.OracleSourceConfig.getDefaultInstance(); } } /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; */ public Builder setOracleSourceConfig( com.google.cloud.datastream.v1alpha1.OracleSourceConfig value) { if (oracleSourceConfigBuilder_ == null) { if (value == null) { throw new NullPointerException(); } sourceStreamConfig_ = value; onChanged(); } else { oracleSourceConfigBuilder_.setMessage(value); } sourceStreamConfigCase_ = 100; return this; } /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; */ public Builder setOracleSourceConfig( com.google.cloud.datastream.v1alpha1.OracleSourceConfig.Builder builderForValue) { if (oracleSourceConfigBuilder_ == null) { sourceStreamConfig_ = builderForValue.build(); onChanged(); } else { oracleSourceConfigBuilder_.setMessage(builderForValue.build()); } sourceStreamConfigCase_ = 100; return this; } /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; */ public Builder mergeOracleSourceConfig( com.google.cloud.datastream.v1alpha1.OracleSourceConfig value) { if (oracleSourceConfigBuilder_ == null) { if (sourceStreamConfigCase_ == 100 && sourceStreamConfig_ != com.google.cloud.datastream.v1alpha1.OracleSourceConfig.getDefaultInstance()) { sourceStreamConfig_ = com.google.cloud.datastream.v1alpha1.OracleSourceConfig.newBuilder( (com.google.cloud.datastream.v1alpha1.OracleSourceConfig) sourceStreamConfig_) .mergeFrom(value) .buildPartial(); } else { sourceStreamConfig_ = value; } onChanged(); } else { if (sourceStreamConfigCase_ == 100) { oracleSourceConfigBuilder_.mergeFrom(value); } else { oracleSourceConfigBuilder_.setMessage(value); } } sourceStreamConfigCase_ = 100; return this; } /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; */ public Builder clearOracleSourceConfig() { if (oracleSourceConfigBuilder_ == null) { if (sourceStreamConfigCase_ == 100) { sourceStreamConfigCase_ = 0; sourceStreamConfig_ = null; onChanged(); } } else { if (sourceStreamConfigCase_ == 100) { sourceStreamConfigCase_ = 0; sourceStreamConfig_ = null; } oracleSourceConfigBuilder_.clear(); } return this; } /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; */ public com.google.cloud.datastream.v1alpha1.OracleSourceConfig.Builder getOracleSourceConfigBuilder() { return getOracleSourceConfigFieldBuilder().getBuilder(); } /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; */ @java.lang.Override public com.google.cloud.datastream.v1alpha1.OracleSourceConfigOrBuilder getOracleSourceConfigOrBuilder() { if ((sourceStreamConfigCase_ == 100) && (oracleSourceConfigBuilder_ != null)) { return oracleSourceConfigBuilder_.getMessageOrBuilder(); } else { if (sourceStreamConfigCase_ == 100) { return (com.google.cloud.datastream.v1alpha1.OracleSourceConfig) sourceStreamConfig_; } return com.google.cloud.datastream.v1alpha1.OracleSourceConfig.getDefaultInstance(); } } /** * * *
     * Oracle data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.OracleSourceConfig oracle_source_config = 100; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.datastream.v1alpha1.OracleSourceConfig, com.google.cloud.datastream.v1alpha1.OracleSourceConfig.Builder, com.google.cloud.datastream.v1alpha1.OracleSourceConfigOrBuilder> getOracleSourceConfigFieldBuilder() { if (oracleSourceConfigBuilder_ == null) { if (!(sourceStreamConfigCase_ == 100)) { sourceStreamConfig_ = com.google.cloud.datastream.v1alpha1.OracleSourceConfig.getDefaultInstance(); } oracleSourceConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.datastream.v1alpha1.OracleSourceConfig, com.google.cloud.datastream.v1alpha1.OracleSourceConfig.Builder, com.google.cloud.datastream.v1alpha1.OracleSourceConfigOrBuilder>( (com.google.cloud.datastream.v1alpha1.OracleSourceConfig) sourceStreamConfig_, getParentForChildren(), isClean()); sourceStreamConfig_ = null; } sourceStreamConfigCase_ = 100; onChanged(); return oracleSourceConfigBuilder_; } private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.datastream.v1alpha1.MysqlSourceConfig, com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.Builder, com.google.cloud.datastream.v1alpha1.MysqlSourceConfigOrBuilder> mysqlSourceConfigBuilder_; /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; * * @return Whether the mysqlSourceConfig field is set. */ @java.lang.Override public boolean hasMysqlSourceConfig() { return sourceStreamConfigCase_ == 101; } /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; * * @return The mysqlSourceConfig. */ @java.lang.Override public com.google.cloud.datastream.v1alpha1.MysqlSourceConfig getMysqlSourceConfig() { if (mysqlSourceConfigBuilder_ == null) { if (sourceStreamConfigCase_ == 101) { return (com.google.cloud.datastream.v1alpha1.MysqlSourceConfig) sourceStreamConfig_; } return com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.getDefaultInstance(); } else { if (sourceStreamConfigCase_ == 101) { return mysqlSourceConfigBuilder_.getMessage(); } return com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.getDefaultInstance(); } } /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; */ public Builder setMysqlSourceConfig( com.google.cloud.datastream.v1alpha1.MysqlSourceConfig value) { if (mysqlSourceConfigBuilder_ == null) { if (value == null) { throw new NullPointerException(); } sourceStreamConfig_ = value; onChanged(); } else { mysqlSourceConfigBuilder_.setMessage(value); } sourceStreamConfigCase_ = 101; return this; } /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; */ public Builder setMysqlSourceConfig( com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.Builder builderForValue) { if (mysqlSourceConfigBuilder_ == null) { sourceStreamConfig_ = builderForValue.build(); onChanged(); } else { mysqlSourceConfigBuilder_.setMessage(builderForValue.build()); } sourceStreamConfigCase_ = 101; return this; } /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; */ public Builder mergeMysqlSourceConfig( com.google.cloud.datastream.v1alpha1.MysqlSourceConfig value) { if (mysqlSourceConfigBuilder_ == null) { if (sourceStreamConfigCase_ == 101 && sourceStreamConfig_ != com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.getDefaultInstance()) { sourceStreamConfig_ = com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.newBuilder( (com.google.cloud.datastream.v1alpha1.MysqlSourceConfig) sourceStreamConfig_) .mergeFrom(value) .buildPartial(); } else { sourceStreamConfig_ = value; } onChanged(); } else { if (sourceStreamConfigCase_ == 101) { mysqlSourceConfigBuilder_.mergeFrom(value); } else { mysqlSourceConfigBuilder_.setMessage(value); } } sourceStreamConfigCase_ = 101; return this; } /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; */ public Builder clearMysqlSourceConfig() { if (mysqlSourceConfigBuilder_ == null) { if (sourceStreamConfigCase_ == 101) { sourceStreamConfigCase_ = 0; sourceStreamConfig_ = null; onChanged(); } } else { if (sourceStreamConfigCase_ == 101) { sourceStreamConfigCase_ = 0; sourceStreamConfig_ = null; } mysqlSourceConfigBuilder_.clear(); } return this; } /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; */ public com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.Builder getMysqlSourceConfigBuilder() { return getMysqlSourceConfigFieldBuilder().getBuilder(); } /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; */ @java.lang.Override public com.google.cloud.datastream.v1alpha1.MysqlSourceConfigOrBuilder getMysqlSourceConfigOrBuilder() { if ((sourceStreamConfigCase_ == 101) && (mysqlSourceConfigBuilder_ != null)) { return mysqlSourceConfigBuilder_.getMessageOrBuilder(); } else { if (sourceStreamConfigCase_ == 101) { return (com.google.cloud.datastream.v1alpha1.MysqlSourceConfig) sourceStreamConfig_; } return com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.getDefaultInstance(); } } /** * * *
     * MySQL data source configuration
     * 
* * .google.cloud.datastream.v1alpha1.MysqlSourceConfig mysql_source_config = 101; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.datastream.v1alpha1.MysqlSourceConfig, com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.Builder, com.google.cloud.datastream.v1alpha1.MysqlSourceConfigOrBuilder> getMysqlSourceConfigFieldBuilder() { if (mysqlSourceConfigBuilder_ == null) { if (!(sourceStreamConfigCase_ == 101)) { sourceStreamConfig_ = com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.getDefaultInstance(); } mysqlSourceConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.datastream.v1alpha1.MysqlSourceConfig, com.google.cloud.datastream.v1alpha1.MysqlSourceConfig.Builder, com.google.cloud.datastream.v1alpha1.MysqlSourceConfigOrBuilder>( (com.google.cloud.datastream.v1alpha1.MysqlSourceConfig) sourceStreamConfig_, getParentForChildren(), isClean()); sourceStreamConfig_ = null; } sourceStreamConfigCase_ = 101; onChanged(); return mysqlSourceConfigBuilder_; } @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:google.cloud.datastream.v1alpha1.SourceConfig) } // @@protoc_insertion_point(class_scope:google.cloud.datastream.v1alpha1.SourceConfig) private static final com.google.cloud.datastream.v1alpha1.SourceConfig DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.datastream.v1alpha1.SourceConfig(); } public static com.google.cloud.datastream.v1alpha1.SourceConfig getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public SourceConfig 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 com.google.cloud.datastream.v1alpha1.SourceConfig getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy