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