1 /* 2 * Copyright 2020 Google LLC 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * https://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 // Generated by the protocol buffer compiler. DO NOT EDIT! 17 // source: google/cloud/clouddms/v1/clouddms.proto 18 19 package com.google.cloud.clouddms.v1; 20 21 /** 22 * 23 * 24 * <pre> 25 * Request message to create a new Database Migration Service migration job 26 * in the specified project and region. 27 * </pre> 28 * 29 * Protobuf type {@code google.cloud.clouddms.v1.CreateMigrationJobRequest} 30 */ 31 public final class CreateMigrationJobRequest extends com.google.protobuf.GeneratedMessageV3 32 implements 33 // @@protoc_insertion_point(message_implements:google.cloud.clouddms.v1.CreateMigrationJobRequest) 34 CreateMigrationJobRequestOrBuilder { 35 private static final long serialVersionUID = 0L; 36 // Use CreateMigrationJobRequest.newBuilder() to construct. CreateMigrationJobRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)37 private CreateMigrationJobRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { 38 super(builder); 39 } 40 CreateMigrationJobRequest()41 private CreateMigrationJobRequest() { 42 parent_ = ""; 43 migrationJobId_ = ""; 44 requestId_ = ""; 45 } 46 47 @java.lang.Override 48 @SuppressWarnings({"unused"}) newInstance(UnusedPrivateParameter unused)49 protected java.lang.Object newInstance(UnusedPrivateParameter unused) { 50 return new CreateMigrationJobRequest(); 51 } 52 53 @java.lang.Override getUnknownFields()54 public final com.google.protobuf.UnknownFieldSet getUnknownFields() { 55 return this.unknownFields; 56 } 57 getDescriptor()58 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 59 return com.google.cloud.clouddms.v1.ClouddmsProto 60 .internal_static_google_cloud_clouddms_v1_CreateMigrationJobRequest_descriptor; 61 } 62 63 @java.lang.Override 64 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()65 internalGetFieldAccessorTable() { 66 return com.google.cloud.clouddms.v1.ClouddmsProto 67 .internal_static_google_cloud_clouddms_v1_CreateMigrationJobRequest_fieldAccessorTable 68 .ensureFieldAccessorsInitialized( 69 com.google.cloud.clouddms.v1.CreateMigrationJobRequest.class, 70 com.google.cloud.clouddms.v1.CreateMigrationJobRequest.Builder.class); 71 } 72 73 public static final int PARENT_FIELD_NUMBER = 1; 74 75 @SuppressWarnings("serial") 76 private volatile java.lang.Object parent_ = ""; 77 /** 78 * 79 * 80 * <pre> 81 * Required. The parent, which owns this collection of migration jobs. 82 * </pre> 83 * 84 * <code> 85 * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } 86 * </code> 87 * 88 * @return The parent. 89 */ 90 @java.lang.Override getParent()91 public java.lang.String getParent() { 92 java.lang.Object ref = parent_; 93 if (ref instanceof java.lang.String) { 94 return (java.lang.String) ref; 95 } else { 96 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 97 java.lang.String s = bs.toStringUtf8(); 98 parent_ = s; 99 return s; 100 } 101 } 102 /** 103 * 104 * 105 * <pre> 106 * Required. The parent, which owns this collection of migration jobs. 107 * </pre> 108 * 109 * <code> 110 * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } 111 * </code> 112 * 113 * @return The bytes for parent. 114 */ 115 @java.lang.Override getParentBytes()116 public com.google.protobuf.ByteString getParentBytes() { 117 java.lang.Object ref = parent_; 118 if (ref instanceof java.lang.String) { 119 com.google.protobuf.ByteString b = 120 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 121 parent_ = b; 122 return b; 123 } else { 124 return (com.google.protobuf.ByteString) ref; 125 } 126 } 127 128 public static final int MIGRATION_JOB_ID_FIELD_NUMBER = 2; 129 130 @SuppressWarnings("serial") 131 private volatile java.lang.Object migrationJobId_ = ""; 132 /** 133 * 134 * 135 * <pre> 136 * Required. The ID of the instance to create. 137 * </pre> 138 * 139 * <code>string migration_job_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 140 * 141 * @return The migrationJobId. 142 */ 143 @java.lang.Override getMigrationJobId()144 public java.lang.String getMigrationJobId() { 145 java.lang.Object ref = migrationJobId_; 146 if (ref instanceof java.lang.String) { 147 return (java.lang.String) ref; 148 } else { 149 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 150 java.lang.String s = bs.toStringUtf8(); 151 migrationJobId_ = s; 152 return s; 153 } 154 } 155 /** 156 * 157 * 158 * <pre> 159 * Required. The ID of the instance to create. 160 * </pre> 161 * 162 * <code>string migration_job_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 163 * 164 * @return The bytes for migrationJobId. 165 */ 166 @java.lang.Override getMigrationJobIdBytes()167 public com.google.protobuf.ByteString getMigrationJobIdBytes() { 168 java.lang.Object ref = migrationJobId_; 169 if (ref instanceof java.lang.String) { 170 com.google.protobuf.ByteString b = 171 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 172 migrationJobId_ = b; 173 return b; 174 } else { 175 return (com.google.protobuf.ByteString) ref; 176 } 177 } 178 179 public static final int MIGRATION_JOB_FIELD_NUMBER = 3; 180 private com.google.cloud.clouddms.v1.MigrationJob migrationJob_; 181 /** 182 * 183 * 184 * <pre> 185 * Required. Represents a [migration 186 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 187 * object. 188 * </pre> 189 * 190 * <code> 191 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 192 * </code> 193 * 194 * @return Whether the migrationJob field is set. 195 */ 196 @java.lang.Override hasMigrationJob()197 public boolean hasMigrationJob() { 198 return migrationJob_ != null; 199 } 200 /** 201 * 202 * 203 * <pre> 204 * Required. Represents a [migration 205 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 206 * object. 207 * </pre> 208 * 209 * <code> 210 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 211 * </code> 212 * 213 * @return The migrationJob. 214 */ 215 @java.lang.Override getMigrationJob()216 public com.google.cloud.clouddms.v1.MigrationJob getMigrationJob() { 217 return migrationJob_ == null 218 ? com.google.cloud.clouddms.v1.MigrationJob.getDefaultInstance() 219 : migrationJob_; 220 } 221 /** 222 * 223 * 224 * <pre> 225 * Required. Represents a [migration 226 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 227 * object. 228 * </pre> 229 * 230 * <code> 231 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 232 * </code> 233 */ 234 @java.lang.Override getMigrationJobOrBuilder()235 public com.google.cloud.clouddms.v1.MigrationJobOrBuilder getMigrationJobOrBuilder() { 236 return migrationJob_ == null 237 ? com.google.cloud.clouddms.v1.MigrationJob.getDefaultInstance() 238 : migrationJob_; 239 } 240 241 public static final int REQUEST_ID_FIELD_NUMBER = 4; 242 243 @SuppressWarnings("serial") 244 private volatile java.lang.Object requestId_ = ""; 245 /** 246 * 247 * 248 * <pre> 249 * A unique id used to identify the request. If the server receives two 250 * requests with the same id, then the second request will be ignored. 251 * It is recommended to always set this value to a UUID. 252 * The id must contain only letters (a-z, A-Z), numbers (0-9), underscores 253 * (_), and hyphens (-). The maximum length is 40 characters. 254 * </pre> 255 * 256 * <code>string request_id = 4;</code> 257 * 258 * @return The requestId. 259 */ 260 @java.lang.Override getRequestId()261 public java.lang.String getRequestId() { 262 java.lang.Object ref = requestId_; 263 if (ref instanceof java.lang.String) { 264 return (java.lang.String) ref; 265 } else { 266 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 267 java.lang.String s = bs.toStringUtf8(); 268 requestId_ = s; 269 return s; 270 } 271 } 272 /** 273 * 274 * 275 * <pre> 276 * A unique id used to identify the request. If the server receives two 277 * requests with the same id, then the second request will be ignored. 278 * It is recommended to always set this value to a UUID. 279 * The id must contain only letters (a-z, A-Z), numbers (0-9), underscores 280 * (_), and hyphens (-). The maximum length is 40 characters. 281 * </pre> 282 * 283 * <code>string request_id = 4;</code> 284 * 285 * @return The bytes for requestId. 286 */ 287 @java.lang.Override getRequestIdBytes()288 public com.google.protobuf.ByteString getRequestIdBytes() { 289 java.lang.Object ref = requestId_; 290 if (ref instanceof java.lang.String) { 291 com.google.protobuf.ByteString b = 292 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 293 requestId_ = b; 294 return b; 295 } else { 296 return (com.google.protobuf.ByteString) ref; 297 } 298 } 299 300 private byte memoizedIsInitialized = -1; 301 302 @java.lang.Override isInitialized()303 public final boolean isInitialized() { 304 byte isInitialized = memoizedIsInitialized; 305 if (isInitialized == 1) return true; 306 if (isInitialized == 0) return false; 307 308 memoizedIsInitialized = 1; 309 return true; 310 } 311 312 @java.lang.Override writeTo(com.google.protobuf.CodedOutputStream output)313 public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { 314 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { 315 com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); 316 } 317 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(migrationJobId_)) { 318 com.google.protobuf.GeneratedMessageV3.writeString(output, 2, migrationJobId_); 319 } 320 if (migrationJob_ != null) { 321 output.writeMessage(3, getMigrationJob()); 322 } 323 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(requestId_)) { 324 com.google.protobuf.GeneratedMessageV3.writeString(output, 4, requestId_); 325 } 326 getUnknownFields().writeTo(output); 327 } 328 329 @java.lang.Override getSerializedSize()330 public int getSerializedSize() { 331 int size = memoizedSize; 332 if (size != -1) return size; 333 334 size = 0; 335 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { 336 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); 337 } 338 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(migrationJobId_)) { 339 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, migrationJobId_); 340 } 341 if (migrationJob_ != null) { 342 size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getMigrationJob()); 343 } 344 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(requestId_)) { 345 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, requestId_); 346 } 347 size += getUnknownFields().getSerializedSize(); 348 memoizedSize = size; 349 return size; 350 } 351 352 @java.lang.Override equals(final java.lang.Object obj)353 public boolean equals(final java.lang.Object obj) { 354 if (obj == this) { 355 return true; 356 } 357 if (!(obj instanceof com.google.cloud.clouddms.v1.CreateMigrationJobRequest)) { 358 return super.equals(obj); 359 } 360 com.google.cloud.clouddms.v1.CreateMigrationJobRequest other = 361 (com.google.cloud.clouddms.v1.CreateMigrationJobRequest) obj; 362 363 if (!getParent().equals(other.getParent())) return false; 364 if (!getMigrationJobId().equals(other.getMigrationJobId())) return false; 365 if (hasMigrationJob() != other.hasMigrationJob()) return false; 366 if (hasMigrationJob()) { 367 if (!getMigrationJob().equals(other.getMigrationJob())) return false; 368 } 369 if (!getRequestId().equals(other.getRequestId())) return false; 370 if (!getUnknownFields().equals(other.getUnknownFields())) return false; 371 return true; 372 } 373 374 @java.lang.Override hashCode()375 public int hashCode() { 376 if (memoizedHashCode != 0) { 377 return memoizedHashCode; 378 } 379 int hash = 41; 380 hash = (19 * hash) + getDescriptor().hashCode(); 381 hash = (37 * hash) + PARENT_FIELD_NUMBER; 382 hash = (53 * hash) + getParent().hashCode(); 383 hash = (37 * hash) + MIGRATION_JOB_ID_FIELD_NUMBER; 384 hash = (53 * hash) + getMigrationJobId().hashCode(); 385 if (hasMigrationJob()) { 386 hash = (37 * hash) + MIGRATION_JOB_FIELD_NUMBER; 387 hash = (53 * hash) + getMigrationJob().hashCode(); 388 } 389 hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; 390 hash = (53 * hash) + getRequestId().hashCode(); 391 hash = (29 * hash) + getUnknownFields().hashCode(); 392 memoizedHashCode = hash; 393 return hash; 394 } 395 parseFrom( java.nio.ByteBuffer data)396 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 397 java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { 398 return PARSER.parseFrom(data); 399 } 400 parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)401 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 402 java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 403 throws com.google.protobuf.InvalidProtocolBufferException { 404 return PARSER.parseFrom(data, extensionRegistry); 405 } 406 parseFrom( com.google.protobuf.ByteString data)407 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 408 com.google.protobuf.ByteString data) 409 throws com.google.protobuf.InvalidProtocolBufferException { 410 return PARSER.parseFrom(data); 411 } 412 parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)413 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 414 com.google.protobuf.ByteString data, 415 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 416 throws com.google.protobuf.InvalidProtocolBufferException { 417 return PARSER.parseFrom(data, extensionRegistry); 418 } 419 parseFrom(byte[] data)420 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom(byte[] data) 421 throws com.google.protobuf.InvalidProtocolBufferException { 422 return PARSER.parseFrom(data); 423 } 424 parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)425 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 426 byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 427 throws com.google.protobuf.InvalidProtocolBufferException { 428 return PARSER.parseFrom(data, extensionRegistry); 429 } 430 parseFrom( java.io.InputStream input)431 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 432 java.io.InputStream input) throws java.io.IOException { 433 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 434 } 435 parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)436 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 437 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 438 throws java.io.IOException { 439 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 440 PARSER, input, extensionRegistry); 441 } 442 parseDelimitedFrom( java.io.InputStream input)443 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseDelimitedFrom( 444 java.io.InputStream input) throws java.io.IOException { 445 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); 446 } 447 parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)448 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseDelimitedFrom( 449 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 450 throws java.io.IOException { 451 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( 452 PARSER, input, extensionRegistry); 453 } 454 parseFrom( com.google.protobuf.CodedInputStream input)455 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 456 com.google.protobuf.CodedInputStream input) throws java.io.IOException { 457 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 458 } 459 parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)460 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest parseFrom( 461 com.google.protobuf.CodedInputStream input, 462 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 463 throws java.io.IOException { 464 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 465 PARSER, input, extensionRegistry); 466 } 467 468 @java.lang.Override newBuilderForType()469 public Builder newBuilderForType() { 470 return newBuilder(); 471 } 472 newBuilder()473 public static Builder newBuilder() { 474 return DEFAULT_INSTANCE.toBuilder(); 475 } 476 newBuilder( com.google.cloud.clouddms.v1.CreateMigrationJobRequest prototype)477 public static Builder newBuilder( 478 com.google.cloud.clouddms.v1.CreateMigrationJobRequest prototype) { 479 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); 480 } 481 482 @java.lang.Override toBuilder()483 public Builder toBuilder() { 484 return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); 485 } 486 487 @java.lang.Override newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)488 protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 489 Builder builder = new Builder(parent); 490 return builder; 491 } 492 /** 493 * 494 * 495 * <pre> 496 * Request message to create a new Database Migration Service migration job 497 * in the specified project and region. 498 * </pre> 499 * 500 * Protobuf type {@code google.cloud.clouddms.v1.CreateMigrationJobRequest} 501 */ 502 public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> 503 implements 504 // @@protoc_insertion_point(builder_implements:google.cloud.clouddms.v1.CreateMigrationJobRequest) 505 com.google.cloud.clouddms.v1.CreateMigrationJobRequestOrBuilder { getDescriptor()506 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 507 return com.google.cloud.clouddms.v1.ClouddmsProto 508 .internal_static_google_cloud_clouddms_v1_CreateMigrationJobRequest_descriptor; 509 } 510 511 @java.lang.Override 512 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()513 internalGetFieldAccessorTable() { 514 return com.google.cloud.clouddms.v1.ClouddmsProto 515 .internal_static_google_cloud_clouddms_v1_CreateMigrationJobRequest_fieldAccessorTable 516 .ensureFieldAccessorsInitialized( 517 com.google.cloud.clouddms.v1.CreateMigrationJobRequest.class, 518 com.google.cloud.clouddms.v1.CreateMigrationJobRequest.Builder.class); 519 } 520 521 // Construct using com.google.cloud.clouddms.v1.CreateMigrationJobRequest.newBuilder() Builder()522 private Builder() {} 523 Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)524 private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 525 super(parent); 526 } 527 528 @java.lang.Override clear()529 public Builder clear() { 530 super.clear(); 531 bitField0_ = 0; 532 parent_ = ""; 533 migrationJobId_ = ""; 534 migrationJob_ = null; 535 if (migrationJobBuilder_ != null) { 536 migrationJobBuilder_.dispose(); 537 migrationJobBuilder_ = null; 538 } 539 requestId_ = ""; 540 return this; 541 } 542 543 @java.lang.Override getDescriptorForType()544 public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { 545 return com.google.cloud.clouddms.v1.ClouddmsProto 546 .internal_static_google_cloud_clouddms_v1_CreateMigrationJobRequest_descriptor; 547 } 548 549 @java.lang.Override getDefaultInstanceForType()550 public com.google.cloud.clouddms.v1.CreateMigrationJobRequest getDefaultInstanceForType() { 551 return com.google.cloud.clouddms.v1.CreateMigrationJobRequest.getDefaultInstance(); 552 } 553 554 @java.lang.Override build()555 public com.google.cloud.clouddms.v1.CreateMigrationJobRequest build() { 556 com.google.cloud.clouddms.v1.CreateMigrationJobRequest result = buildPartial(); 557 if (!result.isInitialized()) { 558 throw newUninitializedMessageException(result); 559 } 560 return result; 561 } 562 563 @java.lang.Override buildPartial()564 public com.google.cloud.clouddms.v1.CreateMigrationJobRequest buildPartial() { 565 com.google.cloud.clouddms.v1.CreateMigrationJobRequest result = 566 new com.google.cloud.clouddms.v1.CreateMigrationJobRequest(this); 567 if (bitField0_ != 0) { 568 buildPartial0(result); 569 } 570 onBuilt(); 571 return result; 572 } 573 buildPartial0(com.google.cloud.clouddms.v1.CreateMigrationJobRequest result)574 private void buildPartial0(com.google.cloud.clouddms.v1.CreateMigrationJobRequest result) { 575 int from_bitField0_ = bitField0_; 576 if (((from_bitField0_ & 0x00000001) != 0)) { 577 result.parent_ = parent_; 578 } 579 if (((from_bitField0_ & 0x00000002) != 0)) { 580 result.migrationJobId_ = migrationJobId_; 581 } 582 if (((from_bitField0_ & 0x00000004) != 0)) { 583 result.migrationJob_ = 584 migrationJobBuilder_ == null ? migrationJob_ : migrationJobBuilder_.build(); 585 } 586 if (((from_bitField0_ & 0x00000008) != 0)) { 587 result.requestId_ = requestId_; 588 } 589 } 590 591 @java.lang.Override clone()592 public Builder clone() { 593 return super.clone(); 594 } 595 596 @java.lang.Override setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)597 public Builder setField( 598 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 599 return super.setField(field, value); 600 } 601 602 @java.lang.Override clearField(com.google.protobuf.Descriptors.FieldDescriptor field)603 public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { 604 return super.clearField(field); 605 } 606 607 @java.lang.Override clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)608 public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { 609 return super.clearOneof(oneof); 610 } 611 612 @java.lang.Override setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)613 public Builder setRepeatedField( 614 com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { 615 return super.setRepeatedField(field, index, value); 616 } 617 618 @java.lang.Override addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)619 public Builder addRepeatedField( 620 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 621 return super.addRepeatedField(field, value); 622 } 623 624 @java.lang.Override mergeFrom(com.google.protobuf.Message other)625 public Builder mergeFrom(com.google.protobuf.Message other) { 626 if (other instanceof com.google.cloud.clouddms.v1.CreateMigrationJobRequest) { 627 return mergeFrom((com.google.cloud.clouddms.v1.CreateMigrationJobRequest) other); 628 } else { 629 super.mergeFrom(other); 630 return this; 631 } 632 } 633 mergeFrom(com.google.cloud.clouddms.v1.CreateMigrationJobRequest other)634 public Builder mergeFrom(com.google.cloud.clouddms.v1.CreateMigrationJobRequest other) { 635 if (other == com.google.cloud.clouddms.v1.CreateMigrationJobRequest.getDefaultInstance()) 636 return this; 637 if (!other.getParent().isEmpty()) { 638 parent_ = other.parent_; 639 bitField0_ |= 0x00000001; 640 onChanged(); 641 } 642 if (!other.getMigrationJobId().isEmpty()) { 643 migrationJobId_ = other.migrationJobId_; 644 bitField0_ |= 0x00000002; 645 onChanged(); 646 } 647 if (other.hasMigrationJob()) { 648 mergeMigrationJob(other.getMigrationJob()); 649 } 650 if (!other.getRequestId().isEmpty()) { 651 requestId_ = other.requestId_; 652 bitField0_ |= 0x00000008; 653 onChanged(); 654 } 655 this.mergeUnknownFields(other.getUnknownFields()); 656 onChanged(); 657 return this; 658 } 659 660 @java.lang.Override isInitialized()661 public final boolean isInitialized() { 662 return true; 663 } 664 665 @java.lang.Override mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)666 public Builder mergeFrom( 667 com.google.protobuf.CodedInputStream input, 668 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 669 throws java.io.IOException { 670 if (extensionRegistry == null) { 671 throw new java.lang.NullPointerException(); 672 } 673 try { 674 boolean done = false; 675 while (!done) { 676 int tag = input.readTag(); 677 switch (tag) { 678 case 0: 679 done = true; 680 break; 681 case 10: 682 { 683 parent_ = input.readStringRequireUtf8(); 684 bitField0_ |= 0x00000001; 685 break; 686 } // case 10 687 case 18: 688 { 689 migrationJobId_ = input.readStringRequireUtf8(); 690 bitField0_ |= 0x00000002; 691 break; 692 } // case 18 693 case 26: 694 { 695 input.readMessage(getMigrationJobFieldBuilder().getBuilder(), extensionRegistry); 696 bitField0_ |= 0x00000004; 697 break; 698 } // case 26 699 case 34: 700 { 701 requestId_ = input.readStringRequireUtf8(); 702 bitField0_ |= 0x00000008; 703 break; 704 } // case 34 705 default: 706 { 707 if (!super.parseUnknownField(input, extensionRegistry, tag)) { 708 done = true; // was an endgroup tag 709 } 710 break; 711 } // default: 712 } // switch (tag) 713 } // while (!done) 714 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 715 throw e.unwrapIOException(); 716 } finally { 717 onChanged(); 718 } // finally 719 return this; 720 } 721 722 private int bitField0_; 723 724 private java.lang.Object parent_ = ""; 725 /** 726 * 727 * 728 * <pre> 729 * Required. The parent, which owns this collection of migration jobs. 730 * </pre> 731 * 732 * <code> 733 * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } 734 * </code> 735 * 736 * @return The parent. 737 */ getParent()738 public java.lang.String getParent() { 739 java.lang.Object ref = parent_; 740 if (!(ref instanceof java.lang.String)) { 741 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 742 java.lang.String s = bs.toStringUtf8(); 743 parent_ = s; 744 return s; 745 } else { 746 return (java.lang.String) ref; 747 } 748 } 749 /** 750 * 751 * 752 * <pre> 753 * Required. The parent, which owns this collection of migration jobs. 754 * </pre> 755 * 756 * <code> 757 * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } 758 * </code> 759 * 760 * @return The bytes for parent. 761 */ getParentBytes()762 public com.google.protobuf.ByteString getParentBytes() { 763 java.lang.Object ref = parent_; 764 if (ref instanceof String) { 765 com.google.protobuf.ByteString b = 766 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 767 parent_ = b; 768 return b; 769 } else { 770 return (com.google.protobuf.ByteString) ref; 771 } 772 } 773 /** 774 * 775 * 776 * <pre> 777 * Required. The parent, which owns this collection of migration jobs. 778 * </pre> 779 * 780 * <code> 781 * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } 782 * </code> 783 * 784 * @param value The parent to set. 785 * @return This builder for chaining. 786 */ setParent(java.lang.String value)787 public Builder setParent(java.lang.String value) { 788 if (value == null) { 789 throw new NullPointerException(); 790 } 791 parent_ = value; 792 bitField0_ |= 0x00000001; 793 onChanged(); 794 return this; 795 } 796 /** 797 * 798 * 799 * <pre> 800 * Required. The parent, which owns this collection of migration jobs. 801 * </pre> 802 * 803 * <code> 804 * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } 805 * </code> 806 * 807 * @return This builder for chaining. 808 */ clearParent()809 public Builder clearParent() { 810 parent_ = getDefaultInstance().getParent(); 811 bitField0_ = (bitField0_ & ~0x00000001); 812 onChanged(); 813 return this; 814 } 815 /** 816 * 817 * 818 * <pre> 819 * Required. The parent, which owns this collection of migration jobs. 820 * </pre> 821 * 822 * <code> 823 * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } 824 * </code> 825 * 826 * @param value The bytes for parent to set. 827 * @return This builder for chaining. 828 */ setParentBytes(com.google.protobuf.ByteString value)829 public Builder setParentBytes(com.google.protobuf.ByteString value) { 830 if (value == null) { 831 throw new NullPointerException(); 832 } 833 checkByteStringIsUtf8(value); 834 parent_ = value; 835 bitField0_ |= 0x00000001; 836 onChanged(); 837 return this; 838 } 839 840 private java.lang.Object migrationJobId_ = ""; 841 /** 842 * 843 * 844 * <pre> 845 * Required. The ID of the instance to create. 846 * </pre> 847 * 848 * <code>string migration_job_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 849 * 850 * @return The migrationJobId. 851 */ getMigrationJobId()852 public java.lang.String getMigrationJobId() { 853 java.lang.Object ref = migrationJobId_; 854 if (!(ref instanceof java.lang.String)) { 855 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 856 java.lang.String s = bs.toStringUtf8(); 857 migrationJobId_ = s; 858 return s; 859 } else { 860 return (java.lang.String) ref; 861 } 862 } 863 /** 864 * 865 * 866 * <pre> 867 * Required. The ID of the instance to create. 868 * </pre> 869 * 870 * <code>string migration_job_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 871 * 872 * @return The bytes for migrationJobId. 873 */ getMigrationJobIdBytes()874 public com.google.protobuf.ByteString getMigrationJobIdBytes() { 875 java.lang.Object ref = migrationJobId_; 876 if (ref instanceof String) { 877 com.google.protobuf.ByteString b = 878 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 879 migrationJobId_ = b; 880 return b; 881 } else { 882 return (com.google.protobuf.ByteString) ref; 883 } 884 } 885 /** 886 * 887 * 888 * <pre> 889 * Required. The ID of the instance to create. 890 * </pre> 891 * 892 * <code>string migration_job_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 893 * 894 * @param value The migrationJobId to set. 895 * @return This builder for chaining. 896 */ setMigrationJobId(java.lang.String value)897 public Builder setMigrationJobId(java.lang.String value) { 898 if (value == null) { 899 throw new NullPointerException(); 900 } 901 migrationJobId_ = value; 902 bitField0_ |= 0x00000002; 903 onChanged(); 904 return this; 905 } 906 /** 907 * 908 * 909 * <pre> 910 * Required. The ID of the instance to create. 911 * </pre> 912 * 913 * <code>string migration_job_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 914 * 915 * @return This builder for chaining. 916 */ clearMigrationJobId()917 public Builder clearMigrationJobId() { 918 migrationJobId_ = getDefaultInstance().getMigrationJobId(); 919 bitField0_ = (bitField0_ & ~0x00000002); 920 onChanged(); 921 return this; 922 } 923 /** 924 * 925 * 926 * <pre> 927 * Required. The ID of the instance to create. 928 * </pre> 929 * 930 * <code>string migration_job_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 931 * 932 * @param value The bytes for migrationJobId to set. 933 * @return This builder for chaining. 934 */ setMigrationJobIdBytes(com.google.protobuf.ByteString value)935 public Builder setMigrationJobIdBytes(com.google.protobuf.ByteString value) { 936 if (value == null) { 937 throw new NullPointerException(); 938 } 939 checkByteStringIsUtf8(value); 940 migrationJobId_ = value; 941 bitField0_ |= 0x00000002; 942 onChanged(); 943 return this; 944 } 945 946 private com.google.cloud.clouddms.v1.MigrationJob migrationJob_; 947 private com.google.protobuf.SingleFieldBuilderV3< 948 com.google.cloud.clouddms.v1.MigrationJob, 949 com.google.cloud.clouddms.v1.MigrationJob.Builder, 950 com.google.cloud.clouddms.v1.MigrationJobOrBuilder> 951 migrationJobBuilder_; 952 /** 953 * 954 * 955 * <pre> 956 * Required. Represents a [migration 957 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 958 * object. 959 * </pre> 960 * 961 * <code> 962 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 963 * </code> 964 * 965 * @return Whether the migrationJob field is set. 966 */ hasMigrationJob()967 public boolean hasMigrationJob() { 968 return ((bitField0_ & 0x00000004) != 0); 969 } 970 /** 971 * 972 * 973 * <pre> 974 * Required. Represents a [migration 975 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 976 * object. 977 * </pre> 978 * 979 * <code> 980 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 981 * </code> 982 * 983 * @return The migrationJob. 984 */ getMigrationJob()985 public com.google.cloud.clouddms.v1.MigrationJob getMigrationJob() { 986 if (migrationJobBuilder_ == null) { 987 return migrationJob_ == null 988 ? com.google.cloud.clouddms.v1.MigrationJob.getDefaultInstance() 989 : migrationJob_; 990 } else { 991 return migrationJobBuilder_.getMessage(); 992 } 993 } 994 /** 995 * 996 * 997 * <pre> 998 * Required. Represents a [migration 999 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 1000 * object. 1001 * </pre> 1002 * 1003 * <code> 1004 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 1005 * </code> 1006 */ setMigrationJob(com.google.cloud.clouddms.v1.MigrationJob value)1007 public Builder setMigrationJob(com.google.cloud.clouddms.v1.MigrationJob value) { 1008 if (migrationJobBuilder_ == null) { 1009 if (value == null) { 1010 throw new NullPointerException(); 1011 } 1012 migrationJob_ = value; 1013 } else { 1014 migrationJobBuilder_.setMessage(value); 1015 } 1016 bitField0_ |= 0x00000004; 1017 onChanged(); 1018 return this; 1019 } 1020 /** 1021 * 1022 * 1023 * <pre> 1024 * Required. Represents a [migration 1025 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 1026 * object. 1027 * </pre> 1028 * 1029 * <code> 1030 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 1031 * </code> 1032 */ setMigrationJob( com.google.cloud.clouddms.v1.MigrationJob.Builder builderForValue)1033 public Builder setMigrationJob( 1034 com.google.cloud.clouddms.v1.MigrationJob.Builder builderForValue) { 1035 if (migrationJobBuilder_ == null) { 1036 migrationJob_ = builderForValue.build(); 1037 } else { 1038 migrationJobBuilder_.setMessage(builderForValue.build()); 1039 } 1040 bitField0_ |= 0x00000004; 1041 onChanged(); 1042 return this; 1043 } 1044 /** 1045 * 1046 * 1047 * <pre> 1048 * Required. Represents a [migration 1049 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 1050 * object. 1051 * </pre> 1052 * 1053 * <code> 1054 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 1055 * </code> 1056 */ mergeMigrationJob(com.google.cloud.clouddms.v1.MigrationJob value)1057 public Builder mergeMigrationJob(com.google.cloud.clouddms.v1.MigrationJob value) { 1058 if (migrationJobBuilder_ == null) { 1059 if (((bitField0_ & 0x00000004) != 0) 1060 && migrationJob_ != null 1061 && migrationJob_ != com.google.cloud.clouddms.v1.MigrationJob.getDefaultInstance()) { 1062 getMigrationJobBuilder().mergeFrom(value); 1063 } else { 1064 migrationJob_ = value; 1065 } 1066 } else { 1067 migrationJobBuilder_.mergeFrom(value); 1068 } 1069 bitField0_ |= 0x00000004; 1070 onChanged(); 1071 return this; 1072 } 1073 /** 1074 * 1075 * 1076 * <pre> 1077 * Required. Represents a [migration 1078 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 1079 * object. 1080 * </pre> 1081 * 1082 * <code> 1083 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 1084 * </code> 1085 */ clearMigrationJob()1086 public Builder clearMigrationJob() { 1087 bitField0_ = (bitField0_ & ~0x00000004); 1088 migrationJob_ = null; 1089 if (migrationJobBuilder_ != null) { 1090 migrationJobBuilder_.dispose(); 1091 migrationJobBuilder_ = null; 1092 } 1093 onChanged(); 1094 return this; 1095 } 1096 /** 1097 * 1098 * 1099 * <pre> 1100 * Required. Represents a [migration 1101 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 1102 * object. 1103 * </pre> 1104 * 1105 * <code> 1106 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 1107 * </code> 1108 */ getMigrationJobBuilder()1109 public com.google.cloud.clouddms.v1.MigrationJob.Builder getMigrationJobBuilder() { 1110 bitField0_ |= 0x00000004; 1111 onChanged(); 1112 return getMigrationJobFieldBuilder().getBuilder(); 1113 } 1114 /** 1115 * 1116 * 1117 * <pre> 1118 * Required. Represents a [migration 1119 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 1120 * object. 1121 * </pre> 1122 * 1123 * <code> 1124 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 1125 * </code> 1126 */ getMigrationJobOrBuilder()1127 public com.google.cloud.clouddms.v1.MigrationJobOrBuilder getMigrationJobOrBuilder() { 1128 if (migrationJobBuilder_ != null) { 1129 return migrationJobBuilder_.getMessageOrBuilder(); 1130 } else { 1131 return migrationJob_ == null 1132 ? com.google.cloud.clouddms.v1.MigrationJob.getDefaultInstance() 1133 : migrationJob_; 1134 } 1135 } 1136 /** 1137 * 1138 * 1139 * <pre> 1140 * Required. Represents a [migration 1141 * job](https://cloud.google.com/database-migration/docs/reference/rest/v1/projects.locations.migrationJobs) 1142 * object. 1143 * </pre> 1144 * 1145 * <code> 1146 * .google.cloud.clouddms.v1.MigrationJob migration_job = 3 [(.google.api.field_behavior) = REQUIRED]; 1147 * </code> 1148 */ 1149 private com.google.protobuf.SingleFieldBuilderV3< 1150 com.google.cloud.clouddms.v1.MigrationJob, 1151 com.google.cloud.clouddms.v1.MigrationJob.Builder, 1152 com.google.cloud.clouddms.v1.MigrationJobOrBuilder> getMigrationJobFieldBuilder()1153 getMigrationJobFieldBuilder() { 1154 if (migrationJobBuilder_ == null) { 1155 migrationJobBuilder_ = 1156 new com.google.protobuf.SingleFieldBuilderV3< 1157 com.google.cloud.clouddms.v1.MigrationJob, 1158 com.google.cloud.clouddms.v1.MigrationJob.Builder, 1159 com.google.cloud.clouddms.v1.MigrationJobOrBuilder>( 1160 getMigrationJob(), getParentForChildren(), isClean()); 1161 migrationJob_ = null; 1162 } 1163 return migrationJobBuilder_; 1164 } 1165 1166 private java.lang.Object requestId_ = ""; 1167 /** 1168 * 1169 * 1170 * <pre> 1171 * A unique id used to identify the request. If the server receives two 1172 * requests with the same id, then the second request will be ignored. 1173 * It is recommended to always set this value to a UUID. 1174 * The id must contain only letters (a-z, A-Z), numbers (0-9), underscores 1175 * (_), and hyphens (-). The maximum length is 40 characters. 1176 * </pre> 1177 * 1178 * <code>string request_id = 4;</code> 1179 * 1180 * @return The requestId. 1181 */ getRequestId()1182 public java.lang.String getRequestId() { 1183 java.lang.Object ref = requestId_; 1184 if (!(ref instanceof java.lang.String)) { 1185 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1186 java.lang.String s = bs.toStringUtf8(); 1187 requestId_ = s; 1188 return s; 1189 } else { 1190 return (java.lang.String) ref; 1191 } 1192 } 1193 /** 1194 * 1195 * 1196 * <pre> 1197 * A unique id used to identify the request. If the server receives two 1198 * requests with the same id, then the second request will be ignored. 1199 * It is recommended to always set this value to a UUID. 1200 * The id must contain only letters (a-z, A-Z), numbers (0-9), underscores 1201 * (_), and hyphens (-). The maximum length is 40 characters. 1202 * </pre> 1203 * 1204 * <code>string request_id = 4;</code> 1205 * 1206 * @return The bytes for requestId. 1207 */ getRequestIdBytes()1208 public com.google.protobuf.ByteString getRequestIdBytes() { 1209 java.lang.Object ref = requestId_; 1210 if (ref instanceof String) { 1211 com.google.protobuf.ByteString b = 1212 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1213 requestId_ = b; 1214 return b; 1215 } else { 1216 return (com.google.protobuf.ByteString) ref; 1217 } 1218 } 1219 /** 1220 * 1221 * 1222 * <pre> 1223 * A unique id used to identify the request. If the server receives two 1224 * requests with the same id, then the second request will be ignored. 1225 * It is recommended to always set this value to a UUID. 1226 * The id must contain only letters (a-z, A-Z), numbers (0-9), underscores 1227 * (_), and hyphens (-). The maximum length is 40 characters. 1228 * </pre> 1229 * 1230 * <code>string request_id = 4;</code> 1231 * 1232 * @param value The requestId to set. 1233 * @return This builder for chaining. 1234 */ setRequestId(java.lang.String value)1235 public Builder setRequestId(java.lang.String value) { 1236 if (value == null) { 1237 throw new NullPointerException(); 1238 } 1239 requestId_ = value; 1240 bitField0_ |= 0x00000008; 1241 onChanged(); 1242 return this; 1243 } 1244 /** 1245 * 1246 * 1247 * <pre> 1248 * A unique id used to identify the request. If the server receives two 1249 * requests with the same id, then the second request will be ignored. 1250 * It is recommended to always set this value to a UUID. 1251 * The id must contain only letters (a-z, A-Z), numbers (0-9), underscores 1252 * (_), and hyphens (-). The maximum length is 40 characters. 1253 * </pre> 1254 * 1255 * <code>string request_id = 4;</code> 1256 * 1257 * @return This builder for chaining. 1258 */ clearRequestId()1259 public Builder clearRequestId() { 1260 requestId_ = getDefaultInstance().getRequestId(); 1261 bitField0_ = (bitField0_ & ~0x00000008); 1262 onChanged(); 1263 return this; 1264 } 1265 /** 1266 * 1267 * 1268 * <pre> 1269 * A unique id used to identify the request. If the server receives two 1270 * requests with the same id, then the second request will be ignored. 1271 * It is recommended to always set this value to a UUID. 1272 * The id must contain only letters (a-z, A-Z), numbers (0-9), underscores 1273 * (_), and hyphens (-). The maximum length is 40 characters. 1274 * </pre> 1275 * 1276 * <code>string request_id = 4;</code> 1277 * 1278 * @param value The bytes for requestId to set. 1279 * @return This builder for chaining. 1280 */ setRequestIdBytes(com.google.protobuf.ByteString value)1281 public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { 1282 if (value == null) { 1283 throw new NullPointerException(); 1284 } 1285 checkByteStringIsUtf8(value); 1286 requestId_ = value; 1287 bitField0_ |= 0x00000008; 1288 onChanged(); 1289 return this; 1290 } 1291 1292 @java.lang.Override setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)1293 public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { 1294 return super.setUnknownFields(unknownFields); 1295 } 1296 1297 @java.lang.Override mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)1298 public final Builder mergeUnknownFields( 1299 final com.google.protobuf.UnknownFieldSet unknownFields) { 1300 return super.mergeUnknownFields(unknownFields); 1301 } 1302 1303 // @@protoc_insertion_point(builder_scope:google.cloud.clouddms.v1.CreateMigrationJobRequest) 1304 } 1305 1306 // @@protoc_insertion_point(class_scope:google.cloud.clouddms.v1.CreateMigrationJobRequest) 1307 private static final com.google.cloud.clouddms.v1.CreateMigrationJobRequest DEFAULT_INSTANCE; 1308 1309 static { 1310 DEFAULT_INSTANCE = new com.google.cloud.clouddms.v1.CreateMigrationJobRequest(); 1311 } 1312 getDefaultInstance()1313 public static com.google.cloud.clouddms.v1.CreateMigrationJobRequest getDefaultInstance() { 1314 return DEFAULT_INSTANCE; 1315 } 1316 1317 private static final com.google.protobuf.Parser<CreateMigrationJobRequest> PARSER = 1318 new com.google.protobuf.AbstractParser<CreateMigrationJobRequest>() { 1319 @java.lang.Override 1320 public CreateMigrationJobRequest parsePartialFrom( 1321 com.google.protobuf.CodedInputStream input, 1322 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1323 throws com.google.protobuf.InvalidProtocolBufferException { 1324 Builder builder = newBuilder(); 1325 try { 1326 builder.mergeFrom(input, extensionRegistry); 1327 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 1328 throw e.setUnfinishedMessage(builder.buildPartial()); 1329 } catch (com.google.protobuf.UninitializedMessageException e) { 1330 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); 1331 } catch (java.io.IOException e) { 1332 throw new com.google.protobuf.InvalidProtocolBufferException(e) 1333 .setUnfinishedMessage(builder.buildPartial()); 1334 } 1335 return builder.buildPartial(); 1336 } 1337 }; 1338 parser()1339 public static com.google.protobuf.Parser<CreateMigrationJobRequest> parser() { 1340 return PARSER; 1341 } 1342 1343 @java.lang.Override getParserForType()1344 public com.google.protobuf.Parser<CreateMigrationJobRequest> getParserForType() { 1345 return PARSER; 1346 } 1347 1348 @java.lang.Override getDefaultInstanceForType()1349 public com.google.cloud.clouddms.v1.CreateMigrationJobRequest getDefaultInstanceForType() { 1350 return DEFAULT_INSTANCE; 1351 } 1352 } 1353