• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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  * Represents a Persistent Disk resource. Google Compute Engine has two Disk resources: * [Zonal](/compute/docs/reference/rest/v1/disks) * [Regional](/compute/docs/reference/rest/v1/regionDisks) Persistent disks are required for running your VM instances. Create both boot and non-boot (data) persistent disks. For more information, read Persistent Disks. For more storage options, read Storage options. The disks resource represents a zonal persistent disk. For more information, read Zonal persistent disks. The regionDisks resource represents a regional persistent disk. For more information, read Regional resources.
26  * </pre>
27  *
28  * Protobuf type {@code google.cloud.compute.v1.Disk}
29  */
30 public final class Disk extends com.google.protobuf.GeneratedMessageV3
31     implements
32     // @@protoc_insertion_point(message_implements:google.cloud.compute.v1.Disk)
33     DiskOrBuilder {
34   private static final long serialVersionUID = 0L;
35   // Use Disk.newBuilder() to construct.
Disk(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)36   private Disk(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
37     super(builder);
38   }
39 
Disk()40   private Disk() {
41     architecture_ = "";
42     creationTimestamp_ = "";
43     description_ = "";
44     guestOsFeatures_ = java.util.Collections.emptyList();
45     kind_ = "";
46     labelFingerprint_ = "";
47     lastAttachTimestamp_ = "";
48     lastDetachTimestamp_ = "";
49     licenseCodes_ = emptyLongList();
50     licenses_ = com.google.protobuf.LazyStringArrayList.EMPTY;
51     locationHint_ = "";
52     name_ = "";
53     options_ = "";
54     region_ = "";
55     replicaZones_ = com.google.protobuf.LazyStringArrayList.EMPTY;
56     resourcePolicies_ = com.google.protobuf.LazyStringArrayList.EMPTY;
57     selfLink_ = "";
58     sourceDisk_ = "";
59     sourceDiskId_ = "";
60     sourceImage_ = "";
61     sourceImageId_ = "";
62     sourceSnapshot_ = "";
63     sourceSnapshotId_ = "";
64     sourceStorageObject_ = "";
65     status_ = "";
66     type_ = "";
67     users_ = com.google.protobuf.LazyStringArrayList.EMPTY;
68     zone_ = "";
69   }
70 
71   @java.lang.Override
72   @SuppressWarnings({"unused"})
newInstance(UnusedPrivateParameter unused)73   protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
74     return new Disk();
75   }
76 
77   @java.lang.Override
getUnknownFields()78   public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
79     return this.unknownFields;
80   }
81 
getDescriptor()82   public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
83     return com.google.cloud.compute.v1.Compute
84         .internal_static_google_cloud_compute_v1_Disk_descriptor;
85   }
86 
87   @SuppressWarnings({"rawtypes"})
88   @java.lang.Override
internalGetMapField(int number)89   protected com.google.protobuf.MapField internalGetMapField(int number) {
90     switch (number) {
91       case 500195327:
92         return internalGetLabels();
93       default:
94         throw new RuntimeException("Invalid map field number: " + number);
95     }
96   }
97 
98   @java.lang.Override
99   protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()100       internalGetFieldAccessorTable() {
101     return com.google.cloud.compute.v1.Compute
102         .internal_static_google_cloud_compute_v1_Disk_fieldAccessorTable
103         .ensureFieldAccessorsInitialized(
104             com.google.cloud.compute.v1.Disk.class, com.google.cloud.compute.v1.Disk.Builder.class);
105   }
106 
107   /**
108    *
109    *
110    * <pre>
111    * The architecture of the disk. Valid values are ARM64 or X86_64.
112    * </pre>
113    *
114    * Protobuf enum {@code google.cloud.compute.v1.Disk.Architecture}
115    */
116   public enum Architecture implements com.google.protobuf.ProtocolMessageEnum {
117     /**
118      *
119      *
120      * <pre>
121      * A value indicating that the enum field is not set.
122      * </pre>
123      *
124      * <code>UNDEFINED_ARCHITECTURE = 0;</code>
125      */
126     UNDEFINED_ARCHITECTURE(0),
127     /**
128      *
129      *
130      * <pre>
131      * Default value indicating Architecture is not set.
132      * </pre>
133      *
134      * <code>ARCHITECTURE_UNSPECIFIED = 394750507;</code>
135      */
136     ARCHITECTURE_UNSPECIFIED(394750507),
137     /**
138      *
139      *
140      * <pre>
141      * Machines with architecture ARM64
142      * </pre>
143      *
144      * <code>ARM64 = 62547450;</code>
145      */
146     ARM64(62547450),
147     /**
148      *
149      *
150      * <pre>
151      * Machines with architecture X86_64
152      * </pre>
153      *
154      * <code>X86_64 = 425300551;</code>
155      */
156     X86_64(425300551),
157     UNRECOGNIZED(-1),
158     ;
159 
160     /**
161      *
162      *
163      * <pre>
164      * A value indicating that the enum field is not set.
165      * </pre>
166      *
167      * <code>UNDEFINED_ARCHITECTURE = 0;</code>
168      */
169     public static final int UNDEFINED_ARCHITECTURE_VALUE = 0;
170     /**
171      *
172      *
173      * <pre>
174      * Default value indicating Architecture is not set.
175      * </pre>
176      *
177      * <code>ARCHITECTURE_UNSPECIFIED = 394750507;</code>
178      */
179     public static final int ARCHITECTURE_UNSPECIFIED_VALUE = 394750507;
180     /**
181      *
182      *
183      * <pre>
184      * Machines with architecture ARM64
185      * </pre>
186      *
187      * <code>ARM64 = 62547450;</code>
188      */
189     public static final int ARM64_VALUE = 62547450;
190     /**
191      *
192      *
193      * <pre>
194      * Machines with architecture X86_64
195      * </pre>
196      *
197      * <code>X86_64 = 425300551;</code>
198      */
199     public static final int X86_64_VALUE = 425300551;
200 
getNumber()201     public final int getNumber() {
202       if (this == UNRECOGNIZED) {
203         throw new java.lang.IllegalArgumentException(
204             "Can't get the number of an unknown enum value.");
205       }
206       return value;
207     }
208 
209     /**
210      * @param value The numeric wire value of the corresponding enum entry.
211      * @return The enum associated with the given numeric wire value.
212      * @deprecated Use {@link #forNumber(int)} instead.
213      */
214     @java.lang.Deprecated
valueOf(int value)215     public static Architecture valueOf(int value) {
216       return forNumber(value);
217     }
218 
219     /**
220      * @param value The numeric wire value of the corresponding enum entry.
221      * @return The enum associated with the given numeric wire value.
222      */
forNumber(int value)223     public static Architecture forNumber(int value) {
224       switch (value) {
225         case 0:
226           return UNDEFINED_ARCHITECTURE;
227         case 394750507:
228           return ARCHITECTURE_UNSPECIFIED;
229         case 62547450:
230           return ARM64;
231         case 425300551:
232           return X86_64;
233         default:
234           return null;
235       }
236     }
237 
internalGetValueMap()238     public static com.google.protobuf.Internal.EnumLiteMap<Architecture> internalGetValueMap() {
239       return internalValueMap;
240     }
241 
242     private static final com.google.protobuf.Internal.EnumLiteMap<Architecture> internalValueMap =
243         new com.google.protobuf.Internal.EnumLiteMap<Architecture>() {
244           public Architecture findValueByNumber(int number) {
245             return Architecture.forNumber(number);
246           }
247         };
248 
getValueDescriptor()249     public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() {
250       if (this == UNRECOGNIZED) {
251         throw new java.lang.IllegalStateException(
252             "Can't get the descriptor of an unrecognized enum value.");
253       }
254       return getDescriptor().getValues().get(ordinal());
255     }
256 
getDescriptorForType()257     public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() {
258       return getDescriptor();
259     }
260 
getDescriptor()261     public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() {
262       return com.google.cloud.compute.v1.Disk.getDescriptor().getEnumTypes().get(0);
263     }
264 
265     private static final Architecture[] VALUES = values();
266 
valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)267     public static Architecture valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
268       if (desc.getType() != getDescriptor()) {
269         throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type.");
270       }
271       if (desc.getIndex() == -1) {
272         return UNRECOGNIZED;
273       }
274       return VALUES[desc.getIndex()];
275     }
276 
277     private final int value;
278 
Architecture(int value)279     private Architecture(int value) {
280       this.value = value;
281     }
282 
283     // @@protoc_insertion_point(enum_scope:google.cloud.compute.v1.Disk.Architecture)
284   }
285 
286   /**
287    *
288    *
289    * <pre>
290    * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
291    * </pre>
292    *
293    * Protobuf enum {@code google.cloud.compute.v1.Disk.Status}
294    */
295   public enum Status implements com.google.protobuf.ProtocolMessageEnum {
296     /**
297      *
298      *
299      * <pre>
300      * A value indicating that the enum field is not set.
301      * </pre>
302      *
303      * <code>UNDEFINED_STATUS = 0;</code>
304      */
305     UNDEFINED_STATUS(0),
306     /**
307      *
308      *
309      * <pre>
310      * Disk is provisioning
311      * </pre>
312      *
313      * <code>CREATING = 455564985;</code>
314      */
315     CREATING(455564985),
316     /**
317      *
318      *
319      * <pre>
320      * Disk is deleting.
321      * </pre>
322      *
323      * <code>DELETING = 528602024;</code>
324      */
325     DELETING(528602024),
326     /**
327      *
328      *
329      * <pre>
330      * Disk creation failed.
331      * </pre>
332      *
333      * <code>FAILED = 455706685;</code>
334      */
335     FAILED(455706685),
336     /**
337      *
338      *
339      * <pre>
340      * Disk is ready for use.
341      * </pre>
342      *
343      * <code>READY = 77848963;</code>
344      */
345     READY(77848963),
346     /**
347      *
348      *
349      * <pre>
350      * Source data is being copied into the disk.
351      * </pre>
352      *
353      * <code>RESTORING = 404263851;</code>
354      */
355     RESTORING(404263851),
356     UNRECOGNIZED(-1),
357     ;
358 
359     /**
360      *
361      *
362      * <pre>
363      * A value indicating that the enum field is not set.
364      * </pre>
365      *
366      * <code>UNDEFINED_STATUS = 0;</code>
367      */
368     public static final int UNDEFINED_STATUS_VALUE = 0;
369     /**
370      *
371      *
372      * <pre>
373      * Disk is provisioning
374      * </pre>
375      *
376      * <code>CREATING = 455564985;</code>
377      */
378     public static final int CREATING_VALUE = 455564985;
379     /**
380      *
381      *
382      * <pre>
383      * Disk is deleting.
384      * </pre>
385      *
386      * <code>DELETING = 528602024;</code>
387      */
388     public static final int DELETING_VALUE = 528602024;
389     /**
390      *
391      *
392      * <pre>
393      * Disk creation failed.
394      * </pre>
395      *
396      * <code>FAILED = 455706685;</code>
397      */
398     public static final int FAILED_VALUE = 455706685;
399     /**
400      *
401      *
402      * <pre>
403      * Disk is ready for use.
404      * </pre>
405      *
406      * <code>READY = 77848963;</code>
407      */
408     public static final int READY_VALUE = 77848963;
409     /**
410      *
411      *
412      * <pre>
413      * Source data is being copied into the disk.
414      * </pre>
415      *
416      * <code>RESTORING = 404263851;</code>
417      */
418     public static final int RESTORING_VALUE = 404263851;
419 
getNumber()420     public final int getNumber() {
421       if (this == UNRECOGNIZED) {
422         throw new java.lang.IllegalArgumentException(
423             "Can't get the number of an unknown enum value.");
424       }
425       return value;
426     }
427 
428     /**
429      * @param value The numeric wire value of the corresponding enum entry.
430      * @return The enum associated with the given numeric wire value.
431      * @deprecated Use {@link #forNumber(int)} instead.
432      */
433     @java.lang.Deprecated
valueOf(int value)434     public static Status valueOf(int value) {
435       return forNumber(value);
436     }
437 
438     /**
439      * @param value The numeric wire value of the corresponding enum entry.
440      * @return The enum associated with the given numeric wire value.
441      */
forNumber(int value)442     public static Status forNumber(int value) {
443       switch (value) {
444         case 0:
445           return UNDEFINED_STATUS;
446         case 455564985:
447           return CREATING;
448         case 528602024:
449           return DELETING;
450         case 455706685:
451           return FAILED;
452         case 77848963:
453           return READY;
454         case 404263851:
455           return RESTORING;
456         default:
457           return null;
458       }
459     }
460 
internalGetValueMap()461     public static com.google.protobuf.Internal.EnumLiteMap<Status> internalGetValueMap() {
462       return internalValueMap;
463     }
464 
465     private static final com.google.protobuf.Internal.EnumLiteMap<Status> internalValueMap =
466         new com.google.protobuf.Internal.EnumLiteMap<Status>() {
467           public Status findValueByNumber(int number) {
468             return Status.forNumber(number);
469           }
470         };
471 
getValueDescriptor()472     public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() {
473       if (this == UNRECOGNIZED) {
474         throw new java.lang.IllegalStateException(
475             "Can't get the descriptor of an unrecognized enum value.");
476       }
477       return getDescriptor().getValues().get(ordinal());
478     }
479 
getDescriptorForType()480     public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() {
481       return getDescriptor();
482     }
483 
getDescriptor()484     public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() {
485       return com.google.cloud.compute.v1.Disk.getDescriptor().getEnumTypes().get(1);
486     }
487 
488     private static final Status[] VALUES = values();
489 
valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)490     public static Status valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
491       if (desc.getType() != getDescriptor()) {
492         throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type.");
493       }
494       if (desc.getIndex() == -1) {
495         return UNRECOGNIZED;
496       }
497       return VALUES[desc.getIndex()];
498     }
499 
500     private final int value;
501 
Status(int value)502     private Status(int value) {
503       this.value = value;
504     }
505 
506     // @@protoc_insertion_point(enum_scope:google.cloud.compute.v1.Disk.Status)
507   }
508 
509   private int bitField0_;
510   public static final int ARCHITECTURE_FIELD_NUMBER = 302803283;
511 
512   @SuppressWarnings("serial")
513   private volatile java.lang.Object architecture_ = "";
514   /**
515    *
516    *
517    * <pre>
518    * The architecture of the disk. Valid values are ARM64 or X86_64.
519    * Check the Architecture enum for the list of possible values.
520    * </pre>
521    *
522    * <code>optional string architecture = 302803283;</code>
523    *
524    * @return Whether the architecture field is set.
525    */
526   @java.lang.Override
hasArchitecture()527   public boolean hasArchitecture() {
528     return ((bitField0_ & 0x00000001) != 0);
529   }
530   /**
531    *
532    *
533    * <pre>
534    * The architecture of the disk. Valid values are ARM64 or X86_64.
535    * Check the Architecture enum for the list of possible values.
536    * </pre>
537    *
538    * <code>optional string architecture = 302803283;</code>
539    *
540    * @return The architecture.
541    */
542   @java.lang.Override
getArchitecture()543   public java.lang.String getArchitecture() {
544     java.lang.Object ref = architecture_;
545     if (ref instanceof java.lang.String) {
546       return (java.lang.String) ref;
547     } else {
548       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
549       java.lang.String s = bs.toStringUtf8();
550       architecture_ = s;
551       return s;
552     }
553   }
554   /**
555    *
556    *
557    * <pre>
558    * The architecture of the disk. Valid values are ARM64 or X86_64.
559    * Check the Architecture enum for the list of possible values.
560    * </pre>
561    *
562    * <code>optional string architecture = 302803283;</code>
563    *
564    * @return The bytes for architecture.
565    */
566   @java.lang.Override
getArchitectureBytes()567   public com.google.protobuf.ByteString getArchitectureBytes() {
568     java.lang.Object ref = architecture_;
569     if (ref instanceof java.lang.String) {
570       com.google.protobuf.ByteString b =
571           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
572       architecture_ = b;
573       return b;
574     } else {
575       return (com.google.protobuf.ByteString) ref;
576     }
577   }
578 
579   public static final int CREATION_TIMESTAMP_FIELD_NUMBER = 30525366;
580 
581   @SuppressWarnings("serial")
582   private volatile java.lang.Object creationTimestamp_ = "";
583   /**
584    *
585    *
586    * <pre>
587    * [Output Only] Creation timestamp in RFC3339 text format.
588    * </pre>
589    *
590    * <code>optional string creation_timestamp = 30525366;</code>
591    *
592    * @return Whether the creationTimestamp field is set.
593    */
594   @java.lang.Override
hasCreationTimestamp()595   public boolean hasCreationTimestamp() {
596     return ((bitField0_ & 0x00000002) != 0);
597   }
598   /**
599    *
600    *
601    * <pre>
602    * [Output Only] Creation timestamp in RFC3339 text format.
603    * </pre>
604    *
605    * <code>optional string creation_timestamp = 30525366;</code>
606    *
607    * @return The creationTimestamp.
608    */
609   @java.lang.Override
getCreationTimestamp()610   public java.lang.String getCreationTimestamp() {
611     java.lang.Object ref = creationTimestamp_;
612     if (ref instanceof java.lang.String) {
613       return (java.lang.String) ref;
614     } else {
615       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
616       java.lang.String s = bs.toStringUtf8();
617       creationTimestamp_ = s;
618       return s;
619     }
620   }
621   /**
622    *
623    *
624    * <pre>
625    * [Output Only] Creation timestamp in RFC3339 text format.
626    * </pre>
627    *
628    * <code>optional string creation_timestamp = 30525366;</code>
629    *
630    * @return The bytes for creationTimestamp.
631    */
632   @java.lang.Override
getCreationTimestampBytes()633   public com.google.protobuf.ByteString getCreationTimestampBytes() {
634     java.lang.Object ref = creationTimestamp_;
635     if (ref instanceof java.lang.String) {
636       com.google.protobuf.ByteString b =
637           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
638       creationTimestamp_ = b;
639       return b;
640     } else {
641       return (com.google.protobuf.ByteString) ref;
642     }
643   }
644 
645   public static final int DESCRIPTION_FIELD_NUMBER = 422937596;
646 
647   @SuppressWarnings("serial")
648   private volatile java.lang.Object description_ = "";
649   /**
650    *
651    *
652    * <pre>
653    * An optional description of this resource. Provide this property when you create the resource.
654    * </pre>
655    *
656    * <code>optional string description = 422937596;</code>
657    *
658    * @return Whether the description field is set.
659    */
660   @java.lang.Override
hasDescription()661   public boolean hasDescription() {
662     return ((bitField0_ & 0x00000004) != 0);
663   }
664   /**
665    *
666    *
667    * <pre>
668    * An optional description of this resource. Provide this property when you create the resource.
669    * </pre>
670    *
671    * <code>optional string description = 422937596;</code>
672    *
673    * @return The description.
674    */
675   @java.lang.Override
getDescription()676   public java.lang.String getDescription() {
677     java.lang.Object ref = description_;
678     if (ref instanceof java.lang.String) {
679       return (java.lang.String) ref;
680     } else {
681       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
682       java.lang.String s = bs.toStringUtf8();
683       description_ = s;
684       return s;
685     }
686   }
687   /**
688    *
689    *
690    * <pre>
691    * An optional description of this resource. Provide this property when you create the resource.
692    * </pre>
693    *
694    * <code>optional string description = 422937596;</code>
695    *
696    * @return The bytes for description.
697    */
698   @java.lang.Override
getDescriptionBytes()699   public com.google.protobuf.ByteString getDescriptionBytes() {
700     java.lang.Object ref = description_;
701     if (ref instanceof java.lang.String) {
702       com.google.protobuf.ByteString b =
703           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
704       description_ = b;
705       return b;
706     } else {
707       return (com.google.protobuf.ByteString) ref;
708     }
709   }
710 
711   public static final int DISK_ENCRYPTION_KEY_FIELD_NUMBER = 271660677;
712   private com.google.cloud.compute.v1.CustomerEncryptionKey diskEncryptionKey_;
713   /**
714    *
715    *
716    * <pre>
717    * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
718    * </pre>
719    *
720    * <code>optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
721    * </code>
722    *
723    * @return Whether the diskEncryptionKey field is set.
724    */
725   @java.lang.Override
hasDiskEncryptionKey()726   public boolean hasDiskEncryptionKey() {
727     return ((bitField0_ & 0x00000008) != 0);
728   }
729   /**
730    *
731    *
732    * <pre>
733    * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
734    * </pre>
735    *
736    * <code>optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
737    * </code>
738    *
739    * @return The diskEncryptionKey.
740    */
741   @java.lang.Override
getDiskEncryptionKey()742   public com.google.cloud.compute.v1.CustomerEncryptionKey getDiskEncryptionKey() {
743     return diskEncryptionKey_ == null
744         ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
745         : diskEncryptionKey_;
746   }
747   /**
748    *
749    *
750    * <pre>
751    * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
752    * </pre>
753    *
754    * <code>optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
755    * </code>
756    */
757   @java.lang.Override
758   public com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder
getDiskEncryptionKeyOrBuilder()759       getDiskEncryptionKeyOrBuilder() {
760     return diskEncryptionKey_ == null
761         ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
762         : diskEncryptionKey_;
763   }
764 
765   public static final int GUEST_OS_FEATURES_FIELD_NUMBER = 79294545;
766 
767   @SuppressWarnings("serial")
768   private java.util.List<com.google.cloud.compute.v1.GuestOsFeature> guestOsFeatures_;
769   /**
770    *
771    *
772    * <pre>
773    * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
774    * </pre>
775    *
776    * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
777    */
778   @java.lang.Override
getGuestOsFeaturesList()779   public java.util.List<com.google.cloud.compute.v1.GuestOsFeature> getGuestOsFeaturesList() {
780     return guestOsFeatures_;
781   }
782   /**
783    *
784    *
785    * <pre>
786    * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
787    * </pre>
788    *
789    * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
790    */
791   @java.lang.Override
792   public java.util.List<? extends com.google.cloud.compute.v1.GuestOsFeatureOrBuilder>
getGuestOsFeaturesOrBuilderList()793       getGuestOsFeaturesOrBuilderList() {
794     return guestOsFeatures_;
795   }
796   /**
797    *
798    *
799    * <pre>
800    * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
801    * </pre>
802    *
803    * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
804    */
805   @java.lang.Override
getGuestOsFeaturesCount()806   public int getGuestOsFeaturesCount() {
807     return guestOsFeatures_.size();
808   }
809   /**
810    *
811    *
812    * <pre>
813    * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
814    * </pre>
815    *
816    * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
817    */
818   @java.lang.Override
getGuestOsFeatures(int index)819   public com.google.cloud.compute.v1.GuestOsFeature getGuestOsFeatures(int index) {
820     return guestOsFeatures_.get(index);
821   }
822   /**
823    *
824    *
825    * <pre>
826    * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
827    * </pre>
828    *
829    * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
830    */
831   @java.lang.Override
getGuestOsFeaturesOrBuilder( int index)832   public com.google.cloud.compute.v1.GuestOsFeatureOrBuilder getGuestOsFeaturesOrBuilder(
833       int index) {
834     return guestOsFeatures_.get(index);
835   }
836 
837   public static final int ID_FIELD_NUMBER = 3355;
838   private long id_ = 0L;
839   /**
840    *
841    *
842    * <pre>
843    * [Output Only] The unique identifier for the resource. This identifier is defined by the server.
844    * </pre>
845    *
846    * <code>optional uint64 id = 3355;</code>
847    *
848    * @return Whether the id field is set.
849    */
850   @java.lang.Override
hasId()851   public boolean hasId() {
852     return ((bitField0_ & 0x00000010) != 0);
853   }
854   /**
855    *
856    *
857    * <pre>
858    * [Output Only] The unique identifier for the resource. This identifier is defined by the server.
859    * </pre>
860    *
861    * <code>optional uint64 id = 3355;</code>
862    *
863    * @return The id.
864    */
865   @java.lang.Override
getId()866   public long getId() {
867     return id_;
868   }
869 
870   public static final int KIND_FIELD_NUMBER = 3292052;
871 
872   @SuppressWarnings("serial")
873   private volatile java.lang.Object kind_ = "";
874   /**
875    *
876    *
877    * <pre>
878    * [Output Only] Type of the resource. Always compute#disk for disks.
879    * </pre>
880    *
881    * <code>optional string kind = 3292052;</code>
882    *
883    * @return Whether the kind field is set.
884    */
885   @java.lang.Override
hasKind()886   public boolean hasKind() {
887     return ((bitField0_ & 0x00000020) != 0);
888   }
889   /**
890    *
891    *
892    * <pre>
893    * [Output Only] Type of the resource. Always compute#disk for disks.
894    * </pre>
895    *
896    * <code>optional string kind = 3292052;</code>
897    *
898    * @return The kind.
899    */
900   @java.lang.Override
getKind()901   public java.lang.String getKind() {
902     java.lang.Object ref = kind_;
903     if (ref instanceof java.lang.String) {
904       return (java.lang.String) ref;
905     } else {
906       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
907       java.lang.String s = bs.toStringUtf8();
908       kind_ = s;
909       return s;
910     }
911   }
912   /**
913    *
914    *
915    * <pre>
916    * [Output Only] Type of the resource. Always compute#disk for disks.
917    * </pre>
918    *
919    * <code>optional string kind = 3292052;</code>
920    *
921    * @return The bytes for kind.
922    */
923   @java.lang.Override
getKindBytes()924   public com.google.protobuf.ByteString getKindBytes() {
925     java.lang.Object ref = kind_;
926     if (ref instanceof java.lang.String) {
927       com.google.protobuf.ByteString b =
928           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
929       kind_ = b;
930       return b;
931     } else {
932       return (com.google.protobuf.ByteString) ref;
933     }
934   }
935 
936   public static final int LABEL_FINGERPRINT_FIELD_NUMBER = 178124825;
937 
938   @SuppressWarnings("serial")
939   private volatile java.lang.Object labelFingerprint_ = "";
940   /**
941    *
942    *
943    * <pre>
944    * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
945    * </pre>
946    *
947    * <code>optional string label_fingerprint = 178124825;</code>
948    *
949    * @return Whether the labelFingerprint field is set.
950    */
951   @java.lang.Override
hasLabelFingerprint()952   public boolean hasLabelFingerprint() {
953     return ((bitField0_ & 0x00000040) != 0);
954   }
955   /**
956    *
957    *
958    * <pre>
959    * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
960    * </pre>
961    *
962    * <code>optional string label_fingerprint = 178124825;</code>
963    *
964    * @return The labelFingerprint.
965    */
966   @java.lang.Override
getLabelFingerprint()967   public java.lang.String getLabelFingerprint() {
968     java.lang.Object ref = labelFingerprint_;
969     if (ref instanceof java.lang.String) {
970       return (java.lang.String) ref;
971     } else {
972       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
973       java.lang.String s = bs.toStringUtf8();
974       labelFingerprint_ = s;
975       return s;
976     }
977   }
978   /**
979    *
980    *
981    * <pre>
982    * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
983    * </pre>
984    *
985    * <code>optional string label_fingerprint = 178124825;</code>
986    *
987    * @return The bytes for labelFingerprint.
988    */
989   @java.lang.Override
getLabelFingerprintBytes()990   public com.google.protobuf.ByteString getLabelFingerprintBytes() {
991     java.lang.Object ref = labelFingerprint_;
992     if (ref instanceof java.lang.String) {
993       com.google.protobuf.ByteString b =
994           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
995       labelFingerprint_ = b;
996       return b;
997     } else {
998       return (com.google.protobuf.ByteString) ref;
999     }
1000   }
1001 
1002   public static final int LABELS_FIELD_NUMBER = 500195327;
1003 
1004   private static final class LabelsDefaultEntryHolder {
1005     static final com.google.protobuf.MapEntry<java.lang.String, java.lang.String> defaultEntry =
1006         com.google.protobuf.MapEntry.<java.lang.String, java.lang.String>newDefaultInstance(
1007             com.google.cloud.compute.v1.Compute
1008                 .internal_static_google_cloud_compute_v1_Disk_LabelsEntry_descriptor,
1009             com.google.protobuf.WireFormat.FieldType.STRING,
1010             "",
1011             com.google.protobuf.WireFormat.FieldType.STRING,
1012             "");
1013   }
1014 
1015   @SuppressWarnings("serial")
1016   private com.google.protobuf.MapField<java.lang.String, java.lang.String> labels_;
1017 
internalGetLabels()1018   private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetLabels() {
1019     if (labels_ == null) {
1020       return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry);
1021     }
1022     return labels_;
1023   }
1024 
getLabelsCount()1025   public int getLabelsCount() {
1026     return internalGetLabels().getMap().size();
1027   }
1028   /**
1029    *
1030    *
1031    * <pre>
1032    * Labels to apply to this disk. These can be later modified by the setLabels method.
1033    * </pre>
1034    *
1035    * <code>map&lt;string, string&gt; labels = 500195327;</code>
1036    */
1037   @java.lang.Override
containsLabels(java.lang.String key)1038   public boolean containsLabels(java.lang.String key) {
1039     if (key == null) {
1040       throw new NullPointerException("map key");
1041     }
1042     return internalGetLabels().getMap().containsKey(key);
1043   }
1044   /** Use {@link #getLabelsMap()} instead. */
1045   @java.lang.Override
1046   @java.lang.Deprecated
getLabels()1047   public java.util.Map<java.lang.String, java.lang.String> getLabels() {
1048     return getLabelsMap();
1049   }
1050   /**
1051    *
1052    *
1053    * <pre>
1054    * Labels to apply to this disk. These can be later modified by the setLabels method.
1055    * </pre>
1056    *
1057    * <code>map&lt;string, string&gt; labels = 500195327;</code>
1058    */
1059   @java.lang.Override
getLabelsMap()1060   public java.util.Map<java.lang.String, java.lang.String> getLabelsMap() {
1061     return internalGetLabels().getMap();
1062   }
1063   /**
1064    *
1065    *
1066    * <pre>
1067    * Labels to apply to this disk. These can be later modified by the setLabels method.
1068    * </pre>
1069    *
1070    * <code>map&lt;string, string&gt; labels = 500195327;</code>
1071    */
1072   @java.lang.Override
getLabelsOrDefault( java.lang.String key, java.lang.String defaultValue)1073   public /* nullable */ java.lang.String getLabelsOrDefault(
1074       java.lang.String key,
1075       /* nullable */
1076       java.lang.String defaultValue) {
1077     if (key == null) {
1078       throw new NullPointerException("map key");
1079     }
1080     java.util.Map<java.lang.String, java.lang.String> map = internalGetLabels().getMap();
1081     return map.containsKey(key) ? map.get(key) : defaultValue;
1082   }
1083   /**
1084    *
1085    *
1086    * <pre>
1087    * Labels to apply to this disk. These can be later modified by the setLabels method.
1088    * </pre>
1089    *
1090    * <code>map&lt;string, string&gt; labels = 500195327;</code>
1091    */
1092   @java.lang.Override
getLabelsOrThrow(java.lang.String key)1093   public java.lang.String getLabelsOrThrow(java.lang.String key) {
1094     if (key == null) {
1095       throw new NullPointerException("map key");
1096     }
1097     java.util.Map<java.lang.String, java.lang.String> map = internalGetLabels().getMap();
1098     if (!map.containsKey(key)) {
1099       throw new java.lang.IllegalArgumentException();
1100     }
1101     return map.get(key);
1102   }
1103 
1104   public static final int LAST_ATTACH_TIMESTAMP_FIELD_NUMBER = 42159653;
1105 
1106   @SuppressWarnings("serial")
1107   private volatile java.lang.Object lastAttachTimestamp_ = "";
1108   /**
1109    *
1110    *
1111    * <pre>
1112    * [Output Only] Last attach timestamp in RFC3339 text format.
1113    * </pre>
1114    *
1115    * <code>optional string last_attach_timestamp = 42159653;</code>
1116    *
1117    * @return Whether the lastAttachTimestamp field is set.
1118    */
1119   @java.lang.Override
hasLastAttachTimestamp()1120   public boolean hasLastAttachTimestamp() {
1121     return ((bitField0_ & 0x00000080) != 0);
1122   }
1123   /**
1124    *
1125    *
1126    * <pre>
1127    * [Output Only] Last attach timestamp in RFC3339 text format.
1128    * </pre>
1129    *
1130    * <code>optional string last_attach_timestamp = 42159653;</code>
1131    *
1132    * @return The lastAttachTimestamp.
1133    */
1134   @java.lang.Override
getLastAttachTimestamp()1135   public java.lang.String getLastAttachTimestamp() {
1136     java.lang.Object ref = lastAttachTimestamp_;
1137     if (ref instanceof java.lang.String) {
1138       return (java.lang.String) ref;
1139     } else {
1140       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
1141       java.lang.String s = bs.toStringUtf8();
1142       lastAttachTimestamp_ = s;
1143       return s;
1144     }
1145   }
1146   /**
1147    *
1148    *
1149    * <pre>
1150    * [Output Only] Last attach timestamp in RFC3339 text format.
1151    * </pre>
1152    *
1153    * <code>optional string last_attach_timestamp = 42159653;</code>
1154    *
1155    * @return The bytes for lastAttachTimestamp.
1156    */
1157   @java.lang.Override
getLastAttachTimestampBytes()1158   public com.google.protobuf.ByteString getLastAttachTimestampBytes() {
1159     java.lang.Object ref = lastAttachTimestamp_;
1160     if (ref instanceof java.lang.String) {
1161       com.google.protobuf.ByteString b =
1162           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
1163       lastAttachTimestamp_ = b;
1164       return b;
1165     } else {
1166       return (com.google.protobuf.ByteString) ref;
1167     }
1168   }
1169 
1170   public static final int LAST_DETACH_TIMESTAMP_FIELD_NUMBER = 56471027;
1171 
1172   @SuppressWarnings("serial")
1173   private volatile java.lang.Object lastDetachTimestamp_ = "";
1174   /**
1175    *
1176    *
1177    * <pre>
1178    * [Output Only] Last detach timestamp in RFC3339 text format.
1179    * </pre>
1180    *
1181    * <code>optional string last_detach_timestamp = 56471027;</code>
1182    *
1183    * @return Whether the lastDetachTimestamp field is set.
1184    */
1185   @java.lang.Override
hasLastDetachTimestamp()1186   public boolean hasLastDetachTimestamp() {
1187     return ((bitField0_ & 0x00000100) != 0);
1188   }
1189   /**
1190    *
1191    *
1192    * <pre>
1193    * [Output Only] Last detach timestamp in RFC3339 text format.
1194    * </pre>
1195    *
1196    * <code>optional string last_detach_timestamp = 56471027;</code>
1197    *
1198    * @return The lastDetachTimestamp.
1199    */
1200   @java.lang.Override
getLastDetachTimestamp()1201   public java.lang.String getLastDetachTimestamp() {
1202     java.lang.Object ref = lastDetachTimestamp_;
1203     if (ref instanceof java.lang.String) {
1204       return (java.lang.String) ref;
1205     } else {
1206       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
1207       java.lang.String s = bs.toStringUtf8();
1208       lastDetachTimestamp_ = s;
1209       return s;
1210     }
1211   }
1212   /**
1213    *
1214    *
1215    * <pre>
1216    * [Output Only] Last detach timestamp in RFC3339 text format.
1217    * </pre>
1218    *
1219    * <code>optional string last_detach_timestamp = 56471027;</code>
1220    *
1221    * @return The bytes for lastDetachTimestamp.
1222    */
1223   @java.lang.Override
getLastDetachTimestampBytes()1224   public com.google.protobuf.ByteString getLastDetachTimestampBytes() {
1225     java.lang.Object ref = lastDetachTimestamp_;
1226     if (ref instanceof java.lang.String) {
1227       com.google.protobuf.ByteString b =
1228           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
1229       lastDetachTimestamp_ = b;
1230       return b;
1231     } else {
1232       return (com.google.protobuf.ByteString) ref;
1233     }
1234   }
1235 
1236   public static final int LICENSE_CODES_FIELD_NUMBER = 45482664;
1237 
1238   @SuppressWarnings("serial")
1239   private com.google.protobuf.Internal.LongList licenseCodes_;
1240   /**
1241    *
1242    *
1243    * <pre>
1244    * Integer license codes indicating which licenses are attached to this disk.
1245    * </pre>
1246    *
1247    * <code>repeated int64 license_codes = 45482664;</code>
1248    *
1249    * @return A list containing the licenseCodes.
1250    */
1251   @java.lang.Override
getLicenseCodesList()1252   public java.util.List<java.lang.Long> getLicenseCodesList() {
1253     return licenseCodes_;
1254   }
1255   /**
1256    *
1257    *
1258    * <pre>
1259    * Integer license codes indicating which licenses are attached to this disk.
1260    * </pre>
1261    *
1262    * <code>repeated int64 license_codes = 45482664;</code>
1263    *
1264    * @return The count of licenseCodes.
1265    */
getLicenseCodesCount()1266   public int getLicenseCodesCount() {
1267     return licenseCodes_.size();
1268   }
1269   /**
1270    *
1271    *
1272    * <pre>
1273    * Integer license codes indicating which licenses are attached to this disk.
1274    * </pre>
1275    *
1276    * <code>repeated int64 license_codes = 45482664;</code>
1277    *
1278    * @param index The index of the element to return.
1279    * @return The licenseCodes at the given index.
1280    */
getLicenseCodes(int index)1281   public long getLicenseCodes(int index) {
1282     return licenseCodes_.getLong(index);
1283   }
1284 
1285   private int licenseCodesMemoizedSerializedSize = -1;
1286 
1287   public static final int LICENSES_FIELD_NUMBER = 337642578;
1288 
1289   @SuppressWarnings("serial")
1290   private com.google.protobuf.LazyStringList licenses_;
1291   /**
1292    *
1293    *
1294    * <pre>
1295    * A list of publicly visible licenses. Reserved for Google's use.
1296    * </pre>
1297    *
1298    * <code>repeated string licenses = 337642578;</code>
1299    *
1300    * @return A list containing the licenses.
1301    */
getLicensesList()1302   public com.google.protobuf.ProtocolStringList getLicensesList() {
1303     return licenses_;
1304   }
1305   /**
1306    *
1307    *
1308    * <pre>
1309    * A list of publicly visible licenses. Reserved for Google's use.
1310    * </pre>
1311    *
1312    * <code>repeated string licenses = 337642578;</code>
1313    *
1314    * @return The count of licenses.
1315    */
getLicensesCount()1316   public int getLicensesCount() {
1317     return licenses_.size();
1318   }
1319   /**
1320    *
1321    *
1322    * <pre>
1323    * A list of publicly visible licenses. Reserved for Google's use.
1324    * </pre>
1325    *
1326    * <code>repeated string licenses = 337642578;</code>
1327    *
1328    * @param index The index of the element to return.
1329    * @return The licenses at the given index.
1330    */
getLicenses(int index)1331   public java.lang.String getLicenses(int index) {
1332     return licenses_.get(index);
1333   }
1334   /**
1335    *
1336    *
1337    * <pre>
1338    * A list of publicly visible licenses. Reserved for Google's use.
1339    * </pre>
1340    *
1341    * <code>repeated string licenses = 337642578;</code>
1342    *
1343    * @param index The index of the value to return.
1344    * @return The bytes of the licenses at the given index.
1345    */
getLicensesBytes(int index)1346   public com.google.protobuf.ByteString getLicensesBytes(int index) {
1347     return licenses_.getByteString(index);
1348   }
1349 
1350   public static final int LOCATION_HINT_FIELD_NUMBER = 350519505;
1351 
1352   @SuppressWarnings("serial")
1353   private volatile java.lang.Object locationHint_ = "";
1354   /**
1355    *
1356    *
1357    * <pre>
1358    * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
1359    * </pre>
1360    *
1361    * <code>optional string location_hint = 350519505;</code>
1362    *
1363    * @return Whether the locationHint field is set.
1364    */
1365   @java.lang.Override
hasLocationHint()1366   public boolean hasLocationHint() {
1367     return ((bitField0_ & 0x00000200) != 0);
1368   }
1369   /**
1370    *
1371    *
1372    * <pre>
1373    * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
1374    * </pre>
1375    *
1376    * <code>optional string location_hint = 350519505;</code>
1377    *
1378    * @return The locationHint.
1379    */
1380   @java.lang.Override
getLocationHint()1381   public java.lang.String getLocationHint() {
1382     java.lang.Object ref = locationHint_;
1383     if (ref instanceof java.lang.String) {
1384       return (java.lang.String) ref;
1385     } else {
1386       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
1387       java.lang.String s = bs.toStringUtf8();
1388       locationHint_ = s;
1389       return s;
1390     }
1391   }
1392   /**
1393    *
1394    *
1395    * <pre>
1396    * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
1397    * </pre>
1398    *
1399    * <code>optional string location_hint = 350519505;</code>
1400    *
1401    * @return The bytes for locationHint.
1402    */
1403   @java.lang.Override
getLocationHintBytes()1404   public com.google.protobuf.ByteString getLocationHintBytes() {
1405     java.lang.Object ref = locationHint_;
1406     if (ref instanceof java.lang.String) {
1407       com.google.protobuf.ByteString b =
1408           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
1409       locationHint_ = b;
1410       return b;
1411     } else {
1412       return (com.google.protobuf.ByteString) ref;
1413     }
1414   }
1415 
1416   public static final int NAME_FIELD_NUMBER = 3373707;
1417 
1418   @SuppressWarnings("serial")
1419   private volatile java.lang.Object name_ = "";
1420   /**
1421    *
1422    *
1423    * <pre>
1424    * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
1425    * </pre>
1426    *
1427    * <code>optional string name = 3373707;</code>
1428    *
1429    * @return Whether the name field is set.
1430    */
1431   @java.lang.Override
hasName()1432   public boolean hasName() {
1433     return ((bitField0_ & 0x00000400) != 0);
1434   }
1435   /**
1436    *
1437    *
1438    * <pre>
1439    * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
1440    * </pre>
1441    *
1442    * <code>optional string name = 3373707;</code>
1443    *
1444    * @return The name.
1445    */
1446   @java.lang.Override
getName()1447   public java.lang.String getName() {
1448     java.lang.Object ref = name_;
1449     if (ref instanceof java.lang.String) {
1450       return (java.lang.String) ref;
1451     } else {
1452       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
1453       java.lang.String s = bs.toStringUtf8();
1454       name_ = s;
1455       return s;
1456     }
1457   }
1458   /**
1459    *
1460    *
1461    * <pre>
1462    * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
1463    * </pre>
1464    *
1465    * <code>optional string name = 3373707;</code>
1466    *
1467    * @return The bytes for name.
1468    */
1469   @java.lang.Override
getNameBytes()1470   public com.google.protobuf.ByteString getNameBytes() {
1471     java.lang.Object ref = name_;
1472     if (ref instanceof java.lang.String) {
1473       com.google.protobuf.ByteString b =
1474           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
1475       name_ = b;
1476       return b;
1477     } else {
1478       return (com.google.protobuf.ByteString) ref;
1479     }
1480   }
1481 
1482   public static final int OPTIONS_FIELD_NUMBER = 361137822;
1483 
1484   @SuppressWarnings("serial")
1485   private volatile java.lang.Object options_ = "";
1486   /**
1487    *
1488    *
1489    * <pre>
1490    * Internal use only.
1491    * </pre>
1492    *
1493    * <code>optional string options = 361137822;</code>
1494    *
1495    * @return Whether the options field is set.
1496    */
1497   @java.lang.Override
hasOptions()1498   public boolean hasOptions() {
1499     return ((bitField0_ & 0x00000800) != 0);
1500   }
1501   /**
1502    *
1503    *
1504    * <pre>
1505    * Internal use only.
1506    * </pre>
1507    *
1508    * <code>optional string options = 361137822;</code>
1509    *
1510    * @return The options.
1511    */
1512   @java.lang.Override
getOptions()1513   public java.lang.String getOptions() {
1514     java.lang.Object ref = options_;
1515     if (ref instanceof java.lang.String) {
1516       return (java.lang.String) ref;
1517     } else {
1518       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
1519       java.lang.String s = bs.toStringUtf8();
1520       options_ = s;
1521       return s;
1522     }
1523   }
1524   /**
1525    *
1526    *
1527    * <pre>
1528    * Internal use only.
1529    * </pre>
1530    *
1531    * <code>optional string options = 361137822;</code>
1532    *
1533    * @return The bytes for options.
1534    */
1535   @java.lang.Override
getOptionsBytes()1536   public com.google.protobuf.ByteString getOptionsBytes() {
1537     java.lang.Object ref = options_;
1538     if (ref instanceof java.lang.String) {
1539       com.google.protobuf.ByteString b =
1540           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
1541       options_ = b;
1542       return b;
1543     } else {
1544       return (com.google.protobuf.ByteString) ref;
1545     }
1546   }
1547 
1548   public static final int PARAMS_FIELD_NUMBER = 78313862;
1549   private com.google.cloud.compute.v1.DiskParams params_;
1550   /**
1551    *
1552    *
1553    * <pre>
1554    * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
1555    * </pre>
1556    *
1557    * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
1558    *
1559    * @return Whether the params field is set.
1560    */
1561   @java.lang.Override
hasParams()1562   public boolean hasParams() {
1563     return ((bitField0_ & 0x00001000) != 0);
1564   }
1565   /**
1566    *
1567    *
1568    * <pre>
1569    * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
1570    * </pre>
1571    *
1572    * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
1573    *
1574    * @return The params.
1575    */
1576   @java.lang.Override
getParams()1577   public com.google.cloud.compute.v1.DiskParams getParams() {
1578     return params_ == null ? com.google.cloud.compute.v1.DiskParams.getDefaultInstance() : params_;
1579   }
1580   /**
1581    *
1582    *
1583    * <pre>
1584    * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
1585    * </pre>
1586    *
1587    * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
1588    */
1589   @java.lang.Override
getParamsOrBuilder()1590   public com.google.cloud.compute.v1.DiskParamsOrBuilder getParamsOrBuilder() {
1591     return params_ == null ? com.google.cloud.compute.v1.DiskParams.getDefaultInstance() : params_;
1592   }
1593 
1594   public static final int PHYSICAL_BLOCK_SIZE_BYTES_FIELD_NUMBER = 420007943;
1595   private long physicalBlockSizeBytes_ = 0L;
1596   /**
1597    *
1598    *
1599    * <pre>
1600    * Physical block size of the persistent disk, in bytes. If not present in a request, a default value is used. The currently supported size is 4096, other sizes may be added in the future. If an unsupported value is requested, the error message will list the supported values for the caller's project.
1601    * </pre>
1602    *
1603    * <code>optional int64 physical_block_size_bytes = 420007943;</code>
1604    *
1605    * @return Whether the physicalBlockSizeBytes field is set.
1606    */
1607   @java.lang.Override
hasPhysicalBlockSizeBytes()1608   public boolean hasPhysicalBlockSizeBytes() {
1609     return ((bitField0_ & 0x00002000) != 0);
1610   }
1611   /**
1612    *
1613    *
1614    * <pre>
1615    * Physical block size of the persistent disk, in bytes. If not present in a request, a default value is used. The currently supported size is 4096, other sizes may be added in the future. If an unsupported value is requested, the error message will list the supported values for the caller's project.
1616    * </pre>
1617    *
1618    * <code>optional int64 physical_block_size_bytes = 420007943;</code>
1619    *
1620    * @return The physicalBlockSizeBytes.
1621    */
1622   @java.lang.Override
getPhysicalBlockSizeBytes()1623   public long getPhysicalBlockSizeBytes() {
1624     return physicalBlockSizeBytes_;
1625   }
1626 
1627   public static final int PROVISIONED_IOPS_FIELD_NUMBER = 186769108;
1628   private long provisionedIops_ = 0L;
1629   /**
1630    *
1631    *
1632    * <pre>
1633    * Indicates how many IOPS to provision for the disk. This sets the number of I/O operations per second that the disk can handle. Values must be between 10,000 and 120,000. For more details, see the Extreme persistent disk documentation.
1634    * </pre>
1635    *
1636    * <code>optional int64 provisioned_iops = 186769108;</code>
1637    *
1638    * @return Whether the provisionedIops field is set.
1639    */
1640   @java.lang.Override
hasProvisionedIops()1641   public boolean hasProvisionedIops() {
1642     return ((bitField0_ & 0x00004000) != 0);
1643   }
1644   /**
1645    *
1646    *
1647    * <pre>
1648    * Indicates how many IOPS to provision for the disk. This sets the number of I/O operations per second that the disk can handle. Values must be between 10,000 and 120,000. For more details, see the Extreme persistent disk documentation.
1649    * </pre>
1650    *
1651    * <code>optional int64 provisioned_iops = 186769108;</code>
1652    *
1653    * @return The provisionedIops.
1654    */
1655   @java.lang.Override
getProvisionedIops()1656   public long getProvisionedIops() {
1657     return provisionedIops_;
1658   }
1659 
1660   public static final int REGION_FIELD_NUMBER = 138946292;
1661 
1662   @SuppressWarnings("serial")
1663   private volatile java.lang.Object region_ = "";
1664   /**
1665    *
1666    *
1667    * <pre>
1668    * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
1669    * </pre>
1670    *
1671    * <code>optional string region = 138946292;</code>
1672    *
1673    * @return Whether the region field is set.
1674    */
1675   @java.lang.Override
hasRegion()1676   public boolean hasRegion() {
1677     return ((bitField0_ & 0x00008000) != 0);
1678   }
1679   /**
1680    *
1681    *
1682    * <pre>
1683    * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
1684    * </pre>
1685    *
1686    * <code>optional string region = 138946292;</code>
1687    *
1688    * @return The region.
1689    */
1690   @java.lang.Override
getRegion()1691   public java.lang.String getRegion() {
1692     java.lang.Object ref = region_;
1693     if (ref instanceof java.lang.String) {
1694       return (java.lang.String) ref;
1695     } else {
1696       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
1697       java.lang.String s = bs.toStringUtf8();
1698       region_ = s;
1699       return s;
1700     }
1701   }
1702   /**
1703    *
1704    *
1705    * <pre>
1706    * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
1707    * </pre>
1708    *
1709    * <code>optional string region = 138946292;</code>
1710    *
1711    * @return The bytes for region.
1712    */
1713   @java.lang.Override
getRegionBytes()1714   public com.google.protobuf.ByteString getRegionBytes() {
1715     java.lang.Object ref = region_;
1716     if (ref instanceof java.lang.String) {
1717       com.google.protobuf.ByteString b =
1718           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
1719       region_ = b;
1720       return b;
1721     } else {
1722       return (com.google.protobuf.ByteString) ref;
1723     }
1724   }
1725 
1726   public static final int REPLICA_ZONES_FIELD_NUMBER = 48438272;
1727 
1728   @SuppressWarnings("serial")
1729   private com.google.protobuf.LazyStringList replicaZones_;
1730   /**
1731    *
1732    *
1733    * <pre>
1734    * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
1735    * </pre>
1736    *
1737    * <code>repeated string replica_zones = 48438272;</code>
1738    *
1739    * @return A list containing the replicaZones.
1740    */
getReplicaZonesList()1741   public com.google.protobuf.ProtocolStringList getReplicaZonesList() {
1742     return replicaZones_;
1743   }
1744   /**
1745    *
1746    *
1747    * <pre>
1748    * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
1749    * </pre>
1750    *
1751    * <code>repeated string replica_zones = 48438272;</code>
1752    *
1753    * @return The count of replicaZones.
1754    */
getReplicaZonesCount()1755   public int getReplicaZonesCount() {
1756     return replicaZones_.size();
1757   }
1758   /**
1759    *
1760    *
1761    * <pre>
1762    * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
1763    * </pre>
1764    *
1765    * <code>repeated string replica_zones = 48438272;</code>
1766    *
1767    * @param index The index of the element to return.
1768    * @return The replicaZones at the given index.
1769    */
getReplicaZones(int index)1770   public java.lang.String getReplicaZones(int index) {
1771     return replicaZones_.get(index);
1772   }
1773   /**
1774    *
1775    *
1776    * <pre>
1777    * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
1778    * </pre>
1779    *
1780    * <code>repeated string replica_zones = 48438272;</code>
1781    *
1782    * @param index The index of the value to return.
1783    * @return The bytes of the replicaZones at the given index.
1784    */
getReplicaZonesBytes(int index)1785   public com.google.protobuf.ByteString getReplicaZonesBytes(int index) {
1786     return replicaZones_.getByteString(index);
1787   }
1788 
1789   public static final int RESOURCE_POLICIES_FIELD_NUMBER = 22220385;
1790 
1791   @SuppressWarnings("serial")
1792   private com.google.protobuf.LazyStringList resourcePolicies_;
1793   /**
1794    *
1795    *
1796    * <pre>
1797    * Resource policies applied to this disk for automatic snapshot creations.
1798    * </pre>
1799    *
1800    * <code>repeated string resource_policies = 22220385;</code>
1801    *
1802    * @return A list containing the resourcePolicies.
1803    */
getResourcePoliciesList()1804   public com.google.protobuf.ProtocolStringList getResourcePoliciesList() {
1805     return resourcePolicies_;
1806   }
1807   /**
1808    *
1809    *
1810    * <pre>
1811    * Resource policies applied to this disk for automatic snapshot creations.
1812    * </pre>
1813    *
1814    * <code>repeated string resource_policies = 22220385;</code>
1815    *
1816    * @return The count of resourcePolicies.
1817    */
getResourcePoliciesCount()1818   public int getResourcePoliciesCount() {
1819     return resourcePolicies_.size();
1820   }
1821   /**
1822    *
1823    *
1824    * <pre>
1825    * Resource policies applied to this disk for automatic snapshot creations.
1826    * </pre>
1827    *
1828    * <code>repeated string resource_policies = 22220385;</code>
1829    *
1830    * @param index The index of the element to return.
1831    * @return The resourcePolicies at the given index.
1832    */
getResourcePolicies(int index)1833   public java.lang.String getResourcePolicies(int index) {
1834     return resourcePolicies_.get(index);
1835   }
1836   /**
1837    *
1838    *
1839    * <pre>
1840    * Resource policies applied to this disk for automatic snapshot creations.
1841    * </pre>
1842    *
1843    * <code>repeated string resource_policies = 22220385;</code>
1844    *
1845    * @param index The index of the value to return.
1846    * @return The bytes of the resourcePolicies at the given index.
1847    */
getResourcePoliciesBytes(int index)1848   public com.google.protobuf.ByteString getResourcePoliciesBytes(int index) {
1849     return resourcePolicies_.getByteString(index);
1850   }
1851 
1852   public static final int SATISFIES_PZS_FIELD_NUMBER = 480964267;
1853   private boolean satisfiesPzs_ = false;
1854   /**
1855    *
1856    *
1857    * <pre>
1858    * [Output Only] Reserved for future use.
1859    * </pre>
1860    *
1861    * <code>optional bool satisfies_pzs = 480964267;</code>
1862    *
1863    * @return Whether the satisfiesPzs field is set.
1864    */
1865   @java.lang.Override
hasSatisfiesPzs()1866   public boolean hasSatisfiesPzs() {
1867     return ((bitField0_ & 0x00010000) != 0);
1868   }
1869   /**
1870    *
1871    *
1872    * <pre>
1873    * [Output Only] Reserved for future use.
1874    * </pre>
1875    *
1876    * <code>optional bool satisfies_pzs = 480964267;</code>
1877    *
1878    * @return The satisfiesPzs.
1879    */
1880   @java.lang.Override
getSatisfiesPzs()1881   public boolean getSatisfiesPzs() {
1882     return satisfiesPzs_;
1883   }
1884 
1885   public static final int SELF_LINK_FIELD_NUMBER = 456214797;
1886 
1887   @SuppressWarnings("serial")
1888   private volatile java.lang.Object selfLink_ = "";
1889   /**
1890    *
1891    *
1892    * <pre>
1893    * [Output Only] Server-defined fully-qualified URL for this resource.
1894    * </pre>
1895    *
1896    * <code>optional string self_link = 456214797;</code>
1897    *
1898    * @return Whether the selfLink field is set.
1899    */
1900   @java.lang.Override
hasSelfLink()1901   public boolean hasSelfLink() {
1902     return ((bitField0_ & 0x00020000) != 0);
1903   }
1904   /**
1905    *
1906    *
1907    * <pre>
1908    * [Output Only] Server-defined fully-qualified URL for this resource.
1909    * </pre>
1910    *
1911    * <code>optional string self_link = 456214797;</code>
1912    *
1913    * @return The selfLink.
1914    */
1915   @java.lang.Override
getSelfLink()1916   public java.lang.String getSelfLink() {
1917     java.lang.Object ref = selfLink_;
1918     if (ref instanceof java.lang.String) {
1919       return (java.lang.String) ref;
1920     } else {
1921       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
1922       java.lang.String s = bs.toStringUtf8();
1923       selfLink_ = s;
1924       return s;
1925     }
1926   }
1927   /**
1928    *
1929    *
1930    * <pre>
1931    * [Output Only] Server-defined fully-qualified URL for this resource.
1932    * </pre>
1933    *
1934    * <code>optional string self_link = 456214797;</code>
1935    *
1936    * @return The bytes for selfLink.
1937    */
1938   @java.lang.Override
getSelfLinkBytes()1939   public com.google.protobuf.ByteString getSelfLinkBytes() {
1940     java.lang.Object ref = selfLink_;
1941     if (ref instanceof java.lang.String) {
1942       com.google.protobuf.ByteString b =
1943           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
1944       selfLink_ = b;
1945       return b;
1946     } else {
1947       return (com.google.protobuf.ByteString) ref;
1948     }
1949   }
1950 
1951   public static final int SIZE_GB_FIELD_NUMBER = 494929369;
1952   private long sizeGb_ = 0L;
1953   /**
1954    *
1955    *
1956    * <pre>
1957    * Size, in GB, of the persistent disk. You can specify this field when creating a persistent disk using the sourceImage, sourceSnapshot, or sourceDisk parameter, or specify it alone to create an empty persistent disk. If you specify this field along with a source, the value of sizeGb must not be less than the size of the source. Acceptable values are 1 to 65536, inclusive.
1958    * </pre>
1959    *
1960    * <code>optional int64 size_gb = 494929369;</code>
1961    *
1962    * @return Whether the sizeGb field is set.
1963    */
1964   @java.lang.Override
hasSizeGb()1965   public boolean hasSizeGb() {
1966     return ((bitField0_ & 0x00040000) != 0);
1967   }
1968   /**
1969    *
1970    *
1971    * <pre>
1972    * Size, in GB, of the persistent disk. You can specify this field when creating a persistent disk using the sourceImage, sourceSnapshot, or sourceDisk parameter, or specify it alone to create an empty persistent disk. If you specify this field along with a source, the value of sizeGb must not be less than the size of the source. Acceptable values are 1 to 65536, inclusive.
1973    * </pre>
1974    *
1975    * <code>optional int64 size_gb = 494929369;</code>
1976    *
1977    * @return The sizeGb.
1978    */
1979   @java.lang.Override
getSizeGb()1980   public long getSizeGb() {
1981     return sizeGb_;
1982   }
1983 
1984   public static final int SOURCE_DISK_FIELD_NUMBER = 451753793;
1985 
1986   @SuppressWarnings("serial")
1987   private volatile java.lang.Object sourceDisk_ = "";
1988   /**
1989    *
1990    *
1991    * <pre>
1992    * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
1993    * </pre>
1994    *
1995    * <code>optional string source_disk = 451753793;</code>
1996    *
1997    * @return Whether the sourceDisk field is set.
1998    */
1999   @java.lang.Override
hasSourceDisk()2000   public boolean hasSourceDisk() {
2001     return ((bitField0_ & 0x00080000) != 0);
2002   }
2003   /**
2004    *
2005    *
2006    * <pre>
2007    * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
2008    * </pre>
2009    *
2010    * <code>optional string source_disk = 451753793;</code>
2011    *
2012    * @return The sourceDisk.
2013    */
2014   @java.lang.Override
getSourceDisk()2015   public java.lang.String getSourceDisk() {
2016     java.lang.Object ref = sourceDisk_;
2017     if (ref instanceof java.lang.String) {
2018       return (java.lang.String) ref;
2019     } else {
2020       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2021       java.lang.String s = bs.toStringUtf8();
2022       sourceDisk_ = s;
2023       return s;
2024     }
2025   }
2026   /**
2027    *
2028    *
2029    * <pre>
2030    * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
2031    * </pre>
2032    *
2033    * <code>optional string source_disk = 451753793;</code>
2034    *
2035    * @return The bytes for sourceDisk.
2036    */
2037   @java.lang.Override
getSourceDiskBytes()2038   public com.google.protobuf.ByteString getSourceDiskBytes() {
2039     java.lang.Object ref = sourceDisk_;
2040     if (ref instanceof java.lang.String) {
2041       com.google.protobuf.ByteString b =
2042           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2043       sourceDisk_ = b;
2044       return b;
2045     } else {
2046       return (com.google.protobuf.ByteString) ref;
2047     }
2048   }
2049 
2050   public static final int SOURCE_DISK_ID_FIELD_NUMBER = 454190809;
2051 
2052   @SuppressWarnings("serial")
2053   private volatile java.lang.Object sourceDiskId_ = "";
2054   /**
2055    *
2056    *
2057    * <pre>
2058    * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
2059    * </pre>
2060    *
2061    * <code>optional string source_disk_id = 454190809;</code>
2062    *
2063    * @return Whether the sourceDiskId field is set.
2064    */
2065   @java.lang.Override
hasSourceDiskId()2066   public boolean hasSourceDiskId() {
2067     return ((bitField0_ & 0x00100000) != 0);
2068   }
2069   /**
2070    *
2071    *
2072    * <pre>
2073    * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
2074    * </pre>
2075    *
2076    * <code>optional string source_disk_id = 454190809;</code>
2077    *
2078    * @return The sourceDiskId.
2079    */
2080   @java.lang.Override
getSourceDiskId()2081   public java.lang.String getSourceDiskId() {
2082     java.lang.Object ref = sourceDiskId_;
2083     if (ref instanceof java.lang.String) {
2084       return (java.lang.String) ref;
2085     } else {
2086       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2087       java.lang.String s = bs.toStringUtf8();
2088       sourceDiskId_ = s;
2089       return s;
2090     }
2091   }
2092   /**
2093    *
2094    *
2095    * <pre>
2096    * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
2097    * </pre>
2098    *
2099    * <code>optional string source_disk_id = 454190809;</code>
2100    *
2101    * @return The bytes for sourceDiskId.
2102    */
2103   @java.lang.Override
getSourceDiskIdBytes()2104   public com.google.protobuf.ByteString getSourceDiskIdBytes() {
2105     java.lang.Object ref = sourceDiskId_;
2106     if (ref instanceof java.lang.String) {
2107       com.google.protobuf.ByteString b =
2108           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2109       sourceDiskId_ = b;
2110       return b;
2111     } else {
2112       return (com.google.protobuf.ByteString) ref;
2113     }
2114   }
2115 
2116   public static final int SOURCE_IMAGE_FIELD_NUMBER = 50443319;
2117 
2118   @SuppressWarnings("serial")
2119   private volatile java.lang.Object sourceImage_ = "";
2120   /**
2121    *
2122    *
2123    * <pre>
2124    * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
2125    * </pre>
2126    *
2127    * <code>optional string source_image = 50443319;</code>
2128    *
2129    * @return Whether the sourceImage field is set.
2130    */
2131   @java.lang.Override
hasSourceImage()2132   public boolean hasSourceImage() {
2133     return ((bitField0_ & 0x00200000) != 0);
2134   }
2135   /**
2136    *
2137    *
2138    * <pre>
2139    * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
2140    * </pre>
2141    *
2142    * <code>optional string source_image = 50443319;</code>
2143    *
2144    * @return The sourceImage.
2145    */
2146   @java.lang.Override
getSourceImage()2147   public java.lang.String getSourceImage() {
2148     java.lang.Object ref = sourceImage_;
2149     if (ref instanceof java.lang.String) {
2150       return (java.lang.String) ref;
2151     } else {
2152       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2153       java.lang.String s = bs.toStringUtf8();
2154       sourceImage_ = s;
2155       return s;
2156     }
2157   }
2158   /**
2159    *
2160    *
2161    * <pre>
2162    * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
2163    * </pre>
2164    *
2165    * <code>optional string source_image = 50443319;</code>
2166    *
2167    * @return The bytes for sourceImage.
2168    */
2169   @java.lang.Override
getSourceImageBytes()2170   public com.google.protobuf.ByteString getSourceImageBytes() {
2171     java.lang.Object ref = sourceImage_;
2172     if (ref instanceof java.lang.String) {
2173       com.google.protobuf.ByteString b =
2174           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2175       sourceImage_ = b;
2176       return b;
2177     } else {
2178       return (com.google.protobuf.ByteString) ref;
2179     }
2180   }
2181 
2182   public static final int SOURCE_IMAGE_ENCRYPTION_KEY_FIELD_NUMBER = 381503659;
2183   private com.google.cloud.compute.v1.CustomerEncryptionKey sourceImageEncryptionKey_;
2184   /**
2185    *
2186    *
2187    * <pre>
2188    * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
2189    * </pre>
2190    *
2191    * <code>
2192    * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
2193    * </code>
2194    *
2195    * @return Whether the sourceImageEncryptionKey field is set.
2196    */
2197   @java.lang.Override
hasSourceImageEncryptionKey()2198   public boolean hasSourceImageEncryptionKey() {
2199     return ((bitField0_ & 0x00400000) != 0);
2200   }
2201   /**
2202    *
2203    *
2204    * <pre>
2205    * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
2206    * </pre>
2207    *
2208    * <code>
2209    * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
2210    * </code>
2211    *
2212    * @return The sourceImageEncryptionKey.
2213    */
2214   @java.lang.Override
getSourceImageEncryptionKey()2215   public com.google.cloud.compute.v1.CustomerEncryptionKey getSourceImageEncryptionKey() {
2216     return sourceImageEncryptionKey_ == null
2217         ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
2218         : sourceImageEncryptionKey_;
2219   }
2220   /**
2221    *
2222    *
2223    * <pre>
2224    * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
2225    * </pre>
2226    *
2227    * <code>
2228    * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
2229    * </code>
2230    */
2231   @java.lang.Override
2232   public com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder
getSourceImageEncryptionKeyOrBuilder()2233       getSourceImageEncryptionKeyOrBuilder() {
2234     return sourceImageEncryptionKey_ == null
2235         ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
2236         : sourceImageEncryptionKey_;
2237   }
2238 
2239   public static final int SOURCE_IMAGE_ID_FIELD_NUMBER = 55328291;
2240 
2241   @SuppressWarnings("serial")
2242   private volatile java.lang.Object sourceImageId_ = "";
2243   /**
2244    *
2245    *
2246    * <pre>
2247    * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
2248    * </pre>
2249    *
2250    * <code>optional string source_image_id = 55328291;</code>
2251    *
2252    * @return Whether the sourceImageId field is set.
2253    */
2254   @java.lang.Override
hasSourceImageId()2255   public boolean hasSourceImageId() {
2256     return ((bitField0_ & 0x00800000) != 0);
2257   }
2258   /**
2259    *
2260    *
2261    * <pre>
2262    * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
2263    * </pre>
2264    *
2265    * <code>optional string source_image_id = 55328291;</code>
2266    *
2267    * @return The sourceImageId.
2268    */
2269   @java.lang.Override
getSourceImageId()2270   public java.lang.String getSourceImageId() {
2271     java.lang.Object ref = sourceImageId_;
2272     if (ref instanceof java.lang.String) {
2273       return (java.lang.String) ref;
2274     } else {
2275       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2276       java.lang.String s = bs.toStringUtf8();
2277       sourceImageId_ = s;
2278       return s;
2279     }
2280   }
2281   /**
2282    *
2283    *
2284    * <pre>
2285    * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
2286    * </pre>
2287    *
2288    * <code>optional string source_image_id = 55328291;</code>
2289    *
2290    * @return The bytes for sourceImageId.
2291    */
2292   @java.lang.Override
getSourceImageIdBytes()2293   public com.google.protobuf.ByteString getSourceImageIdBytes() {
2294     java.lang.Object ref = sourceImageId_;
2295     if (ref instanceof java.lang.String) {
2296       com.google.protobuf.ByteString b =
2297           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2298       sourceImageId_ = b;
2299       return b;
2300     } else {
2301       return (com.google.protobuf.ByteString) ref;
2302     }
2303   }
2304 
2305   public static final int SOURCE_SNAPSHOT_FIELD_NUMBER = 126061928;
2306 
2307   @SuppressWarnings("serial")
2308   private volatile java.lang.Object sourceSnapshot_ = "";
2309   /**
2310    *
2311    *
2312    * <pre>
2313    * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
2314    * </pre>
2315    *
2316    * <code>optional string source_snapshot = 126061928;</code>
2317    *
2318    * @return Whether the sourceSnapshot field is set.
2319    */
2320   @java.lang.Override
hasSourceSnapshot()2321   public boolean hasSourceSnapshot() {
2322     return ((bitField0_ & 0x01000000) != 0);
2323   }
2324   /**
2325    *
2326    *
2327    * <pre>
2328    * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
2329    * </pre>
2330    *
2331    * <code>optional string source_snapshot = 126061928;</code>
2332    *
2333    * @return The sourceSnapshot.
2334    */
2335   @java.lang.Override
getSourceSnapshot()2336   public java.lang.String getSourceSnapshot() {
2337     java.lang.Object ref = sourceSnapshot_;
2338     if (ref instanceof java.lang.String) {
2339       return (java.lang.String) ref;
2340     } else {
2341       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2342       java.lang.String s = bs.toStringUtf8();
2343       sourceSnapshot_ = s;
2344       return s;
2345     }
2346   }
2347   /**
2348    *
2349    *
2350    * <pre>
2351    * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
2352    * </pre>
2353    *
2354    * <code>optional string source_snapshot = 126061928;</code>
2355    *
2356    * @return The bytes for sourceSnapshot.
2357    */
2358   @java.lang.Override
getSourceSnapshotBytes()2359   public com.google.protobuf.ByteString getSourceSnapshotBytes() {
2360     java.lang.Object ref = sourceSnapshot_;
2361     if (ref instanceof java.lang.String) {
2362       com.google.protobuf.ByteString b =
2363           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2364       sourceSnapshot_ = b;
2365       return b;
2366     } else {
2367       return (com.google.protobuf.ByteString) ref;
2368     }
2369   }
2370 
2371   public static final int SOURCE_SNAPSHOT_ENCRYPTION_KEY_FIELD_NUMBER = 303679322;
2372   private com.google.cloud.compute.v1.CustomerEncryptionKey sourceSnapshotEncryptionKey_;
2373   /**
2374    *
2375    *
2376    * <pre>
2377    * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
2378    * </pre>
2379    *
2380    * <code>
2381    * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
2382    * </code>
2383    *
2384    * @return Whether the sourceSnapshotEncryptionKey field is set.
2385    */
2386   @java.lang.Override
hasSourceSnapshotEncryptionKey()2387   public boolean hasSourceSnapshotEncryptionKey() {
2388     return ((bitField0_ & 0x02000000) != 0);
2389   }
2390   /**
2391    *
2392    *
2393    * <pre>
2394    * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
2395    * </pre>
2396    *
2397    * <code>
2398    * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
2399    * </code>
2400    *
2401    * @return The sourceSnapshotEncryptionKey.
2402    */
2403   @java.lang.Override
getSourceSnapshotEncryptionKey()2404   public com.google.cloud.compute.v1.CustomerEncryptionKey getSourceSnapshotEncryptionKey() {
2405     return sourceSnapshotEncryptionKey_ == null
2406         ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
2407         : sourceSnapshotEncryptionKey_;
2408   }
2409   /**
2410    *
2411    *
2412    * <pre>
2413    * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
2414    * </pre>
2415    *
2416    * <code>
2417    * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
2418    * </code>
2419    */
2420   @java.lang.Override
2421   public com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder
getSourceSnapshotEncryptionKeyOrBuilder()2422       getSourceSnapshotEncryptionKeyOrBuilder() {
2423     return sourceSnapshotEncryptionKey_ == null
2424         ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
2425         : sourceSnapshotEncryptionKey_;
2426   }
2427 
2428   public static final int SOURCE_SNAPSHOT_ID_FIELD_NUMBER = 98962258;
2429 
2430   @SuppressWarnings("serial")
2431   private volatile java.lang.Object sourceSnapshotId_ = "";
2432   /**
2433    *
2434    *
2435    * <pre>
2436    * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
2437    * </pre>
2438    *
2439    * <code>optional string source_snapshot_id = 98962258;</code>
2440    *
2441    * @return Whether the sourceSnapshotId field is set.
2442    */
2443   @java.lang.Override
hasSourceSnapshotId()2444   public boolean hasSourceSnapshotId() {
2445     return ((bitField0_ & 0x04000000) != 0);
2446   }
2447   /**
2448    *
2449    *
2450    * <pre>
2451    * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
2452    * </pre>
2453    *
2454    * <code>optional string source_snapshot_id = 98962258;</code>
2455    *
2456    * @return The sourceSnapshotId.
2457    */
2458   @java.lang.Override
getSourceSnapshotId()2459   public java.lang.String getSourceSnapshotId() {
2460     java.lang.Object ref = sourceSnapshotId_;
2461     if (ref instanceof java.lang.String) {
2462       return (java.lang.String) ref;
2463     } else {
2464       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2465       java.lang.String s = bs.toStringUtf8();
2466       sourceSnapshotId_ = s;
2467       return s;
2468     }
2469   }
2470   /**
2471    *
2472    *
2473    * <pre>
2474    * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
2475    * </pre>
2476    *
2477    * <code>optional string source_snapshot_id = 98962258;</code>
2478    *
2479    * @return The bytes for sourceSnapshotId.
2480    */
2481   @java.lang.Override
getSourceSnapshotIdBytes()2482   public com.google.protobuf.ByteString getSourceSnapshotIdBytes() {
2483     java.lang.Object ref = sourceSnapshotId_;
2484     if (ref instanceof java.lang.String) {
2485       com.google.protobuf.ByteString b =
2486           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2487       sourceSnapshotId_ = b;
2488       return b;
2489     } else {
2490       return (com.google.protobuf.ByteString) ref;
2491     }
2492   }
2493 
2494   public static final int SOURCE_STORAGE_OBJECT_FIELD_NUMBER = 233052711;
2495 
2496   @SuppressWarnings("serial")
2497   private volatile java.lang.Object sourceStorageObject_ = "";
2498   /**
2499    *
2500    *
2501    * <pre>
2502    * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
2503    * </pre>
2504    *
2505    * <code>optional string source_storage_object = 233052711;</code>
2506    *
2507    * @return Whether the sourceStorageObject field is set.
2508    */
2509   @java.lang.Override
hasSourceStorageObject()2510   public boolean hasSourceStorageObject() {
2511     return ((bitField0_ & 0x08000000) != 0);
2512   }
2513   /**
2514    *
2515    *
2516    * <pre>
2517    * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
2518    * </pre>
2519    *
2520    * <code>optional string source_storage_object = 233052711;</code>
2521    *
2522    * @return The sourceStorageObject.
2523    */
2524   @java.lang.Override
getSourceStorageObject()2525   public java.lang.String getSourceStorageObject() {
2526     java.lang.Object ref = sourceStorageObject_;
2527     if (ref instanceof java.lang.String) {
2528       return (java.lang.String) ref;
2529     } else {
2530       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2531       java.lang.String s = bs.toStringUtf8();
2532       sourceStorageObject_ = s;
2533       return s;
2534     }
2535   }
2536   /**
2537    *
2538    *
2539    * <pre>
2540    * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
2541    * </pre>
2542    *
2543    * <code>optional string source_storage_object = 233052711;</code>
2544    *
2545    * @return The bytes for sourceStorageObject.
2546    */
2547   @java.lang.Override
getSourceStorageObjectBytes()2548   public com.google.protobuf.ByteString getSourceStorageObjectBytes() {
2549     java.lang.Object ref = sourceStorageObject_;
2550     if (ref instanceof java.lang.String) {
2551       com.google.protobuf.ByteString b =
2552           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2553       sourceStorageObject_ = b;
2554       return b;
2555     } else {
2556       return (com.google.protobuf.ByteString) ref;
2557     }
2558   }
2559 
2560   public static final int STATUS_FIELD_NUMBER = 181260274;
2561 
2562   @SuppressWarnings("serial")
2563   private volatile java.lang.Object status_ = "";
2564   /**
2565    *
2566    *
2567    * <pre>
2568    * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
2569    * Check the Status enum for the list of possible values.
2570    * </pre>
2571    *
2572    * <code>optional string status = 181260274;</code>
2573    *
2574    * @return Whether the status field is set.
2575    */
2576   @java.lang.Override
hasStatus()2577   public boolean hasStatus() {
2578     return ((bitField0_ & 0x10000000) != 0);
2579   }
2580   /**
2581    *
2582    *
2583    * <pre>
2584    * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
2585    * Check the Status enum for the list of possible values.
2586    * </pre>
2587    *
2588    * <code>optional string status = 181260274;</code>
2589    *
2590    * @return The status.
2591    */
2592   @java.lang.Override
getStatus()2593   public java.lang.String getStatus() {
2594     java.lang.Object ref = status_;
2595     if (ref instanceof java.lang.String) {
2596       return (java.lang.String) ref;
2597     } else {
2598       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2599       java.lang.String s = bs.toStringUtf8();
2600       status_ = s;
2601       return s;
2602     }
2603   }
2604   /**
2605    *
2606    *
2607    * <pre>
2608    * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
2609    * Check the Status enum for the list of possible values.
2610    * </pre>
2611    *
2612    * <code>optional string status = 181260274;</code>
2613    *
2614    * @return The bytes for status.
2615    */
2616   @java.lang.Override
getStatusBytes()2617   public com.google.protobuf.ByteString getStatusBytes() {
2618     java.lang.Object ref = status_;
2619     if (ref instanceof java.lang.String) {
2620       com.google.protobuf.ByteString b =
2621           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2622       status_ = b;
2623       return b;
2624     } else {
2625       return (com.google.protobuf.ByteString) ref;
2626     }
2627   }
2628 
2629   public static final int TYPE_FIELD_NUMBER = 3575610;
2630 
2631   @SuppressWarnings("serial")
2632   private volatile java.lang.Object type_ = "";
2633   /**
2634    *
2635    *
2636    * <pre>
2637    * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
2638    * </pre>
2639    *
2640    * <code>optional string type = 3575610;</code>
2641    *
2642    * @return Whether the type field is set.
2643    */
2644   @java.lang.Override
hasType()2645   public boolean hasType() {
2646     return ((bitField0_ & 0x20000000) != 0);
2647   }
2648   /**
2649    *
2650    *
2651    * <pre>
2652    * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
2653    * </pre>
2654    *
2655    * <code>optional string type = 3575610;</code>
2656    *
2657    * @return The type.
2658    */
2659   @java.lang.Override
getType()2660   public java.lang.String getType() {
2661     java.lang.Object ref = type_;
2662     if (ref instanceof java.lang.String) {
2663       return (java.lang.String) ref;
2664     } else {
2665       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2666       java.lang.String s = bs.toStringUtf8();
2667       type_ = s;
2668       return s;
2669     }
2670   }
2671   /**
2672    *
2673    *
2674    * <pre>
2675    * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
2676    * </pre>
2677    *
2678    * <code>optional string type = 3575610;</code>
2679    *
2680    * @return The bytes for type.
2681    */
2682   @java.lang.Override
getTypeBytes()2683   public com.google.protobuf.ByteString getTypeBytes() {
2684     java.lang.Object ref = type_;
2685     if (ref instanceof java.lang.String) {
2686       com.google.protobuf.ByteString b =
2687           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2688       type_ = b;
2689       return b;
2690     } else {
2691       return (com.google.protobuf.ByteString) ref;
2692     }
2693   }
2694 
2695   public static final int USERS_FIELD_NUMBER = 111578632;
2696 
2697   @SuppressWarnings("serial")
2698   private com.google.protobuf.LazyStringList users_;
2699   /**
2700    *
2701    *
2702    * <pre>
2703    * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
2704    * </pre>
2705    *
2706    * <code>repeated string users = 111578632;</code>
2707    *
2708    * @return A list containing the users.
2709    */
getUsersList()2710   public com.google.protobuf.ProtocolStringList getUsersList() {
2711     return users_;
2712   }
2713   /**
2714    *
2715    *
2716    * <pre>
2717    * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
2718    * </pre>
2719    *
2720    * <code>repeated string users = 111578632;</code>
2721    *
2722    * @return The count of users.
2723    */
getUsersCount()2724   public int getUsersCount() {
2725     return users_.size();
2726   }
2727   /**
2728    *
2729    *
2730    * <pre>
2731    * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
2732    * </pre>
2733    *
2734    * <code>repeated string users = 111578632;</code>
2735    *
2736    * @param index The index of the element to return.
2737    * @return The users at the given index.
2738    */
getUsers(int index)2739   public java.lang.String getUsers(int index) {
2740     return users_.get(index);
2741   }
2742   /**
2743    *
2744    *
2745    * <pre>
2746    * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
2747    * </pre>
2748    *
2749    * <code>repeated string users = 111578632;</code>
2750    *
2751    * @param index The index of the value to return.
2752    * @return The bytes of the users at the given index.
2753    */
getUsersBytes(int index)2754   public com.google.protobuf.ByteString getUsersBytes(int index) {
2755     return users_.getByteString(index);
2756   }
2757 
2758   public static final int ZONE_FIELD_NUMBER = 3744684;
2759 
2760   @SuppressWarnings("serial")
2761   private volatile java.lang.Object zone_ = "";
2762   /**
2763    *
2764    *
2765    * <pre>
2766    * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
2767    * </pre>
2768    *
2769    * <code>optional string zone = 3744684;</code>
2770    *
2771    * @return Whether the zone field is set.
2772    */
2773   @java.lang.Override
hasZone()2774   public boolean hasZone() {
2775     return ((bitField0_ & 0x40000000) != 0);
2776   }
2777   /**
2778    *
2779    *
2780    * <pre>
2781    * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
2782    * </pre>
2783    *
2784    * <code>optional string zone = 3744684;</code>
2785    *
2786    * @return The zone.
2787    */
2788   @java.lang.Override
getZone()2789   public java.lang.String getZone() {
2790     java.lang.Object ref = zone_;
2791     if (ref instanceof java.lang.String) {
2792       return (java.lang.String) ref;
2793     } else {
2794       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
2795       java.lang.String s = bs.toStringUtf8();
2796       zone_ = s;
2797       return s;
2798     }
2799   }
2800   /**
2801    *
2802    *
2803    * <pre>
2804    * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
2805    * </pre>
2806    *
2807    * <code>optional string zone = 3744684;</code>
2808    *
2809    * @return The bytes for zone.
2810    */
2811   @java.lang.Override
getZoneBytes()2812   public com.google.protobuf.ByteString getZoneBytes() {
2813     java.lang.Object ref = zone_;
2814     if (ref instanceof java.lang.String) {
2815       com.google.protobuf.ByteString b =
2816           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
2817       zone_ = b;
2818       return b;
2819     } else {
2820       return (com.google.protobuf.ByteString) ref;
2821     }
2822   }
2823 
2824   private byte memoizedIsInitialized = -1;
2825 
2826   @java.lang.Override
isInitialized()2827   public final boolean isInitialized() {
2828     byte isInitialized = memoizedIsInitialized;
2829     if (isInitialized == 1) return true;
2830     if (isInitialized == 0) return false;
2831 
2832     memoizedIsInitialized = 1;
2833     return true;
2834   }
2835 
2836   @java.lang.Override
writeTo(com.google.protobuf.CodedOutputStream output)2837   public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
2838     getSerializedSize();
2839     if (((bitField0_ & 0x00000010) != 0)) {
2840       output.writeUInt64(3355, id_);
2841     }
2842     if (((bitField0_ & 0x00000020) != 0)) {
2843       com.google.protobuf.GeneratedMessageV3.writeString(output, 3292052, kind_);
2844     }
2845     if (((bitField0_ & 0x00000400) != 0)) {
2846       com.google.protobuf.GeneratedMessageV3.writeString(output, 3373707, name_);
2847     }
2848     if (((bitField0_ & 0x20000000) != 0)) {
2849       com.google.protobuf.GeneratedMessageV3.writeString(output, 3575610, type_);
2850     }
2851     if (((bitField0_ & 0x40000000) != 0)) {
2852       com.google.protobuf.GeneratedMessageV3.writeString(output, 3744684, zone_);
2853     }
2854     for (int i = 0; i < resourcePolicies_.size(); i++) {
2855       com.google.protobuf.GeneratedMessageV3.writeString(
2856           output, 22220385, resourcePolicies_.getRaw(i));
2857     }
2858     if (((bitField0_ & 0x00000002) != 0)) {
2859       com.google.protobuf.GeneratedMessageV3.writeString(output, 30525366, creationTimestamp_);
2860     }
2861     if (((bitField0_ & 0x00000080) != 0)) {
2862       com.google.protobuf.GeneratedMessageV3.writeString(output, 42159653, lastAttachTimestamp_);
2863     }
2864     if (getLicenseCodesList().size() > 0) {
2865       output.writeUInt32NoTag(363861314);
2866       output.writeUInt32NoTag(licenseCodesMemoizedSerializedSize);
2867     }
2868     for (int i = 0; i < licenseCodes_.size(); i++) {
2869       output.writeInt64NoTag(licenseCodes_.getLong(i));
2870     }
2871     for (int i = 0; i < replicaZones_.size(); i++) {
2872       com.google.protobuf.GeneratedMessageV3.writeString(output, 48438272, replicaZones_.getRaw(i));
2873     }
2874     if (((bitField0_ & 0x00200000) != 0)) {
2875       com.google.protobuf.GeneratedMessageV3.writeString(output, 50443319, sourceImage_);
2876     }
2877     if (((bitField0_ & 0x00800000) != 0)) {
2878       com.google.protobuf.GeneratedMessageV3.writeString(output, 55328291, sourceImageId_);
2879     }
2880     if (((bitField0_ & 0x00000100) != 0)) {
2881       com.google.protobuf.GeneratedMessageV3.writeString(output, 56471027, lastDetachTimestamp_);
2882     }
2883     if (((bitField0_ & 0x00001000) != 0)) {
2884       output.writeMessage(78313862, getParams());
2885     }
2886     for (int i = 0; i < guestOsFeatures_.size(); i++) {
2887       output.writeMessage(79294545, guestOsFeatures_.get(i));
2888     }
2889     if (((bitField0_ & 0x04000000) != 0)) {
2890       com.google.protobuf.GeneratedMessageV3.writeString(output, 98962258, sourceSnapshotId_);
2891     }
2892     for (int i = 0; i < users_.size(); i++) {
2893       com.google.protobuf.GeneratedMessageV3.writeString(output, 111578632, users_.getRaw(i));
2894     }
2895     if (((bitField0_ & 0x01000000) != 0)) {
2896       com.google.protobuf.GeneratedMessageV3.writeString(output, 126061928, sourceSnapshot_);
2897     }
2898     if (((bitField0_ & 0x00008000) != 0)) {
2899       com.google.protobuf.GeneratedMessageV3.writeString(output, 138946292, region_);
2900     }
2901     if (((bitField0_ & 0x00000040) != 0)) {
2902       com.google.protobuf.GeneratedMessageV3.writeString(output, 178124825, labelFingerprint_);
2903     }
2904     if (((bitField0_ & 0x10000000) != 0)) {
2905       com.google.protobuf.GeneratedMessageV3.writeString(output, 181260274, status_);
2906     }
2907     if (((bitField0_ & 0x00004000) != 0)) {
2908       output.writeInt64(186769108, provisionedIops_);
2909     }
2910     if (((bitField0_ & 0x08000000) != 0)) {
2911       com.google.protobuf.GeneratedMessageV3.writeString(output, 233052711, sourceStorageObject_);
2912     }
2913     if (((bitField0_ & 0x00000008) != 0)) {
2914       output.writeMessage(271660677, getDiskEncryptionKey());
2915     }
2916     if (((bitField0_ & 0x00000001) != 0)) {
2917       com.google.protobuf.GeneratedMessageV3.writeString(output, 302803283, architecture_);
2918     }
2919     if (((bitField0_ & 0x02000000) != 0)) {
2920       output.writeMessage(303679322, getSourceSnapshotEncryptionKey());
2921     }
2922     for (int i = 0; i < licenses_.size(); i++) {
2923       com.google.protobuf.GeneratedMessageV3.writeString(output, 337642578, licenses_.getRaw(i));
2924     }
2925     if (((bitField0_ & 0x00000200) != 0)) {
2926       com.google.protobuf.GeneratedMessageV3.writeString(output, 350519505, locationHint_);
2927     }
2928     if (((bitField0_ & 0x00000800) != 0)) {
2929       com.google.protobuf.GeneratedMessageV3.writeString(output, 361137822, options_);
2930     }
2931     if (((bitField0_ & 0x00400000) != 0)) {
2932       output.writeMessage(381503659, getSourceImageEncryptionKey());
2933     }
2934     if (((bitField0_ & 0x00002000) != 0)) {
2935       output.writeInt64(420007943, physicalBlockSizeBytes_);
2936     }
2937     if (((bitField0_ & 0x00000004) != 0)) {
2938       com.google.protobuf.GeneratedMessageV3.writeString(output, 422937596, description_);
2939     }
2940     if (((bitField0_ & 0x00080000) != 0)) {
2941       com.google.protobuf.GeneratedMessageV3.writeString(output, 451753793, sourceDisk_);
2942     }
2943     if (((bitField0_ & 0x00100000) != 0)) {
2944       com.google.protobuf.GeneratedMessageV3.writeString(output, 454190809, sourceDiskId_);
2945     }
2946     if (((bitField0_ & 0x00020000) != 0)) {
2947       com.google.protobuf.GeneratedMessageV3.writeString(output, 456214797, selfLink_);
2948     }
2949     if (((bitField0_ & 0x00010000) != 0)) {
2950       output.writeBool(480964267, satisfiesPzs_);
2951     }
2952     if (((bitField0_ & 0x00040000) != 0)) {
2953       output.writeInt64(494929369, sizeGb_);
2954     }
2955     com.google.protobuf.GeneratedMessageV3.serializeStringMapTo(
2956         output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 500195327);
2957     getUnknownFields().writeTo(output);
2958   }
2959 
2960   @java.lang.Override
getSerializedSize()2961   public int getSerializedSize() {
2962     int size = memoizedSize;
2963     if (size != -1) return size;
2964 
2965     size = 0;
2966     if (((bitField0_ & 0x00000010) != 0)) {
2967       size += com.google.protobuf.CodedOutputStream.computeUInt64Size(3355, id_);
2968     }
2969     if (((bitField0_ & 0x00000020) != 0)) {
2970       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3292052, kind_);
2971     }
2972     if (((bitField0_ & 0x00000400) != 0)) {
2973       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3373707, name_);
2974     }
2975     if (((bitField0_ & 0x20000000) != 0)) {
2976       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3575610, type_);
2977     }
2978     if (((bitField0_ & 0x40000000) != 0)) {
2979       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3744684, zone_);
2980     }
2981     {
2982       int dataSize = 0;
2983       for (int i = 0; i < resourcePolicies_.size(); i++) {
2984         dataSize += computeStringSizeNoTag(resourcePolicies_.getRaw(i));
2985       }
2986       size += dataSize;
2987       size += 4 * getResourcePoliciesList().size();
2988     }
2989     if (((bitField0_ & 0x00000002) != 0)) {
2990       size +=
2991           com.google.protobuf.GeneratedMessageV3.computeStringSize(30525366, creationTimestamp_);
2992     }
2993     if (((bitField0_ & 0x00000080) != 0)) {
2994       size +=
2995           com.google.protobuf.GeneratedMessageV3.computeStringSize(42159653, lastAttachTimestamp_);
2996     }
2997     {
2998       int dataSize = 0;
2999       for (int i = 0; i < licenseCodes_.size(); i++) {
3000         dataSize +=
3001             com.google.protobuf.CodedOutputStream.computeInt64SizeNoTag(licenseCodes_.getLong(i));
3002       }
3003       size += dataSize;
3004       if (!getLicenseCodesList().isEmpty()) {
3005         size += 5;
3006         size += com.google.protobuf.CodedOutputStream.computeInt32SizeNoTag(dataSize);
3007       }
3008       licenseCodesMemoizedSerializedSize = dataSize;
3009     }
3010     {
3011       int dataSize = 0;
3012       for (int i = 0; i < replicaZones_.size(); i++) {
3013         dataSize += computeStringSizeNoTag(replicaZones_.getRaw(i));
3014       }
3015       size += dataSize;
3016       size += 5 * getReplicaZonesList().size();
3017     }
3018     if (((bitField0_ & 0x00200000) != 0)) {
3019       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(50443319, sourceImage_);
3020     }
3021     if (((bitField0_ & 0x00800000) != 0)) {
3022       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(55328291, sourceImageId_);
3023     }
3024     if (((bitField0_ & 0x00000100) != 0)) {
3025       size +=
3026           com.google.protobuf.GeneratedMessageV3.computeStringSize(56471027, lastDetachTimestamp_);
3027     }
3028     if (((bitField0_ & 0x00001000) != 0)) {
3029       size += com.google.protobuf.CodedOutputStream.computeMessageSize(78313862, getParams());
3030     }
3031     for (int i = 0; i < guestOsFeatures_.size(); i++) {
3032       size +=
3033           com.google.protobuf.CodedOutputStream.computeMessageSize(
3034               79294545, guestOsFeatures_.get(i));
3035     }
3036     if (((bitField0_ & 0x04000000) != 0)) {
3037       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(98962258, sourceSnapshotId_);
3038     }
3039     {
3040       int dataSize = 0;
3041       for (int i = 0; i < users_.size(); i++) {
3042         dataSize += computeStringSizeNoTag(users_.getRaw(i));
3043       }
3044       size += dataSize;
3045       size += 5 * getUsersList().size();
3046     }
3047     if (((bitField0_ & 0x01000000) != 0)) {
3048       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(126061928, sourceSnapshot_);
3049     }
3050     if (((bitField0_ & 0x00008000) != 0)) {
3051       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(138946292, region_);
3052     }
3053     if (((bitField0_ & 0x00000040) != 0)) {
3054       size +=
3055           com.google.protobuf.GeneratedMessageV3.computeStringSize(178124825, labelFingerprint_);
3056     }
3057     if (((bitField0_ & 0x10000000) != 0)) {
3058       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(181260274, status_);
3059     }
3060     if (((bitField0_ & 0x00004000) != 0)) {
3061       size += com.google.protobuf.CodedOutputStream.computeInt64Size(186769108, provisionedIops_);
3062     }
3063     if (((bitField0_ & 0x08000000) != 0)) {
3064       size +=
3065           com.google.protobuf.GeneratedMessageV3.computeStringSize(233052711, sourceStorageObject_);
3066     }
3067     if (((bitField0_ & 0x00000008) != 0)) {
3068       size +=
3069           com.google.protobuf.CodedOutputStream.computeMessageSize(
3070               271660677, getDiskEncryptionKey());
3071     }
3072     if (((bitField0_ & 0x00000001) != 0)) {
3073       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(302803283, architecture_);
3074     }
3075     if (((bitField0_ & 0x02000000) != 0)) {
3076       size +=
3077           com.google.protobuf.CodedOutputStream.computeMessageSize(
3078               303679322, getSourceSnapshotEncryptionKey());
3079     }
3080     {
3081       int dataSize = 0;
3082       for (int i = 0; i < licenses_.size(); i++) {
3083         dataSize += computeStringSizeNoTag(licenses_.getRaw(i));
3084       }
3085       size += dataSize;
3086       size += 5 * getLicensesList().size();
3087     }
3088     if (((bitField0_ & 0x00000200) != 0)) {
3089       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(350519505, locationHint_);
3090     }
3091     if (((bitField0_ & 0x00000800) != 0)) {
3092       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(361137822, options_);
3093     }
3094     if (((bitField0_ & 0x00400000) != 0)) {
3095       size +=
3096           com.google.protobuf.CodedOutputStream.computeMessageSize(
3097               381503659, getSourceImageEncryptionKey());
3098     }
3099     if (((bitField0_ & 0x00002000) != 0)) {
3100       size +=
3101           com.google.protobuf.CodedOutputStream.computeInt64Size(
3102               420007943, physicalBlockSizeBytes_);
3103     }
3104     if (((bitField0_ & 0x00000004) != 0)) {
3105       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(422937596, description_);
3106     }
3107     if (((bitField0_ & 0x00080000) != 0)) {
3108       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(451753793, sourceDisk_);
3109     }
3110     if (((bitField0_ & 0x00100000) != 0)) {
3111       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(454190809, sourceDiskId_);
3112     }
3113     if (((bitField0_ & 0x00020000) != 0)) {
3114       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(456214797, selfLink_);
3115     }
3116     if (((bitField0_ & 0x00010000) != 0)) {
3117       size += com.google.protobuf.CodedOutputStream.computeBoolSize(480964267, satisfiesPzs_);
3118     }
3119     if (((bitField0_ & 0x00040000) != 0)) {
3120       size += com.google.protobuf.CodedOutputStream.computeInt64Size(494929369, sizeGb_);
3121     }
3122     for (java.util.Map.Entry<java.lang.String, java.lang.String> entry :
3123         internalGetLabels().getMap().entrySet()) {
3124       com.google.protobuf.MapEntry<java.lang.String, java.lang.String> labels__ =
3125           LabelsDefaultEntryHolder.defaultEntry
3126               .newBuilderForType()
3127               .setKey(entry.getKey())
3128               .setValue(entry.getValue())
3129               .build();
3130       size += com.google.protobuf.CodedOutputStream.computeMessageSize(500195327, labels__);
3131     }
3132     size += getUnknownFields().getSerializedSize();
3133     memoizedSize = size;
3134     return size;
3135   }
3136 
3137   @java.lang.Override
equals(final java.lang.Object obj)3138   public boolean equals(final java.lang.Object obj) {
3139     if (obj == this) {
3140       return true;
3141     }
3142     if (!(obj instanceof com.google.cloud.compute.v1.Disk)) {
3143       return super.equals(obj);
3144     }
3145     com.google.cloud.compute.v1.Disk other = (com.google.cloud.compute.v1.Disk) obj;
3146 
3147     if (hasArchitecture() != other.hasArchitecture()) return false;
3148     if (hasArchitecture()) {
3149       if (!getArchitecture().equals(other.getArchitecture())) return false;
3150     }
3151     if (hasCreationTimestamp() != other.hasCreationTimestamp()) return false;
3152     if (hasCreationTimestamp()) {
3153       if (!getCreationTimestamp().equals(other.getCreationTimestamp())) return false;
3154     }
3155     if (hasDescription() != other.hasDescription()) return false;
3156     if (hasDescription()) {
3157       if (!getDescription().equals(other.getDescription())) return false;
3158     }
3159     if (hasDiskEncryptionKey() != other.hasDiskEncryptionKey()) return false;
3160     if (hasDiskEncryptionKey()) {
3161       if (!getDiskEncryptionKey().equals(other.getDiskEncryptionKey())) return false;
3162     }
3163     if (!getGuestOsFeaturesList().equals(other.getGuestOsFeaturesList())) return false;
3164     if (hasId() != other.hasId()) return false;
3165     if (hasId()) {
3166       if (getId() != other.getId()) return false;
3167     }
3168     if (hasKind() != other.hasKind()) return false;
3169     if (hasKind()) {
3170       if (!getKind().equals(other.getKind())) return false;
3171     }
3172     if (hasLabelFingerprint() != other.hasLabelFingerprint()) return false;
3173     if (hasLabelFingerprint()) {
3174       if (!getLabelFingerprint().equals(other.getLabelFingerprint())) return false;
3175     }
3176     if (!internalGetLabels().equals(other.internalGetLabels())) return false;
3177     if (hasLastAttachTimestamp() != other.hasLastAttachTimestamp()) return false;
3178     if (hasLastAttachTimestamp()) {
3179       if (!getLastAttachTimestamp().equals(other.getLastAttachTimestamp())) return false;
3180     }
3181     if (hasLastDetachTimestamp() != other.hasLastDetachTimestamp()) return false;
3182     if (hasLastDetachTimestamp()) {
3183       if (!getLastDetachTimestamp().equals(other.getLastDetachTimestamp())) return false;
3184     }
3185     if (!getLicenseCodesList().equals(other.getLicenseCodesList())) return false;
3186     if (!getLicensesList().equals(other.getLicensesList())) return false;
3187     if (hasLocationHint() != other.hasLocationHint()) return false;
3188     if (hasLocationHint()) {
3189       if (!getLocationHint().equals(other.getLocationHint())) return false;
3190     }
3191     if (hasName() != other.hasName()) return false;
3192     if (hasName()) {
3193       if (!getName().equals(other.getName())) return false;
3194     }
3195     if (hasOptions() != other.hasOptions()) return false;
3196     if (hasOptions()) {
3197       if (!getOptions().equals(other.getOptions())) return false;
3198     }
3199     if (hasParams() != other.hasParams()) return false;
3200     if (hasParams()) {
3201       if (!getParams().equals(other.getParams())) return false;
3202     }
3203     if (hasPhysicalBlockSizeBytes() != other.hasPhysicalBlockSizeBytes()) return false;
3204     if (hasPhysicalBlockSizeBytes()) {
3205       if (getPhysicalBlockSizeBytes() != other.getPhysicalBlockSizeBytes()) return false;
3206     }
3207     if (hasProvisionedIops() != other.hasProvisionedIops()) return false;
3208     if (hasProvisionedIops()) {
3209       if (getProvisionedIops() != other.getProvisionedIops()) return false;
3210     }
3211     if (hasRegion() != other.hasRegion()) return false;
3212     if (hasRegion()) {
3213       if (!getRegion().equals(other.getRegion())) return false;
3214     }
3215     if (!getReplicaZonesList().equals(other.getReplicaZonesList())) return false;
3216     if (!getResourcePoliciesList().equals(other.getResourcePoliciesList())) return false;
3217     if (hasSatisfiesPzs() != other.hasSatisfiesPzs()) return false;
3218     if (hasSatisfiesPzs()) {
3219       if (getSatisfiesPzs() != other.getSatisfiesPzs()) return false;
3220     }
3221     if (hasSelfLink() != other.hasSelfLink()) return false;
3222     if (hasSelfLink()) {
3223       if (!getSelfLink().equals(other.getSelfLink())) return false;
3224     }
3225     if (hasSizeGb() != other.hasSizeGb()) return false;
3226     if (hasSizeGb()) {
3227       if (getSizeGb() != other.getSizeGb()) return false;
3228     }
3229     if (hasSourceDisk() != other.hasSourceDisk()) return false;
3230     if (hasSourceDisk()) {
3231       if (!getSourceDisk().equals(other.getSourceDisk())) return false;
3232     }
3233     if (hasSourceDiskId() != other.hasSourceDiskId()) return false;
3234     if (hasSourceDiskId()) {
3235       if (!getSourceDiskId().equals(other.getSourceDiskId())) return false;
3236     }
3237     if (hasSourceImage() != other.hasSourceImage()) return false;
3238     if (hasSourceImage()) {
3239       if (!getSourceImage().equals(other.getSourceImage())) return false;
3240     }
3241     if (hasSourceImageEncryptionKey() != other.hasSourceImageEncryptionKey()) return false;
3242     if (hasSourceImageEncryptionKey()) {
3243       if (!getSourceImageEncryptionKey().equals(other.getSourceImageEncryptionKey())) return false;
3244     }
3245     if (hasSourceImageId() != other.hasSourceImageId()) return false;
3246     if (hasSourceImageId()) {
3247       if (!getSourceImageId().equals(other.getSourceImageId())) return false;
3248     }
3249     if (hasSourceSnapshot() != other.hasSourceSnapshot()) return false;
3250     if (hasSourceSnapshot()) {
3251       if (!getSourceSnapshot().equals(other.getSourceSnapshot())) return false;
3252     }
3253     if (hasSourceSnapshotEncryptionKey() != other.hasSourceSnapshotEncryptionKey()) return false;
3254     if (hasSourceSnapshotEncryptionKey()) {
3255       if (!getSourceSnapshotEncryptionKey().equals(other.getSourceSnapshotEncryptionKey()))
3256         return false;
3257     }
3258     if (hasSourceSnapshotId() != other.hasSourceSnapshotId()) return false;
3259     if (hasSourceSnapshotId()) {
3260       if (!getSourceSnapshotId().equals(other.getSourceSnapshotId())) return false;
3261     }
3262     if (hasSourceStorageObject() != other.hasSourceStorageObject()) return false;
3263     if (hasSourceStorageObject()) {
3264       if (!getSourceStorageObject().equals(other.getSourceStorageObject())) return false;
3265     }
3266     if (hasStatus() != other.hasStatus()) return false;
3267     if (hasStatus()) {
3268       if (!getStatus().equals(other.getStatus())) return false;
3269     }
3270     if (hasType() != other.hasType()) return false;
3271     if (hasType()) {
3272       if (!getType().equals(other.getType())) return false;
3273     }
3274     if (!getUsersList().equals(other.getUsersList())) return false;
3275     if (hasZone() != other.hasZone()) return false;
3276     if (hasZone()) {
3277       if (!getZone().equals(other.getZone())) return false;
3278     }
3279     if (!getUnknownFields().equals(other.getUnknownFields())) return false;
3280     return true;
3281   }
3282 
3283   @java.lang.Override
hashCode()3284   public int hashCode() {
3285     if (memoizedHashCode != 0) {
3286       return memoizedHashCode;
3287     }
3288     int hash = 41;
3289     hash = (19 * hash) + getDescriptor().hashCode();
3290     if (hasArchitecture()) {
3291       hash = (37 * hash) + ARCHITECTURE_FIELD_NUMBER;
3292       hash = (53 * hash) + getArchitecture().hashCode();
3293     }
3294     if (hasCreationTimestamp()) {
3295       hash = (37 * hash) + CREATION_TIMESTAMP_FIELD_NUMBER;
3296       hash = (53 * hash) + getCreationTimestamp().hashCode();
3297     }
3298     if (hasDescription()) {
3299       hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER;
3300       hash = (53 * hash) + getDescription().hashCode();
3301     }
3302     if (hasDiskEncryptionKey()) {
3303       hash = (37 * hash) + DISK_ENCRYPTION_KEY_FIELD_NUMBER;
3304       hash = (53 * hash) + getDiskEncryptionKey().hashCode();
3305     }
3306     if (getGuestOsFeaturesCount() > 0) {
3307       hash = (37 * hash) + GUEST_OS_FEATURES_FIELD_NUMBER;
3308       hash = (53 * hash) + getGuestOsFeaturesList().hashCode();
3309     }
3310     if (hasId()) {
3311       hash = (37 * hash) + ID_FIELD_NUMBER;
3312       hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getId());
3313     }
3314     if (hasKind()) {
3315       hash = (37 * hash) + KIND_FIELD_NUMBER;
3316       hash = (53 * hash) + getKind().hashCode();
3317     }
3318     if (hasLabelFingerprint()) {
3319       hash = (37 * hash) + LABEL_FINGERPRINT_FIELD_NUMBER;
3320       hash = (53 * hash) + getLabelFingerprint().hashCode();
3321     }
3322     if (!internalGetLabels().getMap().isEmpty()) {
3323       hash = (37 * hash) + LABELS_FIELD_NUMBER;
3324       hash = (53 * hash) + internalGetLabels().hashCode();
3325     }
3326     if (hasLastAttachTimestamp()) {
3327       hash = (37 * hash) + LAST_ATTACH_TIMESTAMP_FIELD_NUMBER;
3328       hash = (53 * hash) + getLastAttachTimestamp().hashCode();
3329     }
3330     if (hasLastDetachTimestamp()) {
3331       hash = (37 * hash) + LAST_DETACH_TIMESTAMP_FIELD_NUMBER;
3332       hash = (53 * hash) + getLastDetachTimestamp().hashCode();
3333     }
3334     if (getLicenseCodesCount() > 0) {
3335       hash = (37 * hash) + LICENSE_CODES_FIELD_NUMBER;
3336       hash = (53 * hash) + getLicenseCodesList().hashCode();
3337     }
3338     if (getLicensesCount() > 0) {
3339       hash = (37 * hash) + LICENSES_FIELD_NUMBER;
3340       hash = (53 * hash) + getLicensesList().hashCode();
3341     }
3342     if (hasLocationHint()) {
3343       hash = (37 * hash) + LOCATION_HINT_FIELD_NUMBER;
3344       hash = (53 * hash) + getLocationHint().hashCode();
3345     }
3346     if (hasName()) {
3347       hash = (37 * hash) + NAME_FIELD_NUMBER;
3348       hash = (53 * hash) + getName().hashCode();
3349     }
3350     if (hasOptions()) {
3351       hash = (37 * hash) + OPTIONS_FIELD_NUMBER;
3352       hash = (53 * hash) + getOptions().hashCode();
3353     }
3354     if (hasParams()) {
3355       hash = (37 * hash) + PARAMS_FIELD_NUMBER;
3356       hash = (53 * hash) + getParams().hashCode();
3357     }
3358     if (hasPhysicalBlockSizeBytes()) {
3359       hash = (37 * hash) + PHYSICAL_BLOCK_SIZE_BYTES_FIELD_NUMBER;
3360       hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getPhysicalBlockSizeBytes());
3361     }
3362     if (hasProvisionedIops()) {
3363       hash = (37 * hash) + PROVISIONED_IOPS_FIELD_NUMBER;
3364       hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getProvisionedIops());
3365     }
3366     if (hasRegion()) {
3367       hash = (37 * hash) + REGION_FIELD_NUMBER;
3368       hash = (53 * hash) + getRegion().hashCode();
3369     }
3370     if (getReplicaZonesCount() > 0) {
3371       hash = (37 * hash) + REPLICA_ZONES_FIELD_NUMBER;
3372       hash = (53 * hash) + getReplicaZonesList().hashCode();
3373     }
3374     if (getResourcePoliciesCount() > 0) {
3375       hash = (37 * hash) + RESOURCE_POLICIES_FIELD_NUMBER;
3376       hash = (53 * hash) + getResourcePoliciesList().hashCode();
3377     }
3378     if (hasSatisfiesPzs()) {
3379       hash = (37 * hash) + SATISFIES_PZS_FIELD_NUMBER;
3380       hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSatisfiesPzs());
3381     }
3382     if (hasSelfLink()) {
3383       hash = (37 * hash) + SELF_LINK_FIELD_NUMBER;
3384       hash = (53 * hash) + getSelfLink().hashCode();
3385     }
3386     if (hasSizeGb()) {
3387       hash = (37 * hash) + SIZE_GB_FIELD_NUMBER;
3388       hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSizeGb());
3389     }
3390     if (hasSourceDisk()) {
3391       hash = (37 * hash) + SOURCE_DISK_FIELD_NUMBER;
3392       hash = (53 * hash) + getSourceDisk().hashCode();
3393     }
3394     if (hasSourceDiskId()) {
3395       hash = (37 * hash) + SOURCE_DISK_ID_FIELD_NUMBER;
3396       hash = (53 * hash) + getSourceDiskId().hashCode();
3397     }
3398     if (hasSourceImage()) {
3399       hash = (37 * hash) + SOURCE_IMAGE_FIELD_NUMBER;
3400       hash = (53 * hash) + getSourceImage().hashCode();
3401     }
3402     if (hasSourceImageEncryptionKey()) {
3403       hash = (37 * hash) + SOURCE_IMAGE_ENCRYPTION_KEY_FIELD_NUMBER;
3404       hash = (53 * hash) + getSourceImageEncryptionKey().hashCode();
3405     }
3406     if (hasSourceImageId()) {
3407       hash = (37 * hash) + SOURCE_IMAGE_ID_FIELD_NUMBER;
3408       hash = (53 * hash) + getSourceImageId().hashCode();
3409     }
3410     if (hasSourceSnapshot()) {
3411       hash = (37 * hash) + SOURCE_SNAPSHOT_FIELD_NUMBER;
3412       hash = (53 * hash) + getSourceSnapshot().hashCode();
3413     }
3414     if (hasSourceSnapshotEncryptionKey()) {
3415       hash = (37 * hash) + SOURCE_SNAPSHOT_ENCRYPTION_KEY_FIELD_NUMBER;
3416       hash = (53 * hash) + getSourceSnapshotEncryptionKey().hashCode();
3417     }
3418     if (hasSourceSnapshotId()) {
3419       hash = (37 * hash) + SOURCE_SNAPSHOT_ID_FIELD_NUMBER;
3420       hash = (53 * hash) + getSourceSnapshotId().hashCode();
3421     }
3422     if (hasSourceStorageObject()) {
3423       hash = (37 * hash) + SOURCE_STORAGE_OBJECT_FIELD_NUMBER;
3424       hash = (53 * hash) + getSourceStorageObject().hashCode();
3425     }
3426     if (hasStatus()) {
3427       hash = (37 * hash) + STATUS_FIELD_NUMBER;
3428       hash = (53 * hash) + getStatus().hashCode();
3429     }
3430     if (hasType()) {
3431       hash = (37 * hash) + TYPE_FIELD_NUMBER;
3432       hash = (53 * hash) + getType().hashCode();
3433     }
3434     if (getUsersCount() > 0) {
3435       hash = (37 * hash) + USERS_FIELD_NUMBER;
3436       hash = (53 * hash) + getUsersList().hashCode();
3437     }
3438     if (hasZone()) {
3439       hash = (37 * hash) + ZONE_FIELD_NUMBER;
3440       hash = (53 * hash) + getZone().hashCode();
3441     }
3442     hash = (29 * hash) + getUnknownFields().hashCode();
3443     memoizedHashCode = hash;
3444     return hash;
3445   }
3446 
parseFrom(java.nio.ByteBuffer data)3447   public static com.google.cloud.compute.v1.Disk parseFrom(java.nio.ByteBuffer data)
3448       throws com.google.protobuf.InvalidProtocolBufferException {
3449     return PARSER.parseFrom(data);
3450   }
3451 
parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3452   public static com.google.cloud.compute.v1.Disk parseFrom(
3453       java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
3454       throws com.google.protobuf.InvalidProtocolBufferException {
3455     return PARSER.parseFrom(data, extensionRegistry);
3456   }
3457 
parseFrom(com.google.protobuf.ByteString data)3458   public static com.google.cloud.compute.v1.Disk parseFrom(com.google.protobuf.ByteString data)
3459       throws com.google.protobuf.InvalidProtocolBufferException {
3460     return PARSER.parseFrom(data);
3461   }
3462 
parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3463   public static com.google.cloud.compute.v1.Disk parseFrom(
3464       com.google.protobuf.ByteString data,
3465       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
3466       throws com.google.protobuf.InvalidProtocolBufferException {
3467     return PARSER.parseFrom(data, extensionRegistry);
3468   }
3469 
parseFrom(byte[] data)3470   public static com.google.cloud.compute.v1.Disk parseFrom(byte[] data)
3471       throws com.google.protobuf.InvalidProtocolBufferException {
3472     return PARSER.parseFrom(data);
3473   }
3474 
parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3475   public static com.google.cloud.compute.v1.Disk parseFrom(
3476       byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
3477       throws com.google.protobuf.InvalidProtocolBufferException {
3478     return PARSER.parseFrom(data, extensionRegistry);
3479   }
3480 
parseFrom(java.io.InputStream input)3481   public static com.google.cloud.compute.v1.Disk parseFrom(java.io.InputStream input)
3482       throws java.io.IOException {
3483     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
3484   }
3485 
parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3486   public static com.google.cloud.compute.v1.Disk parseFrom(
3487       java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
3488       throws java.io.IOException {
3489     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
3490         PARSER, input, extensionRegistry);
3491   }
3492 
parseDelimitedFrom(java.io.InputStream input)3493   public static com.google.cloud.compute.v1.Disk parseDelimitedFrom(java.io.InputStream input)
3494       throws java.io.IOException {
3495     return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
3496   }
3497 
parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3498   public static com.google.cloud.compute.v1.Disk parseDelimitedFrom(
3499       java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
3500       throws java.io.IOException {
3501     return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
3502         PARSER, input, extensionRegistry);
3503   }
3504 
parseFrom( com.google.protobuf.CodedInputStream input)3505   public static com.google.cloud.compute.v1.Disk parseFrom(
3506       com.google.protobuf.CodedInputStream input) throws java.io.IOException {
3507     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
3508   }
3509 
parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3510   public static com.google.cloud.compute.v1.Disk parseFrom(
3511       com.google.protobuf.CodedInputStream input,
3512       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
3513       throws java.io.IOException {
3514     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
3515         PARSER, input, extensionRegistry);
3516   }
3517 
3518   @java.lang.Override
newBuilderForType()3519   public Builder newBuilderForType() {
3520     return newBuilder();
3521   }
3522 
newBuilder()3523   public static Builder newBuilder() {
3524     return DEFAULT_INSTANCE.toBuilder();
3525   }
3526 
newBuilder(com.google.cloud.compute.v1.Disk prototype)3527   public static Builder newBuilder(com.google.cloud.compute.v1.Disk prototype) {
3528     return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
3529   }
3530 
3531   @java.lang.Override
toBuilder()3532   public Builder toBuilder() {
3533     return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
3534   }
3535 
3536   @java.lang.Override
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)3537   protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
3538     Builder builder = new Builder(parent);
3539     return builder;
3540   }
3541   /**
3542    *
3543    *
3544    * <pre>
3545    * Represents a Persistent Disk resource. Google Compute Engine has two Disk resources: * [Zonal](/compute/docs/reference/rest/v1/disks) * [Regional](/compute/docs/reference/rest/v1/regionDisks) Persistent disks are required for running your VM instances. Create both boot and non-boot (data) persistent disks. For more information, read Persistent Disks. For more storage options, read Storage options. The disks resource represents a zonal persistent disk. For more information, read Zonal persistent disks. The regionDisks resource represents a regional persistent disk. For more information, read Regional resources.
3546    * </pre>
3547    *
3548    * Protobuf type {@code google.cloud.compute.v1.Disk}
3549    */
3550   public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder>
3551       implements
3552       // @@protoc_insertion_point(builder_implements:google.cloud.compute.v1.Disk)
3553       com.google.cloud.compute.v1.DiskOrBuilder {
getDescriptor()3554     public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
3555       return com.google.cloud.compute.v1.Compute
3556           .internal_static_google_cloud_compute_v1_Disk_descriptor;
3557     }
3558 
3559     @SuppressWarnings({"rawtypes"})
internalGetMapField(int number)3560     protected com.google.protobuf.MapField internalGetMapField(int number) {
3561       switch (number) {
3562         case 500195327:
3563           return internalGetLabels();
3564         default:
3565           throw new RuntimeException("Invalid map field number: " + number);
3566       }
3567     }
3568 
3569     @SuppressWarnings({"rawtypes"})
internalGetMutableMapField(int number)3570     protected com.google.protobuf.MapField internalGetMutableMapField(int number) {
3571       switch (number) {
3572         case 500195327:
3573           return internalGetMutableLabels();
3574         default:
3575           throw new RuntimeException("Invalid map field number: " + number);
3576       }
3577     }
3578 
3579     @java.lang.Override
3580     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()3581         internalGetFieldAccessorTable() {
3582       return com.google.cloud.compute.v1.Compute
3583           .internal_static_google_cloud_compute_v1_Disk_fieldAccessorTable
3584           .ensureFieldAccessorsInitialized(
3585               com.google.cloud.compute.v1.Disk.class,
3586               com.google.cloud.compute.v1.Disk.Builder.class);
3587     }
3588 
3589     // Construct using com.google.cloud.compute.v1.Disk.newBuilder()
Builder()3590     private Builder() {
3591       maybeForceBuilderInitialization();
3592     }
3593 
Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)3594     private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
3595       super(parent);
3596       maybeForceBuilderInitialization();
3597     }
3598 
maybeForceBuilderInitialization()3599     private void maybeForceBuilderInitialization() {
3600       if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {
3601         getDiskEncryptionKeyFieldBuilder();
3602         getGuestOsFeaturesFieldBuilder();
3603         getParamsFieldBuilder();
3604         getSourceImageEncryptionKeyFieldBuilder();
3605         getSourceSnapshotEncryptionKeyFieldBuilder();
3606       }
3607     }
3608 
3609     @java.lang.Override
clear()3610     public Builder clear() {
3611       super.clear();
3612       bitField0_ = 0;
3613       bitField1_ = 0;
3614       architecture_ = "";
3615       creationTimestamp_ = "";
3616       description_ = "";
3617       diskEncryptionKey_ = null;
3618       if (diskEncryptionKeyBuilder_ != null) {
3619         diskEncryptionKeyBuilder_.dispose();
3620         diskEncryptionKeyBuilder_ = null;
3621       }
3622       if (guestOsFeaturesBuilder_ == null) {
3623         guestOsFeatures_ = java.util.Collections.emptyList();
3624       } else {
3625         guestOsFeatures_ = null;
3626         guestOsFeaturesBuilder_.clear();
3627       }
3628       bitField0_ = (bitField0_ & ~0x00000010);
3629       id_ = 0L;
3630       kind_ = "";
3631       labelFingerprint_ = "";
3632       internalGetMutableLabels().clear();
3633       lastAttachTimestamp_ = "";
3634       lastDetachTimestamp_ = "";
3635       licenseCodes_ = emptyLongList();
3636       licenses_ = com.google.protobuf.LazyStringArrayList.EMPTY;
3637       bitField0_ = (bitField0_ & ~0x00001000);
3638       locationHint_ = "";
3639       name_ = "";
3640       options_ = "";
3641       params_ = null;
3642       if (paramsBuilder_ != null) {
3643         paramsBuilder_.dispose();
3644         paramsBuilder_ = null;
3645       }
3646       physicalBlockSizeBytes_ = 0L;
3647       provisionedIops_ = 0L;
3648       region_ = "";
3649       replicaZones_ = com.google.protobuf.LazyStringArrayList.EMPTY;
3650       bitField0_ = (bitField0_ & ~0x00100000);
3651       resourcePolicies_ = com.google.protobuf.LazyStringArrayList.EMPTY;
3652       bitField0_ = (bitField0_ & ~0x00200000);
3653       satisfiesPzs_ = false;
3654       selfLink_ = "";
3655       sizeGb_ = 0L;
3656       sourceDisk_ = "";
3657       sourceDiskId_ = "";
3658       sourceImage_ = "";
3659       sourceImageEncryptionKey_ = null;
3660       if (sourceImageEncryptionKeyBuilder_ != null) {
3661         sourceImageEncryptionKeyBuilder_.dispose();
3662         sourceImageEncryptionKeyBuilder_ = null;
3663       }
3664       sourceImageId_ = "";
3665       sourceSnapshot_ = "";
3666       sourceSnapshotEncryptionKey_ = null;
3667       if (sourceSnapshotEncryptionKeyBuilder_ != null) {
3668         sourceSnapshotEncryptionKeyBuilder_.dispose();
3669         sourceSnapshotEncryptionKeyBuilder_ = null;
3670       }
3671       sourceSnapshotId_ = "";
3672       sourceStorageObject_ = "";
3673       status_ = "";
3674       type_ = "";
3675       users_ = com.google.protobuf.LazyStringArrayList.EMPTY;
3676       bitField1_ = (bitField1_ & ~0x00000010);
3677       zone_ = "";
3678       return this;
3679     }
3680 
3681     @java.lang.Override
getDescriptorForType()3682     public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
3683       return com.google.cloud.compute.v1.Compute
3684           .internal_static_google_cloud_compute_v1_Disk_descriptor;
3685     }
3686 
3687     @java.lang.Override
getDefaultInstanceForType()3688     public com.google.cloud.compute.v1.Disk getDefaultInstanceForType() {
3689       return com.google.cloud.compute.v1.Disk.getDefaultInstance();
3690     }
3691 
3692     @java.lang.Override
build()3693     public com.google.cloud.compute.v1.Disk build() {
3694       com.google.cloud.compute.v1.Disk result = buildPartial();
3695       if (!result.isInitialized()) {
3696         throw newUninitializedMessageException(result);
3697       }
3698       return result;
3699     }
3700 
3701     @java.lang.Override
buildPartial()3702     public com.google.cloud.compute.v1.Disk buildPartial() {
3703       com.google.cloud.compute.v1.Disk result = new com.google.cloud.compute.v1.Disk(this);
3704       buildPartialRepeatedFields(result);
3705       if (bitField0_ != 0) {
3706         buildPartial0(result);
3707       }
3708       if (bitField1_ != 0) {
3709         buildPartial1(result);
3710       }
3711       onBuilt();
3712       return result;
3713     }
3714 
buildPartialRepeatedFields(com.google.cloud.compute.v1.Disk result)3715     private void buildPartialRepeatedFields(com.google.cloud.compute.v1.Disk result) {
3716       if (guestOsFeaturesBuilder_ == null) {
3717         if (((bitField0_ & 0x00000010) != 0)) {
3718           guestOsFeatures_ = java.util.Collections.unmodifiableList(guestOsFeatures_);
3719           bitField0_ = (bitField0_ & ~0x00000010);
3720         }
3721         result.guestOsFeatures_ = guestOsFeatures_;
3722       } else {
3723         result.guestOsFeatures_ = guestOsFeaturesBuilder_.build();
3724       }
3725       if (((bitField0_ & 0x00000800) != 0)) {
3726         licenseCodes_.makeImmutable();
3727         bitField0_ = (bitField0_ & ~0x00000800);
3728       }
3729       result.licenseCodes_ = licenseCodes_;
3730       if (((bitField0_ & 0x00001000) != 0)) {
3731         licenses_ = licenses_.getUnmodifiableView();
3732         bitField0_ = (bitField0_ & ~0x00001000);
3733       }
3734       result.licenses_ = licenses_;
3735       if (((bitField0_ & 0x00100000) != 0)) {
3736         replicaZones_ = replicaZones_.getUnmodifiableView();
3737         bitField0_ = (bitField0_ & ~0x00100000);
3738       }
3739       result.replicaZones_ = replicaZones_;
3740       if (((bitField0_ & 0x00200000) != 0)) {
3741         resourcePolicies_ = resourcePolicies_.getUnmodifiableView();
3742         bitField0_ = (bitField0_ & ~0x00200000);
3743       }
3744       result.resourcePolicies_ = resourcePolicies_;
3745       if (((bitField1_ & 0x00000010) != 0)) {
3746         users_ = users_.getUnmodifiableView();
3747         bitField1_ = (bitField1_ & ~0x00000010);
3748       }
3749       result.users_ = users_;
3750     }
3751 
buildPartial0(com.google.cloud.compute.v1.Disk result)3752     private void buildPartial0(com.google.cloud.compute.v1.Disk result) {
3753       int from_bitField0_ = bitField0_;
3754       int to_bitField0_ = 0;
3755       if (((from_bitField0_ & 0x00000001) != 0)) {
3756         result.architecture_ = architecture_;
3757         to_bitField0_ |= 0x00000001;
3758       }
3759       if (((from_bitField0_ & 0x00000002) != 0)) {
3760         result.creationTimestamp_ = creationTimestamp_;
3761         to_bitField0_ |= 0x00000002;
3762       }
3763       if (((from_bitField0_ & 0x00000004) != 0)) {
3764         result.description_ = description_;
3765         to_bitField0_ |= 0x00000004;
3766       }
3767       if (((from_bitField0_ & 0x00000008) != 0)) {
3768         result.diskEncryptionKey_ =
3769             diskEncryptionKeyBuilder_ == null
3770                 ? diskEncryptionKey_
3771                 : diskEncryptionKeyBuilder_.build();
3772         to_bitField0_ |= 0x00000008;
3773       }
3774       if (((from_bitField0_ & 0x00000020) != 0)) {
3775         result.id_ = id_;
3776         to_bitField0_ |= 0x00000010;
3777       }
3778       if (((from_bitField0_ & 0x00000040) != 0)) {
3779         result.kind_ = kind_;
3780         to_bitField0_ |= 0x00000020;
3781       }
3782       if (((from_bitField0_ & 0x00000080) != 0)) {
3783         result.labelFingerprint_ = labelFingerprint_;
3784         to_bitField0_ |= 0x00000040;
3785       }
3786       if (((from_bitField0_ & 0x00000100) != 0)) {
3787         result.labels_ = internalGetLabels();
3788         result.labels_.makeImmutable();
3789       }
3790       if (((from_bitField0_ & 0x00000200) != 0)) {
3791         result.lastAttachTimestamp_ = lastAttachTimestamp_;
3792         to_bitField0_ |= 0x00000080;
3793       }
3794       if (((from_bitField0_ & 0x00000400) != 0)) {
3795         result.lastDetachTimestamp_ = lastDetachTimestamp_;
3796         to_bitField0_ |= 0x00000100;
3797       }
3798       if (((from_bitField0_ & 0x00002000) != 0)) {
3799         result.locationHint_ = locationHint_;
3800         to_bitField0_ |= 0x00000200;
3801       }
3802       if (((from_bitField0_ & 0x00004000) != 0)) {
3803         result.name_ = name_;
3804         to_bitField0_ |= 0x00000400;
3805       }
3806       if (((from_bitField0_ & 0x00008000) != 0)) {
3807         result.options_ = options_;
3808         to_bitField0_ |= 0x00000800;
3809       }
3810       if (((from_bitField0_ & 0x00010000) != 0)) {
3811         result.params_ = paramsBuilder_ == null ? params_ : paramsBuilder_.build();
3812         to_bitField0_ |= 0x00001000;
3813       }
3814       if (((from_bitField0_ & 0x00020000) != 0)) {
3815         result.physicalBlockSizeBytes_ = physicalBlockSizeBytes_;
3816         to_bitField0_ |= 0x00002000;
3817       }
3818       if (((from_bitField0_ & 0x00040000) != 0)) {
3819         result.provisionedIops_ = provisionedIops_;
3820         to_bitField0_ |= 0x00004000;
3821       }
3822       if (((from_bitField0_ & 0x00080000) != 0)) {
3823         result.region_ = region_;
3824         to_bitField0_ |= 0x00008000;
3825       }
3826       if (((from_bitField0_ & 0x00400000) != 0)) {
3827         result.satisfiesPzs_ = satisfiesPzs_;
3828         to_bitField0_ |= 0x00010000;
3829       }
3830       if (((from_bitField0_ & 0x00800000) != 0)) {
3831         result.selfLink_ = selfLink_;
3832         to_bitField0_ |= 0x00020000;
3833       }
3834       if (((from_bitField0_ & 0x01000000) != 0)) {
3835         result.sizeGb_ = sizeGb_;
3836         to_bitField0_ |= 0x00040000;
3837       }
3838       if (((from_bitField0_ & 0x02000000) != 0)) {
3839         result.sourceDisk_ = sourceDisk_;
3840         to_bitField0_ |= 0x00080000;
3841       }
3842       if (((from_bitField0_ & 0x04000000) != 0)) {
3843         result.sourceDiskId_ = sourceDiskId_;
3844         to_bitField0_ |= 0x00100000;
3845       }
3846       if (((from_bitField0_ & 0x08000000) != 0)) {
3847         result.sourceImage_ = sourceImage_;
3848         to_bitField0_ |= 0x00200000;
3849       }
3850       if (((from_bitField0_ & 0x10000000) != 0)) {
3851         result.sourceImageEncryptionKey_ =
3852             sourceImageEncryptionKeyBuilder_ == null
3853                 ? sourceImageEncryptionKey_
3854                 : sourceImageEncryptionKeyBuilder_.build();
3855         to_bitField0_ |= 0x00400000;
3856       }
3857       if (((from_bitField0_ & 0x20000000) != 0)) {
3858         result.sourceImageId_ = sourceImageId_;
3859         to_bitField0_ |= 0x00800000;
3860       }
3861       if (((from_bitField0_ & 0x40000000) != 0)) {
3862         result.sourceSnapshot_ = sourceSnapshot_;
3863         to_bitField0_ |= 0x01000000;
3864       }
3865       if (((from_bitField0_ & 0x80000000) != 0)) {
3866         result.sourceSnapshotEncryptionKey_ =
3867             sourceSnapshotEncryptionKeyBuilder_ == null
3868                 ? sourceSnapshotEncryptionKey_
3869                 : sourceSnapshotEncryptionKeyBuilder_.build();
3870         to_bitField0_ |= 0x02000000;
3871       }
3872       result.bitField0_ |= to_bitField0_;
3873     }
3874 
buildPartial1(com.google.cloud.compute.v1.Disk result)3875     private void buildPartial1(com.google.cloud.compute.v1.Disk result) {
3876       int from_bitField1_ = bitField1_;
3877       int to_bitField0_ = 0;
3878       if (((from_bitField1_ & 0x00000001) != 0)) {
3879         result.sourceSnapshotId_ = sourceSnapshotId_;
3880         to_bitField0_ |= 0x04000000;
3881       }
3882       if (((from_bitField1_ & 0x00000002) != 0)) {
3883         result.sourceStorageObject_ = sourceStorageObject_;
3884         to_bitField0_ |= 0x08000000;
3885       }
3886       if (((from_bitField1_ & 0x00000004) != 0)) {
3887         result.status_ = status_;
3888         to_bitField0_ |= 0x10000000;
3889       }
3890       if (((from_bitField1_ & 0x00000008) != 0)) {
3891         result.type_ = type_;
3892         to_bitField0_ |= 0x20000000;
3893       }
3894       if (((from_bitField1_ & 0x00000020) != 0)) {
3895         result.zone_ = zone_;
3896         to_bitField0_ |= 0x40000000;
3897       }
3898       result.bitField0_ |= to_bitField0_;
3899     }
3900 
3901     @java.lang.Override
clone()3902     public Builder clone() {
3903       return super.clone();
3904     }
3905 
3906     @java.lang.Override
setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)3907     public Builder setField(
3908         com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
3909       return super.setField(field, value);
3910     }
3911 
3912     @java.lang.Override
clearField(com.google.protobuf.Descriptors.FieldDescriptor field)3913     public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
3914       return super.clearField(field);
3915     }
3916 
3917     @java.lang.Override
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)3918     public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
3919       return super.clearOneof(oneof);
3920     }
3921 
3922     @java.lang.Override
setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)3923     public Builder setRepeatedField(
3924         com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
3925       return super.setRepeatedField(field, index, value);
3926     }
3927 
3928     @java.lang.Override
addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)3929     public Builder addRepeatedField(
3930         com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
3931       return super.addRepeatedField(field, value);
3932     }
3933 
3934     @java.lang.Override
mergeFrom(com.google.protobuf.Message other)3935     public Builder mergeFrom(com.google.protobuf.Message other) {
3936       if (other instanceof com.google.cloud.compute.v1.Disk) {
3937         return mergeFrom((com.google.cloud.compute.v1.Disk) other);
3938       } else {
3939         super.mergeFrom(other);
3940         return this;
3941       }
3942     }
3943 
mergeFrom(com.google.cloud.compute.v1.Disk other)3944     public Builder mergeFrom(com.google.cloud.compute.v1.Disk other) {
3945       if (other == com.google.cloud.compute.v1.Disk.getDefaultInstance()) return this;
3946       if (other.hasArchitecture()) {
3947         architecture_ = other.architecture_;
3948         bitField0_ |= 0x00000001;
3949         onChanged();
3950       }
3951       if (other.hasCreationTimestamp()) {
3952         creationTimestamp_ = other.creationTimestamp_;
3953         bitField0_ |= 0x00000002;
3954         onChanged();
3955       }
3956       if (other.hasDescription()) {
3957         description_ = other.description_;
3958         bitField0_ |= 0x00000004;
3959         onChanged();
3960       }
3961       if (other.hasDiskEncryptionKey()) {
3962         mergeDiskEncryptionKey(other.getDiskEncryptionKey());
3963       }
3964       if (guestOsFeaturesBuilder_ == null) {
3965         if (!other.guestOsFeatures_.isEmpty()) {
3966           if (guestOsFeatures_.isEmpty()) {
3967             guestOsFeatures_ = other.guestOsFeatures_;
3968             bitField0_ = (bitField0_ & ~0x00000010);
3969           } else {
3970             ensureGuestOsFeaturesIsMutable();
3971             guestOsFeatures_.addAll(other.guestOsFeatures_);
3972           }
3973           onChanged();
3974         }
3975       } else {
3976         if (!other.guestOsFeatures_.isEmpty()) {
3977           if (guestOsFeaturesBuilder_.isEmpty()) {
3978             guestOsFeaturesBuilder_.dispose();
3979             guestOsFeaturesBuilder_ = null;
3980             guestOsFeatures_ = other.guestOsFeatures_;
3981             bitField0_ = (bitField0_ & ~0x00000010);
3982             guestOsFeaturesBuilder_ =
3983                 com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders
3984                     ? getGuestOsFeaturesFieldBuilder()
3985                     : null;
3986           } else {
3987             guestOsFeaturesBuilder_.addAllMessages(other.guestOsFeatures_);
3988           }
3989         }
3990       }
3991       if (other.hasId()) {
3992         setId(other.getId());
3993       }
3994       if (other.hasKind()) {
3995         kind_ = other.kind_;
3996         bitField0_ |= 0x00000040;
3997         onChanged();
3998       }
3999       if (other.hasLabelFingerprint()) {
4000         labelFingerprint_ = other.labelFingerprint_;
4001         bitField0_ |= 0x00000080;
4002         onChanged();
4003       }
4004       internalGetMutableLabels().mergeFrom(other.internalGetLabels());
4005       bitField0_ |= 0x00000100;
4006       if (other.hasLastAttachTimestamp()) {
4007         lastAttachTimestamp_ = other.lastAttachTimestamp_;
4008         bitField0_ |= 0x00000200;
4009         onChanged();
4010       }
4011       if (other.hasLastDetachTimestamp()) {
4012         lastDetachTimestamp_ = other.lastDetachTimestamp_;
4013         bitField0_ |= 0x00000400;
4014         onChanged();
4015       }
4016       if (!other.licenseCodes_.isEmpty()) {
4017         if (licenseCodes_.isEmpty()) {
4018           licenseCodes_ = other.licenseCodes_;
4019           bitField0_ = (bitField0_ & ~0x00000800);
4020         } else {
4021           ensureLicenseCodesIsMutable();
4022           licenseCodes_.addAll(other.licenseCodes_);
4023         }
4024         onChanged();
4025       }
4026       if (!other.licenses_.isEmpty()) {
4027         if (licenses_.isEmpty()) {
4028           licenses_ = other.licenses_;
4029           bitField0_ = (bitField0_ & ~0x00001000);
4030         } else {
4031           ensureLicensesIsMutable();
4032           licenses_.addAll(other.licenses_);
4033         }
4034         onChanged();
4035       }
4036       if (other.hasLocationHint()) {
4037         locationHint_ = other.locationHint_;
4038         bitField0_ |= 0x00002000;
4039         onChanged();
4040       }
4041       if (other.hasName()) {
4042         name_ = other.name_;
4043         bitField0_ |= 0x00004000;
4044         onChanged();
4045       }
4046       if (other.hasOptions()) {
4047         options_ = other.options_;
4048         bitField0_ |= 0x00008000;
4049         onChanged();
4050       }
4051       if (other.hasParams()) {
4052         mergeParams(other.getParams());
4053       }
4054       if (other.hasPhysicalBlockSizeBytes()) {
4055         setPhysicalBlockSizeBytes(other.getPhysicalBlockSizeBytes());
4056       }
4057       if (other.hasProvisionedIops()) {
4058         setProvisionedIops(other.getProvisionedIops());
4059       }
4060       if (other.hasRegion()) {
4061         region_ = other.region_;
4062         bitField0_ |= 0x00080000;
4063         onChanged();
4064       }
4065       if (!other.replicaZones_.isEmpty()) {
4066         if (replicaZones_.isEmpty()) {
4067           replicaZones_ = other.replicaZones_;
4068           bitField0_ = (bitField0_ & ~0x00100000);
4069         } else {
4070           ensureReplicaZonesIsMutable();
4071           replicaZones_.addAll(other.replicaZones_);
4072         }
4073         onChanged();
4074       }
4075       if (!other.resourcePolicies_.isEmpty()) {
4076         if (resourcePolicies_.isEmpty()) {
4077           resourcePolicies_ = other.resourcePolicies_;
4078           bitField0_ = (bitField0_ & ~0x00200000);
4079         } else {
4080           ensureResourcePoliciesIsMutable();
4081           resourcePolicies_.addAll(other.resourcePolicies_);
4082         }
4083         onChanged();
4084       }
4085       if (other.hasSatisfiesPzs()) {
4086         setSatisfiesPzs(other.getSatisfiesPzs());
4087       }
4088       if (other.hasSelfLink()) {
4089         selfLink_ = other.selfLink_;
4090         bitField0_ |= 0x00800000;
4091         onChanged();
4092       }
4093       if (other.hasSizeGb()) {
4094         setSizeGb(other.getSizeGb());
4095       }
4096       if (other.hasSourceDisk()) {
4097         sourceDisk_ = other.sourceDisk_;
4098         bitField0_ |= 0x02000000;
4099         onChanged();
4100       }
4101       if (other.hasSourceDiskId()) {
4102         sourceDiskId_ = other.sourceDiskId_;
4103         bitField0_ |= 0x04000000;
4104         onChanged();
4105       }
4106       if (other.hasSourceImage()) {
4107         sourceImage_ = other.sourceImage_;
4108         bitField0_ |= 0x08000000;
4109         onChanged();
4110       }
4111       if (other.hasSourceImageEncryptionKey()) {
4112         mergeSourceImageEncryptionKey(other.getSourceImageEncryptionKey());
4113       }
4114       if (other.hasSourceImageId()) {
4115         sourceImageId_ = other.sourceImageId_;
4116         bitField0_ |= 0x20000000;
4117         onChanged();
4118       }
4119       if (other.hasSourceSnapshot()) {
4120         sourceSnapshot_ = other.sourceSnapshot_;
4121         bitField0_ |= 0x40000000;
4122         onChanged();
4123       }
4124       if (other.hasSourceSnapshotEncryptionKey()) {
4125         mergeSourceSnapshotEncryptionKey(other.getSourceSnapshotEncryptionKey());
4126       }
4127       if (other.hasSourceSnapshotId()) {
4128         sourceSnapshotId_ = other.sourceSnapshotId_;
4129         bitField1_ |= 0x00000001;
4130         onChanged();
4131       }
4132       if (other.hasSourceStorageObject()) {
4133         sourceStorageObject_ = other.sourceStorageObject_;
4134         bitField1_ |= 0x00000002;
4135         onChanged();
4136       }
4137       if (other.hasStatus()) {
4138         status_ = other.status_;
4139         bitField1_ |= 0x00000004;
4140         onChanged();
4141       }
4142       if (other.hasType()) {
4143         type_ = other.type_;
4144         bitField1_ |= 0x00000008;
4145         onChanged();
4146       }
4147       if (!other.users_.isEmpty()) {
4148         if (users_.isEmpty()) {
4149           users_ = other.users_;
4150           bitField1_ = (bitField1_ & ~0x00000010);
4151         } else {
4152           ensureUsersIsMutable();
4153           users_.addAll(other.users_);
4154         }
4155         onChanged();
4156       }
4157       if (other.hasZone()) {
4158         zone_ = other.zone_;
4159         bitField1_ |= 0x00000020;
4160         onChanged();
4161       }
4162       this.mergeUnknownFields(other.getUnknownFields());
4163       onChanged();
4164       return this;
4165     }
4166 
4167     @java.lang.Override
isInitialized()4168     public final boolean isInitialized() {
4169       return true;
4170     }
4171 
4172     @java.lang.Override
mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)4173     public Builder mergeFrom(
4174         com.google.protobuf.CodedInputStream input,
4175         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
4176         throws java.io.IOException {
4177       if (extensionRegistry == null) {
4178         throw new java.lang.NullPointerException();
4179       }
4180       try {
4181         boolean done = false;
4182         while (!done) {
4183           int tag = input.readTag();
4184           switch (tag) {
4185             case 0:
4186               done = true;
4187               break;
4188             case 26840:
4189               {
4190                 id_ = input.readUInt64();
4191                 bitField0_ |= 0x00000020;
4192                 break;
4193               } // case 26840
4194             case 26336418:
4195               {
4196                 kind_ = input.readStringRequireUtf8();
4197                 bitField0_ |= 0x00000040;
4198                 break;
4199               } // case 26336418
4200             case 26989658:
4201               {
4202                 name_ = input.readStringRequireUtf8();
4203                 bitField0_ |= 0x00004000;
4204                 break;
4205               } // case 26989658
4206             case 28604882:
4207               {
4208                 type_ = input.readStringRequireUtf8();
4209                 bitField1_ |= 0x00000008;
4210                 break;
4211               } // case 28604882
4212             case 29957474:
4213               {
4214                 zone_ = input.readStringRequireUtf8();
4215                 bitField1_ |= 0x00000020;
4216                 break;
4217               } // case 29957474
4218             case 177763082:
4219               {
4220                 java.lang.String s = input.readStringRequireUtf8();
4221                 ensureResourcePoliciesIsMutable();
4222                 resourcePolicies_.add(s);
4223                 break;
4224               } // case 177763082
4225             case 244202930:
4226               {
4227                 creationTimestamp_ = input.readStringRequireUtf8();
4228                 bitField0_ |= 0x00000002;
4229                 break;
4230               } // case 244202930
4231             case 337277226:
4232               {
4233                 lastAttachTimestamp_ = input.readStringRequireUtf8();
4234                 bitField0_ |= 0x00000200;
4235                 break;
4236               } // case 337277226
4237             case 363861312:
4238               {
4239                 long v = input.readInt64();
4240                 ensureLicenseCodesIsMutable();
4241                 licenseCodes_.addLong(v);
4242                 break;
4243               } // case 363861312
4244             case 363861314:
4245               {
4246                 int length = input.readRawVarint32();
4247                 int limit = input.pushLimit(length);
4248                 ensureLicenseCodesIsMutable();
4249                 while (input.getBytesUntilLimit() > 0) {
4250                   licenseCodes_.addLong(input.readInt64());
4251                 }
4252                 input.popLimit(limit);
4253                 break;
4254               } // case 363861314
4255             case 387506178:
4256               {
4257                 java.lang.String s = input.readStringRequireUtf8();
4258                 ensureReplicaZonesIsMutable();
4259                 replicaZones_.add(s);
4260                 break;
4261               } // case 387506178
4262             case 403546554:
4263               {
4264                 sourceImage_ = input.readStringRequireUtf8();
4265                 bitField0_ |= 0x08000000;
4266                 break;
4267               } // case 403546554
4268             case 442626330:
4269               {
4270                 sourceImageId_ = input.readStringRequireUtf8();
4271                 bitField0_ |= 0x20000000;
4272                 break;
4273               } // case 442626330
4274             case 451768218:
4275               {
4276                 lastDetachTimestamp_ = input.readStringRequireUtf8();
4277                 bitField0_ |= 0x00000400;
4278                 break;
4279               } // case 451768218
4280             case 626510898:
4281               {
4282                 input.readMessage(getParamsFieldBuilder().getBuilder(), extensionRegistry);
4283                 bitField0_ |= 0x00010000;
4284                 break;
4285               } // case 626510898
4286             case 634356362:
4287               {
4288                 com.google.cloud.compute.v1.GuestOsFeature m =
4289                     input.readMessage(
4290                         com.google.cloud.compute.v1.GuestOsFeature.parser(), extensionRegistry);
4291                 if (guestOsFeaturesBuilder_ == null) {
4292                   ensureGuestOsFeaturesIsMutable();
4293                   guestOsFeatures_.add(m);
4294                 } else {
4295                   guestOsFeaturesBuilder_.addMessage(m);
4296                 }
4297                 break;
4298               } // case 634356362
4299             case 791698066:
4300               {
4301                 sourceSnapshotId_ = input.readStringRequireUtf8();
4302                 bitField1_ |= 0x00000001;
4303                 break;
4304               } // case 791698066
4305             case 892629058:
4306               {
4307                 java.lang.String s = input.readStringRequireUtf8();
4308                 ensureUsersIsMutable();
4309                 users_.add(s);
4310                 break;
4311               } // case 892629058
4312             case 1008495426:
4313               {
4314                 sourceSnapshot_ = input.readStringRequireUtf8();
4315                 bitField0_ |= 0x40000000;
4316                 break;
4317               } // case 1008495426
4318             case 1111570338:
4319               {
4320                 region_ = input.readStringRequireUtf8();
4321                 bitField0_ |= 0x00080000;
4322                 break;
4323               } // case 1111570338
4324             case 1424998602:
4325               {
4326                 labelFingerprint_ = input.readStringRequireUtf8();
4327                 bitField0_ |= 0x00000080;
4328                 break;
4329               } // case 1424998602
4330             case 1450082194:
4331               {
4332                 status_ = input.readStringRequireUtf8();
4333                 bitField1_ |= 0x00000004;
4334                 break;
4335               } // case 1450082194
4336             case 1494152864:
4337               {
4338                 provisionedIops_ = input.readInt64();
4339                 bitField0_ |= 0x00040000;
4340                 break;
4341               } // case 1494152864
4342             case 1864421690:
4343               {
4344                 sourceStorageObject_ = input.readStringRequireUtf8();
4345                 bitField1_ |= 0x00000002;
4346                 break;
4347               } // case 1864421690
4348             case -2121681878:
4349               {
4350                 input.readMessage(
4351                     getDiskEncryptionKeyFieldBuilder().getBuilder(), extensionRegistry);
4352                 bitField0_ |= 0x00000008;
4353                 break;
4354               } // case -2121681878
4355             case -1872541030:
4356               {
4357                 architecture_ = input.readStringRequireUtf8();
4358                 bitField0_ |= 0x00000001;
4359                 break;
4360               } // case -1872541030
4361             case -1865532718:
4362               {
4363                 input.readMessage(
4364                     getSourceSnapshotEncryptionKeyFieldBuilder().getBuilder(), extensionRegistry);
4365                 bitField0_ |= 0x80000000;
4366                 break;
4367               } // case -1865532718
4368             case -1593826670:
4369               {
4370                 java.lang.String s = input.readStringRequireUtf8();
4371                 ensureLicensesIsMutable();
4372                 licenses_.add(s);
4373                 break;
4374               } // case -1593826670
4375             case -1490811254:
4376               {
4377                 locationHint_ = input.readStringRequireUtf8();
4378                 bitField0_ |= 0x00002000;
4379                 break;
4380               } // case -1490811254
4381             case -1405864718:
4382               {
4383                 options_ = input.readStringRequireUtf8();
4384                 bitField0_ |= 0x00008000;
4385                 break;
4386               } // case -1405864718
4387             case -1242938022:
4388               {
4389                 input.readMessage(
4390                     getSourceImageEncryptionKeyFieldBuilder().getBuilder(), extensionRegistry);
4391                 bitField0_ |= 0x10000000;
4392                 break;
4393               } // case -1242938022
4394             case -934903752:
4395               {
4396                 physicalBlockSizeBytes_ = input.readInt64();
4397                 bitField0_ |= 0x00020000;
4398                 break;
4399               } // case -934903752
4400             case -911466526:
4401               {
4402                 description_ = input.readStringRequireUtf8();
4403                 bitField0_ |= 0x00000004;
4404                 break;
4405               } // case -911466526
4406             case -680936950:
4407               {
4408                 sourceDisk_ = input.readStringRequireUtf8();
4409                 bitField0_ |= 0x02000000;
4410                 break;
4411               } // case -680936950
4412             case -661440822:
4413               {
4414                 sourceDiskId_ = input.readStringRequireUtf8();
4415                 bitField0_ |= 0x04000000;
4416                 break;
4417               } // case -661440822
4418             case -645248918:
4419               {
4420                 selfLink_ = input.readStringRequireUtf8();
4421                 bitField0_ |= 0x00800000;
4422                 break;
4423               } // case -645248918
4424             case -447253160:
4425               {
4426                 satisfiesPzs_ = input.readBool();
4427                 bitField0_ |= 0x00400000;
4428                 break;
4429               } // case -447253160
4430             case -335532344:
4431               {
4432                 sizeGb_ = input.readInt64();
4433                 bitField0_ |= 0x01000000;
4434                 break;
4435               } // case -335532344
4436             case -293404678:
4437               {
4438                 com.google.protobuf.MapEntry<java.lang.String, java.lang.String> labels__ =
4439                     input.readMessage(
4440                         LabelsDefaultEntryHolder.defaultEntry.getParserForType(),
4441                         extensionRegistry);
4442                 internalGetMutableLabels()
4443                     .getMutableMap()
4444                     .put(labels__.getKey(), labels__.getValue());
4445                 bitField0_ |= 0x00000100;
4446                 break;
4447               } // case -293404678
4448             default:
4449               {
4450                 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
4451                   done = true; // was an endgroup tag
4452                 }
4453                 break;
4454               } // default:
4455           } // switch (tag)
4456         } // while (!done)
4457       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
4458         throw e.unwrapIOException();
4459       } finally {
4460         onChanged();
4461       } // finally
4462       return this;
4463     }
4464 
4465     private int bitField0_;
4466     private int bitField1_;
4467 
4468     private java.lang.Object architecture_ = "";
4469     /**
4470      *
4471      *
4472      * <pre>
4473      * The architecture of the disk. Valid values are ARM64 or X86_64.
4474      * Check the Architecture enum for the list of possible values.
4475      * </pre>
4476      *
4477      * <code>optional string architecture = 302803283;</code>
4478      *
4479      * @return Whether the architecture field is set.
4480      */
hasArchitecture()4481     public boolean hasArchitecture() {
4482       return ((bitField0_ & 0x00000001) != 0);
4483     }
4484     /**
4485      *
4486      *
4487      * <pre>
4488      * The architecture of the disk. Valid values are ARM64 or X86_64.
4489      * Check the Architecture enum for the list of possible values.
4490      * </pre>
4491      *
4492      * <code>optional string architecture = 302803283;</code>
4493      *
4494      * @return The architecture.
4495      */
getArchitecture()4496     public java.lang.String getArchitecture() {
4497       java.lang.Object ref = architecture_;
4498       if (!(ref instanceof java.lang.String)) {
4499         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
4500         java.lang.String s = bs.toStringUtf8();
4501         architecture_ = s;
4502         return s;
4503       } else {
4504         return (java.lang.String) ref;
4505       }
4506     }
4507     /**
4508      *
4509      *
4510      * <pre>
4511      * The architecture of the disk. Valid values are ARM64 or X86_64.
4512      * Check the Architecture enum for the list of possible values.
4513      * </pre>
4514      *
4515      * <code>optional string architecture = 302803283;</code>
4516      *
4517      * @return The bytes for architecture.
4518      */
getArchitectureBytes()4519     public com.google.protobuf.ByteString getArchitectureBytes() {
4520       java.lang.Object ref = architecture_;
4521       if (ref instanceof String) {
4522         com.google.protobuf.ByteString b =
4523             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
4524         architecture_ = b;
4525         return b;
4526       } else {
4527         return (com.google.protobuf.ByteString) ref;
4528       }
4529     }
4530     /**
4531      *
4532      *
4533      * <pre>
4534      * The architecture of the disk. Valid values are ARM64 or X86_64.
4535      * Check the Architecture enum for the list of possible values.
4536      * </pre>
4537      *
4538      * <code>optional string architecture = 302803283;</code>
4539      *
4540      * @param value The architecture to set.
4541      * @return This builder for chaining.
4542      */
setArchitecture(java.lang.String value)4543     public Builder setArchitecture(java.lang.String value) {
4544       if (value == null) {
4545         throw new NullPointerException();
4546       }
4547       architecture_ = value;
4548       bitField0_ |= 0x00000001;
4549       onChanged();
4550       return this;
4551     }
4552     /**
4553      *
4554      *
4555      * <pre>
4556      * The architecture of the disk. Valid values are ARM64 or X86_64.
4557      * Check the Architecture enum for the list of possible values.
4558      * </pre>
4559      *
4560      * <code>optional string architecture = 302803283;</code>
4561      *
4562      * @return This builder for chaining.
4563      */
clearArchitecture()4564     public Builder clearArchitecture() {
4565       architecture_ = getDefaultInstance().getArchitecture();
4566       bitField0_ = (bitField0_ & ~0x00000001);
4567       onChanged();
4568       return this;
4569     }
4570     /**
4571      *
4572      *
4573      * <pre>
4574      * The architecture of the disk. Valid values are ARM64 or X86_64.
4575      * Check the Architecture enum for the list of possible values.
4576      * </pre>
4577      *
4578      * <code>optional string architecture = 302803283;</code>
4579      *
4580      * @param value The bytes for architecture to set.
4581      * @return This builder for chaining.
4582      */
setArchitectureBytes(com.google.protobuf.ByteString value)4583     public Builder setArchitectureBytes(com.google.protobuf.ByteString value) {
4584       if (value == null) {
4585         throw new NullPointerException();
4586       }
4587       checkByteStringIsUtf8(value);
4588       architecture_ = value;
4589       bitField0_ |= 0x00000001;
4590       onChanged();
4591       return this;
4592     }
4593 
4594     private java.lang.Object creationTimestamp_ = "";
4595     /**
4596      *
4597      *
4598      * <pre>
4599      * [Output Only] Creation timestamp in RFC3339 text format.
4600      * </pre>
4601      *
4602      * <code>optional string creation_timestamp = 30525366;</code>
4603      *
4604      * @return Whether the creationTimestamp field is set.
4605      */
hasCreationTimestamp()4606     public boolean hasCreationTimestamp() {
4607       return ((bitField0_ & 0x00000002) != 0);
4608     }
4609     /**
4610      *
4611      *
4612      * <pre>
4613      * [Output Only] Creation timestamp in RFC3339 text format.
4614      * </pre>
4615      *
4616      * <code>optional string creation_timestamp = 30525366;</code>
4617      *
4618      * @return The creationTimestamp.
4619      */
getCreationTimestamp()4620     public java.lang.String getCreationTimestamp() {
4621       java.lang.Object ref = creationTimestamp_;
4622       if (!(ref instanceof java.lang.String)) {
4623         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
4624         java.lang.String s = bs.toStringUtf8();
4625         creationTimestamp_ = s;
4626         return s;
4627       } else {
4628         return (java.lang.String) ref;
4629       }
4630     }
4631     /**
4632      *
4633      *
4634      * <pre>
4635      * [Output Only] Creation timestamp in RFC3339 text format.
4636      * </pre>
4637      *
4638      * <code>optional string creation_timestamp = 30525366;</code>
4639      *
4640      * @return The bytes for creationTimestamp.
4641      */
getCreationTimestampBytes()4642     public com.google.protobuf.ByteString getCreationTimestampBytes() {
4643       java.lang.Object ref = creationTimestamp_;
4644       if (ref instanceof String) {
4645         com.google.protobuf.ByteString b =
4646             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
4647         creationTimestamp_ = b;
4648         return b;
4649       } else {
4650         return (com.google.protobuf.ByteString) ref;
4651       }
4652     }
4653     /**
4654      *
4655      *
4656      * <pre>
4657      * [Output Only] Creation timestamp in RFC3339 text format.
4658      * </pre>
4659      *
4660      * <code>optional string creation_timestamp = 30525366;</code>
4661      *
4662      * @param value The creationTimestamp to set.
4663      * @return This builder for chaining.
4664      */
setCreationTimestamp(java.lang.String value)4665     public Builder setCreationTimestamp(java.lang.String value) {
4666       if (value == null) {
4667         throw new NullPointerException();
4668       }
4669       creationTimestamp_ = value;
4670       bitField0_ |= 0x00000002;
4671       onChanged();
4672       return this;
4673     }
4674     /**
4675      *
4676      *
4677      * <pre>
4678      * [Output Only] Creation timestamp in RFC3339 text format.
4679      * </pre>
4680      *
4681      * <code>optional string creation_timestamp = 30525366;</code>
4682      *
4683      * @return This builder for chaining.
4684      */
clearCreationTimestamp()4685     public Builder clearCreationTimestamp() {
4686       creationTimestamp_ = getDefaultInstance().getCreationTimestamp();
4687       bitField0_ = (bitField0_ & ~0x00000002);
4688       onChanged();
4689       return this;
4690     }
4691     /**
4692      *
4693      *
4694      * <pre>
4695      * [Output Only] Creation timestamp in RFC3339 text format.
4696      * </pre>
4697      *
4698      * <code>optional string creation_timestamp = 30525366;</code>
4699      *
4700      * @param value The bytes for creationTimestamp to set.
4701      * @return This builder for chaining.
4702      */
setCreationTimestampBytes(com.google.protobuf.ByteString value)4703     public Builder setCreationTimestampBytes(com.google.protobuf.ByteString value) {
4704       if (value == null) {
4705         throw new NullPointerException();
4706       }
4707       checkByteStringIsUtf8(value);
4708       creationTimestamp_ = value;
4709       bitField0_ |= 0x00000002;
4710       onChanged();
4711       return this;
4712     }
4713 
4714     private java.lang.Object description_ = "";
4715     /**
4716      *
4717      *
4718      * <pre>
4719      * An optional description of this resource. Provide this property when you create the resource.
4720      * </pre>
4721      *
4722      * <code>optional string description = 422937596;</code>
4723      *
4724      * @return Whether the description field is set.
4725      */
hasDescription()4726     public boolean hasDescription() {
4727       return ((bitField0_ & 0x00000004) != 0);
4728     }
4729     /**
4730      *
4731      *
4732      * <pre>
4733      * An optional description of this resource. Provide this property when you create the resource.
4734      * </pre>
4735      *
4736      * <code>optional string description = 422937596;</code>
4737      *
4738      * @return The description.
4739      */
getDescription()4740     public java.lang.String getDescription() {
4741       java.lang.Object ref = description_;
4742       if (!(ref instanceof java.lang.String)) {
4743         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
4744         java.lang.String s = bs.toStringUtf8();
4745         description_ = s;
4746         return s;
4747       } else {
4748         return (java.lang.String) ref;
4749       }
4750     }
4751     /**
4752      *
4753      *
4754      * <pre>
4755      * An optional description of this resource. Provide this property when you create the resource.
4756      * </pre>
4757      *
4758      * <code>optional string description = 422937596;</code>
4759      *
4760      * @return The bytes for description.
4761      */
getDescriptionBytes()4762     public com.google.protobuf.ByteString getDescriptionBytes() {
4763       java.lang.Object ref = description_;
4764       if (ref instanceof String) {
4765         com.google.protobuf.ByteString b =
4766             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
4767         description_ = b;
4768         return b;
4769       } else {
4770         return (com.google.protobuf.ByteString) ref;
4771       }
4772     }
4773     /**
4774      *
4775      *
4776      * <pre>
4777      * An optional description of this resource. Provide this property when you create the resource.
4778      * </pre>
4779      *
4780      * <code>optional string description = 422937596;</code>
4781      *
4782      * @param value The description to set.
4783      * @return This builder for chaining.
4784      */
setDescription(java.lang.String value)4785     public Builder setDescription(java.lang.String value) {
4786       if (value == null) {
4787         throw new NullPointerException();
4788       }
4789       description_ = value;
4790       bitField0_ |= 0x00000004;
4791       onChanged();
4792       return this;
4793     }
4794     /**
4795      *
4796      *
4797      * <pre>
4798      * An optional description of this resource. Provide this property when you create the resource.
4799      * </pre>
4800      *
4801      * <code>optional string description = 422937596;</code>
4802      *
4803      * @return This builder for chaining.
4804      */
clearDescription()4805     public Builder clearDescription() {
4806       description_ = getDefaultInstance().getDescription();
4807       bitField0_ = (bitField0_ & ~0x00000004);
4808       onChanged();
4809       return this;
4810     }
4811     /**
4812      *
4813      *
4814      * <pre>
4815      * An optional description of this resource. Provide this property when you create the resource.
4816      * </pre>
4817      *
4818      * <code>optional string description = 422937596;</code>
4819      *
4820      * @param value The bytes for description to set.
4821      * @return This builder for chaining.
4822      */
setDescriptionBytes(com.google.protobuf.ByteString value)4823     public Builder setDescriptionBytes(com.google.protobuf.ByteString value) {
4824       if (value == null) {
4825         throw new NullPointerException();
4826       }
4827       checkByteStringIsUtf8(value);
4828       description_ = value;
4829       bitField0_ |= 0x00000004;
4830       onChanged();
4831       return this;
4832     }
4833 
4834     private com.google.cloud.compute.v1.CustomerEncryptionKey diskEncryptionKey_;
4835     private com.google.protobuf.SingleFieldBuilderV3<
4836             com.google.cloud.compute.v1.CustomerEncryptionKey,
4837             com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
4838             com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>
4839         diskEncryptionKeyBuilder_;
4840     /**
4841      *
4842      *
4843      * <pre>
4844      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
4845      * </pre>
4846      *
4847      * <code>
4848      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
4849      * </code>
4850      *
4851      * @return Whether the diskEncryptionKey field is set.
4852      */
hasDiskEncryptionKey()4853     public boolean hasDiskEncryptionKey() {
4854       return ((bitField0_ & 0x00000008) != 0);
4855     }
4856     /**
4857      *
4858      *
4859      * <pre>
4860      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
4861      * </pre>
4862      *
4863      * <code>
4864      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
4865      * </code>
4866      *
4867      * @return The diskEncryptionKey.
4868      */
getDiskEncryptionKey()4869     public com.google.cloud.compute.v1.CustomerEncryptionKey getDiskEncryptionKey() {
4870       if (diskEncryptionKeyBuilder_ == null) {
4871         return diskEncryptionKey_ == null
4872             ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
4873             : diskEncryptionKey_;
4874       } else {
4875         return diskEncryptionKeyBuilder_.getMessage();
4876       }
4877     }
4878     /**
4879      *
4880      *
4881      * <pre>
4882      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
4883      * </pre>
4884      *
4885      * <code>
4886      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
4887      * </code>
4888      */
setDiskEncryptionKey(com.google.cloud.compute.v1.CustomerEncryptionKey value)4889     public Builder setDiskEncryptionKey(com.google.cloud.compute.v1.CustomerEncryptionKey value) {
4890       if (diskEncryptionKeyBuilder_ == null) {
4891         if (value == null) {
4892           throw new NullPointerException();
4893         }
4894         diskEncryptionKey_ = value;
4895       } else {
4896         diskEncryptionKeyBuilder_.setMessage(value);
4897       }
4898       bitField0_ |= 0x00000008;
4899       onChanged();
4900       return this;
4901     }
4902     /**
4903      *
4904      *
4905      * <pre>
4906      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
4907      * </pre>
4908      *
4909      * <code>
4910      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
4911      * </code>
4912      */
setDiskEncryptionKey( com.google.cloud.compute.v1.CustomerEncryptionKey.Builder builderForValue)4913     public Builder setDiskEncryptionKey(
4914         com.google.cloud.compute.v1.CustomerEncryptionKey.Builder builderForValue) {
4915       if (diskEncryptionKeyBuilder_ == null) {
4916         diskEncryptionKey_ = builderForValue.build();
4917       } else {
4918         diskEncryptionKeyBuilder_.setMessage(builderForValue.build());
4919       }
4920       bitField0_ |= 0x00000008;
4921       onChanged();
4922       return this;
4923     }
4924     /**
4925      *
4926      *
4927      * <pre>
4928      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
4929      * </pre>
4930      *
4931      * <code>
4932      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
4933      * </code>
4934      */
mergeDiskEncryptionKey(com.google.cloud.compute.v1.CustomerEncryptionKey value)4935     public Builder mergeDiskEncryptionKey(com.google.cloud.compute.v1.CustomerEncryptionKey value) {
4936       if (diskEncryptionKeyBuilder_ == null) {
4937         if (((bitField0_ & 0x00000008) != 0)
4938             && diskEncryptionKey_ != null
4939             && diskEncryptionKey_
4940                 != com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()) {
4941           getDiskEncryptionKeyBuilder().mergeFrom(value);
4942         } else {
4943           diskEncryptionKey_ = value;
4944         }
4945       } else {
4946         diskEncryptionKeyBuilder_.mergeFrom(value);
4947       }
4948       bitField0_ |= 0x00000008;
4949       onChanged();
4950       return this;
4951     }
4952     /**
4953      *
4954      *
4955      * <pre>
4956      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
4957      * </pre>
4958      *
4959      * <code>
4960      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
4961      * </code>
4962      */
clearDiskEncryptionKey()4963     public Builder clearDiskEncryptionKey() {
4964       bitField0_ = (bitField0_ & ~0x00000008);
4965       diskEncryptionKey_ = null;
4966       if (diskEncryptionKeyBuilder_ != null) {
4967         diskEncryptionKeyBuilder_.dispose();
4968         diskEncryptionKeyBuilder_ = null;
4969       }
4970       onChanged();
4971       return this;
4972     }
4973     /**
4974      *
4975      *
4976      * <pre>
4977      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
4978      * </pre>
4979      *
4980      * <code>
4981      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
4982      * </code>
4983      */
getDiskEncryptionKeyBuilder()4984     public com.google.cloud.compute.v1.CustomerEncryptionKey.Builder getDiskEncryptionKeyBuilder() {
4985       bitField0_ |= 0x00000008;
4986       onChanged();
4987       return getDiskEncryptionKeyFieldBuilder().getBuilder();
4988     }
4989     /**
4990      *
4991      *
4992      * <pre>
4993      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
4994      * </pre>
4995      *
4996      * <code>
4997      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
4998      * </code>
4999      */
5000     public com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder
getDiskEncryptionKeyOrBuilder()5001         getDiskEncryptionKeyOrBuilder() {
5002       if (diskEncryptionKeyBuilder_ != null) {
5003         return diskEncryptionKeyBuilder_.getMessageOrBuilder();
5004       } else {
5005         return diskEncryptionKey_ == null
5006             ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
5007             : diskEncryptionKey_;
5008       }
5009     }
5010     /**
5011      *
5012      *
5013      * <pre>
5014      * Encrypts the disk using a customer-supplied encryption key or a customer-managed encryption key. Encryption keys do not protect access to metadata of the disk. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later. For example, to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine. After you encrypt a disk with a customer-managed key, the diskEncryptionKey.kmsKeyName is set to a key *version* name once the disk is created. The disk is encrypted with this version of the key. In the response, diskEncryptionKey.kmsKeyName appears in the following format: "diskEncryptionKey.kmsKeyName": "projects/kms_project_id/locations/region/keyRings/ key_region/cryptoKeys/key /cryptoKeysVersions/version If you do not provide an encryption key when creating the disk, then the disk is encrypted using an automatically generated key and you don't need to provide a key to use the disk later.
5015      * </pre>
5016      *
5017      * <code>
5018      * optional .google.cloud.compute.v1.CustomerEncryptionKey disk_encryption_key = 271660677;
5019      * </code>
5020      */
5021     private com.google.protobuf.SingleFieldBuilderV3<
5022             com.google.cloud.compute.v1.CustomerEncryptionKey,
5023             com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
5024             com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>
getDiskEncryptionKeyFieldBuilder()5025         getDiskEncryptionKeyFieldBuilder() {
5026       if (diskEncryptionKeyBuilder_ == null) {
5027         diskEncryptionKeyBuilder_ =
5028             new com.google.protobuf.SingleFieldBuilderV3<
5029                 com.google.cloud.compute.v1.CustomerEncryptionKey,
5030                 com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
5031                 com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>(
5032                 getDiskEncryptionKey(), getParentForChildren(), isClean());
5033         diskEncryptionKey_ = null;
5034       }
5035       return diskEncryptionKeyBuilder_;
5036     }
5037 
5038     private java.util.List<com.google.cloud.compute.v1.GuestOsFeature> guestOsFeatures_ =
5039         java.util.Collections.emptyList();
5040 
ensureGuestOsFeaturesIsMutable()5041     private void ensureGuestOsFeaturesIsMutable() {
5042       if (!((bitField0_ & 0x00000010) != 0)) {
5043         guestOsFeatures_ =
5044             new java.util.ArrayList<com.google.cloud.compute.v1.GuestOsFeature>(guestOsFeatures_);
5045         bitField0_ |= 0x00000010;
5046       }
5047     }
5048 
5049     private com.google.protobuf.RepeatedFieldBuilderV3<
5050             com.google.cloud.compute.v1.GuestOsFeature,
5051             com.google.cloud.compute.v1.GuestOsFeature.Builder,
5052             com.google.cloud.compute.v1.GuestOsFeatureOrBuilder>
5053         guestOsFeaturesBuilder_;
5054 
5055     /**
5056      *
5057      *
5058      * <pre>
5059      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5060      * </pre>
5061      *
5062      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5063      */
getGuestOsFeaturesList()5064     public java.util.List<com.google.cloud.compute.v1.GuestOsFeature> getGuestOsFeaturesList() {
5065       if (guestOsFeaturesBuilder_ == null) {
5066         return java.util.Collections.unmodifiableList(guestOsFeatures_);
5067       } else {
5068         return guestOsFeaturesBuilder_.getMessageList();
5069       }
5070     }
5071     /**
5072      *
5073      *
5074      * <pre>
5075      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5076      * </pre>
5077      *
5078      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5079      */
getGuestOsFeaturesCount()5080     public int getGuestOsFeaturesCount() {
5081       if (guestOsFeaturesBuilder_ == null) {
5082         return guestOsFeatures_.size();
5083       } else {
5084         return guestOsFeaturesBuilder_.getCount();
5085       }
5086     }
5087     /**
5088      *
5089      *
5090      * <pre>
5091      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5092      * </pre>
5093      *
5094      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5095      */
getGuestOsFeatures(int index)5096     public com.google.cloud.compute.v1.GuestOsFeature getGuestOsFeatures(int index) {
5097       if (guestOsFeaturesBuilder_ == null) {
5098         return guestOsFeatures_.get(index);
5099       } else {
5100         return guestOsFeaturesBuilder_.getMessage(index);
5101       }
5102     }
5103     /**
5104      *
5105      *
5106      * <pre>
5107      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5108      * </pre>
5109      *
5110      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5111      */
setGuestOsFeatures(int index, com.google.cloud.compute.v1.GuestOsFeature value)5112     public Builder setGuestOsFeatures(int index, com.google.cloud.compute.v1.GuestOsFeature value) {
5113       if (guestOsFeaturesBuilder_ == null) {
5114         if (value == null) {
5115           throw new NullPointerException();
5116         }
5117         ensureGuestOsFeaturesIsMutable();
5118         guestOsFeatures_.set(index, value);
5119         onChanged();
5120       } else {
5121         guestOsFeaturesBuilder_.setMessage(index, value);
5122       }
5123       return this;
5124     }
5125     /**
5126      *
5127      *
5128      * <pre>
5129      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5130      * </pre>
5131      *
5132      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5133      */
setGuestOsFeatures( int index, com.google.cloud.compute.v1.GuestOsFeature.Builder builderForValue)5134     public Builder setGuestOsFeatures(
5135         int index, com.google.cloud.compute.v1.GuestOsFeature.Builder builderForValue) {
5136       if (guestOsFeaturesBuilder_ == null) {
5137         ensureGuestOsFeaturesIsMutable();
5138         guestOsFeatures_.set(index, builderForValue.build());
5139         onChanged();
5140       } else {
5141         guestOsFeaturesBuilder_.setMessage(index, builderForValue.build());
5142       }
5143       return this;
5144     }
5145     /**
5146      *
5147      *
5148      * <pre>
5149      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5150      * </pre>
5151      *
5152      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5153      */
addGuestOsFeatures(com.google.cloud.compute.v1.GuestOsFeature value)5154     public Builder addGuestOsFeatures(com.google.cloud.compute.v1.GuestOsFeature value) {
5155       if (guestOsFeaturesBuilder_ == null) {
5156         if (value == null) {
5157           throw new NullPointerException();
5158         }
5159         ensureGuestOsFeaturesIsMutable();
5160         guestOsFeatures_.add(value);
5161         onChanged();
5162       } else {
5163         guestOsFeaturesBuilder_.addMessage(value);
5164       }
5165       return this;
5166     }
5167     /**
5168      *
5169      *
5170      * <pre>
5171      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5172      * </pre>
5173      *
5174      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5175      */
addGuestOsFeatures(int index, com.google.cloud.compute.v1.GuestOsFeature value)5176     public Builder addGuestOsFeatures(int index, com.google.cloud.compute.v1.GuestOsFeature value) {
5177       if (guestOsFeaturesBuilder_ == null) {
5178         if (value == null) {
5179           throw new NullPointerException();
5180         }
5181         ensureGuestOsFeaturesIsMutable();
5182         guestOsFeatures_.add(index, value);
5183         onChanged();
5184       } else {
5185         guestOsFeaturesBuilder_.addMessage(index, value);
5186       }
5187       return this;
5188     }
5189     /**
5190      *
5191      *
5192      * <pre>
5193      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5194      * </pre>
5195      *
5196      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5197      */
addGuestOsFeatures( com.google.cloud.compute.v1.GuestOsFeature.Builder builderForValue)5198     public Builder addGuestOsFeatures(
5199         com.google.cloud.compute.v1.GuestOsFeature.Builder builderForValue) {
5200       if (guestOsFeaturesBuilder_ == null) {
5201         ensureGuestOsFeaturesIsMutable();
5202         guestOsFeatures_.add(builderForValue.build());
5203         onChanged();
5204       } else {
5205         guestOsFeaturesBuilder_.addMessage(builderForValue.build());
5206       }
5207       return this;
5208     }
5209     /**
5210      *
5211      *
5212      * <pre>
5213      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5214      * </pre>
5215      *
5216      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5217      */
addGuestOsFeatures( int index, com.google.cloud.compute.v1.GuestOsFeature.Builder builderForValue)5218     public Builder addGuestOsFeatures(
5219         int index, com.google.cloud.compute.v1.GuestOsFeature.Builder builderForValue) {
5220       if (guestOsFeaturesBuilder_ == null) {
5221         ensureGuestOsFeaturesIsMutable();
5222         guestOsFeatures_.add(index, builderForValue.build());
5223         onChanged();
5224       } else {
5225         guestOsFeaturesBuilder_.addMessage(index, builderForValue.build());
5226       }
5227       return this;
5228     }
5229     /**
5230      *
5231      *
5232      * <pre>
5233      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5234      * </pre>
5235      *
5236      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5237      */
addAllGuestOsFeatures( java.lang.Iterable<? extends com.google.cloud.compute.v1.GuestOsFeature> values)5238     public Builder addAllGuestOsFeatures(
5239         java.lang.Iterable<? extends com.google.cloud.compute.v1.GuestOsFeature> values) {
5240       if (guestOsFeaturesBuilder_ == null) {
5241         ensureGuestOsFeaturesIsMutable();
5242         com.google.protobuf.AbstractMessageLite.Builder.addAll(values, guestOsFeatures_);
5243         onChanged();
5244       } else {
5245         guestOsFeaturesBuilder_.addAllMessages(values);
5246       }
5247       return this;
5248     }
5249     /**
5250      *
5251      *
5252      * <pre>
5253      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5254      * </pre>
5255      *
5256      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5257      */
clearGuestOsFeatures()5258     public Builder clearGuestOsFeatures() {
5259       if (guestOsFeaturesBuilder_ == null) {
5260         guestOsFeatures_ = java.util.Collections.emptyList();
5261         bitField0_ = (bitField0_ & ~0x00000010);
5262         onChanged();
5263       } else {
5264         guestOsFeaturesBuilder_.clear();
5265       }
5266       return this;
5267     }
5268     /**
5269      *
5270      *
5271      * <pre>
5272      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5273      * </pre>
5274      *
5275      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5276      */
removeGuestOsFeatures(int index)5277     public Builder removeGuestOsFeatures(int index) {
5278       if (guestOsFeaturesBuilder_ == null) {
5279         ensureGuestOsFeaturesIsMutable();
5280         guestOsFeatures_.remove(index);
5281         onChanged();
5282       } else {
5283         guestOsFeaturesBuilder_.remove(index);
5284       }
5285       return this;
5286     }
5287     /**
5288      *
5289      *
5290      * <pre>
5291      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5292      * </pre>
5293      *
5294      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5295      */
getGuestOsFeaturesBuilder(int index)5296     public com.google.cloud.compute.v1.GuestOsFeature.Builder getGuestOsFeaturesBuilder(int index) {
5297       return getGuestOsFeaturesFieldBuilder().getBuilder(index);
5298     }
5299     /**
5300      *
5301      *
5302      * <pre>
5303      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5304      * </pre>
5305      *
5306      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5307      */
getGuestOsFeaturesOrBuilder( int index)5308     public com.google.cloud.compute.v1.GuestOsFeatureOrBuilder getGuestOsFeaturesOrBuilder(
5309         int index) {
5310       if (guestOsFeaturesBuilder_ == null) {
5311         return guestOsFeatures_.get(index);
5312       } else {
5313         return guestOsFeaturesBuilder_.getMessageOrBuilder(index);
5314       }
5315     }
5316     /**
5317      *
5318      *
5319      * <pre>
5320      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5321      * </pre>
5322      *
5323      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5324      */
5325     public java.util.List<? extends com.google.cloud.compute.v1.GuestOsFeatureOrBuilder>
getGuestOsFeaturesOrBuilderList()5326         getGuestOsFeaturesOrBuilderList() {
5327       if (guestOsFeaturesBuilder_ != null) {
5328         return guestOsFeaturesBuilder_.getMessageOrBuilderList();
5329       } else {
5330         return java.util.Collections.unmodifiableList(guestOsFeatures_);
5331       }
5332     }
5333     /**
5334      *
5335      *
5336      * <pre>
5337      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5338      * </pre>
5339      *
5340      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5341      */
addGuestOsFeaturesBuilder()5342     public com.google.cloud.compute.v1.GuestOsFeature.Builder addGuestOsFeaturesBuilder() {
5343       return getGuestOsFeaturesFieldBuilder()
5344           .addBuilder(com.google.cloud.compute.v1.GuestOsFeature.getDefaultInstance());
5345     }
5346     /**
5347      *
5348      *
5349      * <pre>
5350      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5351      * </pre>
5352      *
5353      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5354      */
addGuestOsFeaturesBuilder(int index)5355     public com.google.cloud.compute.v1.GuestOsFeature.Builder addGuestOsFeaturesBuilder(int index) {
5356       return getGuestOsFeaturesFieldBuilder()
5357           .addBuilder(index, com.google.cloud.compute.v1.GuestOsFeature.getDefaultInstance());
5358     }
5359     /**
5360      *
5361      *
5362      * <pre>
5363      * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.
5364      * </pre>
5365      *
5366      * <code>repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;</code>
5367      */
5368     public java.util.List<com.google.cloud.compute.v1.GuestOsFeature.Builder>
getGuestOsFeaturesBuilderList()5369         getGuestOsFeaturesBuilderList() {
5370       return getGuestOsFeaturesFieldBuilder().getBuilderList();
5371     }
5372 
5373     private com.google.protobuf.RepeatedFieldBuilderV3<
5374             com.google.cloud.compute.v1.GuestOsFeature,
5375             com.google.cloud.compute.v1.GuestOsFeature.Builder,
5376             com.google.cloud.compute.v1.GuestOsFeatureOrBuilder>
getGuestOsFeaturesFieldBuilder()5377         getGuestOsFeaturesFieldBuilder() {
5378       if (guestOsFeaturesBuilder_ == null) {
5379         guestOsFeaturesBuilder_ =
5380             new com.google.protobuf.RepeatedFieldBuilderV3<
5381                 com.google.cloud.compute.v1.GuestOsFeature,
5382                 com.google.cloud.compute.v1.GuestOsFeature.Builder,
5383                 com.google.cloud.compute.v1.GuestOsFeatureOrBuilder>(
5384                 guestOsFeatures_,
5385                 ((bitField0_ & 0x00000010) != 0),
5386                 getParentForChildren(),
5387                 isClean());
5388         guestOsFeatures_ = null;
5389       }
5390       return guestOsFeaturesBuilder_;
5391     }
5392 
5393     private long id_;
5394     /**
5395      *
5396      *
5397      * <pre>
5398      * [Output Only] The unique identifier for the resource. This identifier is defined by the server.
5399      * </pre>
5400      *
5401      * <code>optional uint64 id = 3355;</code>
5402      *
5403      * @return Whether the id field is set.
5404      */
5405     @java.lang.Override
hasId()5406     public boolean hasId() {
5407       return ((bitField0_ & 0x00000020) != 0);
5408     }
5409     /**
5410      *
5411      *
5412      * <pre>
5413      * [Output Only] The unique identifier for the resource. This identifier is defined by the server.
5414      * </pre>
5415      *
5416      * <code>optional uint64 id = 3355;</code>
5417      *
5418      * @return The id.
5419      */
5420     @java.lang.Override
getId()5421     public long getId() {
5422       return id_;
5423     }
5424     /**
5425      *
5426      *
5427      * <pre>
5428      * [Output Only] The unique identifier for the resource. This identifier is defined by the server.
5429      * </pre>
5430      *
5431      * <code>optional uint64 id = 3355;</code>
5432      *
5433      * @param value The id to set.
5434      * @return This builder for chaining.
5435      */
setId(long value)5436     public Builder setId(long value) {
5437 
5438       id_ = value;
5439       bitField0_ |= 0x00000020;
5440       onChanged();
5441       return this;
5442     }
5443     /**
5444      *
5445      *
5446      * <pre>
5447      * [Output Only] The unique identifier for the resource. This identifier is defined by the server.
5448      * </pre>
5449      *
5450      * <code>optional uint64 id = 3355;</code>
5451      *
5452      * @return This builder for chaining.
5453      */
clearId()5454     public Builder clearId() {
5455       bitField0_ = (bitField0_ & ~0x00000020);
5456       id_ = 0L;
5457       onChanged();
5458       return this;
5459     }
5460 
5461     private java.lang.Object kind_ = "";
5462     /**
5463      *
5464      *
5465      * <pre>
5466      * [Output Only] Type of the resource. Always compute#disk for disks.
5467      * </pre>
5468      *
5469      * <code>optional string kind = 3292052;</code>
5470      *
5471      * @return Whether the kind field is set.
5472      */
hasKind()5473     public boolean hasKind() {
5474       return ((bitField0_ & 0x00000040) != 0);
5475     }
5476     /**
5477      *
5478      *
5479      * <pre>
5480      * [Output Only] Type of the resource. Always compute#disk for disks.
5481      * </pre>
5482      *
5483      * <code>optional string kind = 3292052;</code>
5484      *
5485      * @return The kind.
5486      */
getKind()5487     public java.lang.String getKind() {
5488       java.lang.Object ref = kind_;
5489       if (!(ref instanceof java.lang.String)) {
5490         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
5491         java.lang.String s = bs.toStringUtf8();
5492         kind_ = s;
5493         return s;
5494       } else {
5495         return (java.lang.String) ref;
5496       }
5497     }
5498     /**
5499      *
5500      *
5501      * <pre>
5502      * [Output Only] Type of the resource. Always compute#disk for disks.
5503      * </pre>
5504      *
5505      * <code>optional string kind = 3292052;</code>
5506      *
5507      * @return The bytes for kind.
5508      */
getKindBytes()5509     public com.google.protobuf.ByteString getKindBytes() {
5510       java.lang.Object ref = kind_;
5511       if (ref instanceof String) {
5512         com.google.protobuf.ByteString b =
5513             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
5514         kind_ = b;
5515         return b;
5516       } else {
5517         return (com.google.protobuf.ByteString) ref;
5518       }
5519     }
5520     /**
5521      *
5522      *
5523      * <pre>
5524      * [Output Only] Type of the resource. Always compute#disk for disks.
5525      * </pre>
5526      *
5527      * <code>optional string kind = 3292052;</code>
5528      *
5529      * @param value The kind to set.
5530      * @return This builder for chaining.
5531      */
setKind(java.lang.String value)5532     public Builder setKind(java.lang.String value) {
5533       if (value == null) {
5534         throw new NullPointerException();
5535       }
5536       kind_ = value;
5537       bitField0_ |= 0x00000040;
5538       onChanged();
5539       return this;
5540     }
5541     /**
5542      *
5543      *
5544      * <pre>
5545      * [Output Only] Type of the resource. Always compute#disk for disks.
5546      * </pre>
5547      *
5548      * <code>optional string kind = 3292052;</code>
5549      *
5550      * @return This builder for chaining.
5551      */
clearKind()5552     public Builder clearKind() {
5553       kind_ = getDefaultInstance().getKind();
5554       bitField0_ = (bitField0_ & ~0x00000040);
5555       onChanged();
5556       return this;
5557     }
5558     /**
5559      *
5560      *
5561      * <pre>
5562      * [Output Only] Type of the resource. Always compute#disk for disks.
5563      * </pre>
5564      *
5565      * <code>optional string kind = 3292052;</code>
5566      *
5567      * @param value The bytes for kind to set.
5568      * @return This builder for chaining.
5569      */
setKindBytes(com.google.protobuf.ByteString value)5570     public Builder setKindBytes(com.google.protobuf.ByteString value) {
5571       if (value == null) {
5572         throw new NullPointerException();
5573       }
5574       checkByteStringIsUtf8(value);
5575       kind_ = value;
5576       bitField0_ |= 0x00000040;
5577       onChanged();
5578       return this;
5579     }
5580 
5581     private java.lang.Object labelFingerprint_ = "";
5582     /**
5583      *
5584      *
5585      * <pre>
5586      * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
5587      * </pre>
5588      *
5589      * <code>optional string label_fingerprint = 178124825;</code>
5590      *
5591      * @return Whether the labelFingerprint field is set.
5592      */
hasLabelFingerprint()5593     public boolean hasLabelFingerprint() {
5594       return ((bitField0_ & 0x00000080) != 0);
5595     }
5596     /**
5597      *
5598      *
5599      * <pre>
5600      * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
5601      * </pre>
5602      *
5603      * <code>optional string label_fingerprint = 178124825;</code>
5604      *
5605      * @return The labelFingerprint.
5606      */
getLabelFingerprint()5607     public java.lang.String getLabelFingerprint() {
5608       java.lang.Object ref = labelFingerprint_;
5609       if (!(ref instanceof java.lang.String)) {
5610         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
5611         java.lang.String s = bs.toStringUtf8();
5612         labelFingerprint_ = s;
5613         return s;
5614       } else {
5615         return (java.lang.String) ref;
5616       }
5617     }
5618     /**
5619      *
5620      *
5621      * <pre>
5622      * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
5623      * </pre>
5624      *
5625      * <code>optional string label_fingerprint = 178124825;</code>
5626      *
5627      * @return The bytes for labelFingerprint.
5628      */
getLabelFingerprintBytes()5629     public com.google.protobuf.ByteString getLabelFingerprintBytes() {
5630       java.lang.Object ref = labelFingerprint_;
5631       if (ref instanceof String) {
5632         com.google.protobuf.ByteString b =
5633             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
5634         labelFingerprint_ = b;
5635         return b;
5636       } else {
5637         return (com.google.protobuf.ByteString) ref;
5638       }
5639     }
5640     /**
5641      *
5642      *
5643      * <pre>
5644      * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
5645      * </pre>
5646      *
5647      * <code>optional string label_fingerprint = 178124825;</code>
5648      *
5649      * @param value The labelFingerprint to set.
5650      * @return This builder for chaining.
5651      */
setLabelFingerprint(java.lang.String value)5652     public Builder setLabelFingerprint(java.lang.String value) {
5653       if (value == null) {
5654         throw new NullPointerException();
5655       }
5656       labelFingerprint_ = value;
5657       bitField0_ |= 0x00000080;
5658       onChanged();
5659       return this;
5660     }
5661     /**
5662      *
5663      *
5664      * <pre>
5665      * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
5666      * </pre>
5667      *
5668      * <code>optional string label_fingerprint = 178124825;</code>
5669      *
5670      * @return This builder for chaining.
5671      */
clearLabelFingerprint()5672     public Builder clearLabelFingerprint() {
5673       labelFingerprint_ = getDefaultInstance().getLabelFingerprint();
5674       bitField0_ = (bitField0_ & ~0x00000080);
5675       onChanged();
5676       return this;
5677     }
5678     /**
5679      *
5680      *
5681      * <pre>
5682      * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk.
5683      * </pre>
5684      *
5685      * <code>optional string label_fingerprint = 178124825;</code>
5686      *
5687      * @param value The bytes for labelFingerprint to set.
5688      * @return This builder for chaining.
5689      */
setLabelFingerprintBytes(com.google.protobuf.ByteString value)5690     public Builder setLabelFingerprintBytes(com.google.protobuf.ByteString value) {
5691       if (value == null) {
5692         throw new NullPointerException();
5693       }
5694       checkByteStringIsUtf8(value);
5695       labelFingerprint_ = value;
5696       bitField0_ |= 0x00000080;
5697       onChanged();
5698       return this;
5699     }
5700 
5701     private com.google.protobuf.MapField<java.lang.String, java.lang.String> labels_;
5702 
internalGetLabels()5703     private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetLabels() {
5704       if (labels_ == null) {
5705         return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry);
5706       }
5707       return labels_;
5708     }
5709 
5710     private com.google.protobuf.MapField<java.lang.String, java.lang.String>
internalGetMutableLabels()5711         internalGetMutableLabels() {
5712       if (labels_ == null) {
5713         labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry);
5714       }
5715       if (!labels_.isMutable()) {
5716         labels_ = labels_.copy();
5717       }
5718       bitField0_ |= 0x00000100;
5719       onChanged();
5720       return labels_;
5721     }
5722 
getLabelsCount()5723     public int getLabelsCount() {
5724       return internalGetLabels().getMap().size();
5725     }
5726     /**
5727      *
5728      *
5729      * <pre>
5730      * Labels to apply to this disk. These can be later modified by the setLabels method.
5731      * </pre>
5732      *
5733      * <code>map&lt;string, string&gt; labels = 500195327;</code>
5734      */
5735     @java.lang.Override
containsLabels(java.lang.String key)5736     public boolean containsLabels(java.lang.String key) {
5737       if (key == null) {
5738         throw new NullPointerException("map key");
5739       }
5740       return internalGetLabels().getMap().containsKey(key);
5741     }
5742     /** Use {@link #getLabelsMap()} instead. */
5743     @java.lang.Override
5744     @java.lang.Deprecated
getLabels()5745     public java.util.Map<java.lang.String, java.lang.String> getLabels() {
5746       return getLabelsMap();
5747     }
5748     /**
5749      *
5750      *
5751      * <pre>
5752      * Labels to apply to this disk. These can be later modified by the setLabels method.
5753      * </pre>
5754      *
5755      * <code>map&lt;string, string&gt; labels = 500195327;</code>
5756      */
5757     @java.lang.Override
getLabelsMap()5758     public java.util.Map<java.lang.String, java.lang.String> getLabelsMap() {
5759       return internalGetLabels().getMap();
5760     }
5761     /**
5762      *
5763      *
5764      * <pre>
5765      * Labels to apply to this disk. These can be later modified by the setLabels method.
5766      * </pre>
5767      *
5768      * <code>map&lt;string, string&gt; labels = 500195327;</code>
5769      */
5770     @java.lang.Override
getLabelsOrDefault( java.lang.String key, java.lang.String defaultValue)5771     public /* nullable */ java.lang.String getLabelsOrDefault(
5772         java.lang.String key,
5773         /* nullable */
5774         java.lang.String defaultValue) {
5775       if (key == null) {
5776         throw new NullPointerException("map key");
5777       }
5778       java.util.Map<java.lang.String, java.lang.String> map = internalGetLabels().getMap();
5779       return map.containsKey(key) ? map.get(key) : defaultValue;
5780     }
5781     /**
5782      *
5783      *
5784      * <pre>
5785      * Labels to apply to this disk. These can be later modified by the setLabels method.
5786      * </pre>
5787      *
5788      * <code>map&lt;string, string&gt; labels = 500195327;</code>
5789      */
5790     @java.lang.Override
getLabelsOrThrow(java.lang.String key)5791     public java.lang.String getLabelsOrThrow(java.lang.String key) {
5792       if (key == null) {
5793         throw new NullPointerException("map key");
5794       }
5795       java.util.Map<java.lang.String, java.lang.String> map = internalGetLabels().getMap();
5796       if (!map.containsKey(key)) {
5797         throw new java.lang.IllegalArgumentException();
5798       }
5799       return map.get(key);
5800     }
5801 
clearLabels()5802     public Builder clearLabels() {
5803       bitField0_ = (bitField0_ & ~0x00000100);
5804       internalGetMutableLabels().getMutableMap().clear();
5805       return this;
5806     }
5807     /**
5808      *
5809      *
5810      * <pre>
5811      * Labels to apply to this disk. These can be later modified by the setLabels method.
5812      * </pre>
5813      *
5814      * <code>map&lt;string, string&gt; labels = 500195327;</code>
5815      */
removeLabels(java.lang.String key)5816     public Builder removeLabels(java.lang.String key) {
5817       if (key == null) {
5818         throw new NullPointerException("map key");
5819       }
5820       internalGetMutableLabels().getMutableMap().remove(key);
5821       return this;
5822     }
5823     /** Use alternate mutation accessors instead. */
5824     @java.lang.Deprecated
getMutableLabels()5825     public java.util.Map<java.lang.String, java.lang.String> getMutableLabels() {
5826       bitField0_ |= 0x00000100;
5827       return internalGetMutableLabels().getMutableMap();
5828     }
5829     /**
5830      *
5831      *
5832      * <pre>
5833      * Labels to apply to this disk. These can be later modified by the setLabels method.
5834      * </pre>
5835      *
5836      * <code>map&lt;string, string&gt; labels = 500195327;</code>
5837      */
putLabels(java.lang.String key, java.lang.String value)5838     public Builder putLabels(java.lang.String key, java.lang.String value) {
5839       if (key == null) {
5840         throw new NullPointerException("map key");
5841       }
5842       if (value == null) {
5843         throw new NullPointerException("map value");
5844       }
5845       internalGetMutableLabels().getMutableMap().put(key, value);
5846       bitField0_ |= 0x00000100;
5847       return this;
5848     }
5849     /**
5850      *
5851      *
5852      * <pre>
5853      * Labels to apply to this disk. These can be later modified by the setLabels method.
5854      * </pre>
5855      *
5856      * <code>map&lt;string, string&gt; labels = 500195327;</code>
5857      */
putAllLabels(java.util.Map<java.lang.String, java.lang.String> values)5858     public Builder putAllLabels(java.util.Map<java.lang.String, java.lang.String> values) {
5859       internalGetMutableLabels().getMutableMap().putAll(values);
5860       bitField0_ |= 0x00000100;
5861       return this;
5862     }
5863 
5864     private java.lang.Object lastAttachTimestamp_ = "";
5865     /**
5866      *
5867      *
5868      * <pre>
5869      * [Output Only] Last attach timestamp in RFC3339 text format.
5870      * </pre>
5871      *
5872      * <code>optional string last_attach_timestamp = 42159653;</code>
5873      *
5874      * @return Whether the lastAttachTimestamp field is set.
5875      */
hasLastAttachTimestamp()5876     public boolean hasLastAttachTimestamp() {
5877       return ((bitField0_ & 0x00000200) != 0);
5878     }
5879     /**
5880      *
5881      *
5882      * <pre>
5883      * [Output Only] Last attach timestamp in RFC3339 text format.
5884      * </pre>
5885      *
5886      * <code>optional string last_attach_timestamp = 42159653;</code>
5887      *
5888      * @return The lastAttachTimestamp.
5889      */
getLastAttachTimestamp()5890     public java.lang.String getLastAttachTimestamp() {
5891       java.lang.Object ref = lastAttachTimestamp_;
5892       if (!(ref instanceof java.lang.String)) {
5893         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
5894         java.lang.String s = bs.toStringUtf8();
5895         lastAttachTimestamp_ = s;
5896         return s;
5897       } else {
5898         return (java.lang.String) ref;
5899       }
5900     }
5901     /**
5902      *
5903      *
5904      * <pre>
5905      * [Output Only] Last attach timestamp in RFC3339 text format.
5906      * </pre>
5907      *
5908      * <code>optional string last_attach_timestamp = 42159653;</code>
5909      *
5910      * @return The bytes for lastAttachTimestamp.
5911      */
getLastAttachTimestampBytes()5912     public com.google.protobuf.ByteString getLastAttachTimestampBytes() {
5913       java.lang.Object ref = lastAttachTimestamp_;
5914       if (ref instanceof String) {
5915         com.google.protobuf.ByteString b =
5916             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
5917         lastAttachTimestamp_ = b;
5918         return b;
5919       } else {
5920         return (com.google.protobuf.ByteString) ref;
5921       }
5922     }
5923     /**
5924      *
5925      *
5926      * <pre>
5927      * [Output Only] Last attach timestamp in RFC3339 text format.
5928      * </pre>
5929      *
5930      * <code>optional string last_attach_timestamp = 42159653;</code>
5931      *
5932      * @param value The lastAttachTimestamp to set.
5933      * @return This builder for chaining.
5934      */
setLastAttachTimestamp(java.lang.String value)5935     public Builder setLastAttachTimestamp(java.lang.String value) {
5936       if (value == null) {
5937         throw new NullPointerException();
5938       }
5939       lastAttachTimestamp_ = value;
5940       bitField0_ |= 0x00000200;
5941       onChanged();
5942       return this;
5943     }
5944     /**
5945      *
5946      *
5947      * <pre>
5948      * [Output Only] Last attach timestamp in RFC3339 text format.
5949      * </pre>
5950      *
5951      * <code>optional string last_attach_timestamp = 42159653;</code>
5952      *
5953      * @return This builder for chaining.
5954      */
clearLastAttachTimestamp()5955     public Builder clearLastAttachTimestamp() {
5956       lastAttachTimestamp_ = getDefaultInstance().getLastAttachTimestamp();
5957       bitField0_ = (bitField0_ & ~0x00000200);
5958       onChanged();
5959       return this;
5960     }
5961     /**
5962      *
5963      *
5964      * <pre>
5965      * [Output Only] Last attach timestamp in RFC3339 text format.
5966      * </pre>
5967      *
5968      * <code>optional string last_attach_timestamp = 42159653;</code>
5969      *
5970      * @param value The bytes for lastAttachTimestamp to set.
5971      * @return This builder for chaining.
5972      */
setLastAttachTimestampBytes(com.google.protobuf.ByteString value)5973     public Builder setLastAttachTimestampBytes(com.google.protobuf.ByteString value) {
5974       if (value == null) {
5975         throw new NullPointerException();
5976       }
5977       checkByteStringIsUtf8(value);
5978       lastAttachTimestamp_ = value;
5979       bitField0_ |= 0x00000200;
5980       onChanged();
5981       return this;
5982     }
5983 
5984     private java.lang.Object lastDetachTimestamp_ = "";
5985     /**
5986      *
5987      *
5988      * <pre>
5989      * [Output Only] Last detach timestamp in RFC3339 text format.
5990      * </pre>
5991      *
5992      * <code>optional string last_detach_timestamp = 56471027;</code>
5993      *
5994      * @return Whether the lastDetachTimestamp field is set.
5995      */
hasLastDetachTimestamp()5996     public boolean hasLastDetachTimestamp() {
5997       return ((bitField0_ & 0x00000400) != 0);
5998     }
5999     /**
6000      *
6001      *
6002      * <pre>
6003      * [Output Only] Last detach timestamp in RFC3339 text format.
6004      * </pre>
6005      *
6006      * <code>optional string last_detach_timestamp = 56471027;</code>
6007      *
6008      * @return The lastDetachTimestamp.
6009      */
getLastDetachTimestamp()6010     public java.lang.String getLastDetachTimestamp() {
6011       java.lang.Object ref = lastDetachTimestamp_;
6012       if (!(ref instanceof java.lang.String)) {
6013         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
6014         java.lang.String s = bs.toStringUtf8();
6015         lastDetachTimestamp_ = s;
6016         return s;
6017       } else {
6018         return (java.lang.String) ref;
6019       }
6020     }
6021     /**
6022      *
6023      *
6024      * <pre>
6025      * [Output Only] Last detach timestamp in RFC3339 text format.
6026      * </pre>
6027      *
6028      * <code>optional string last_detach_timestamp = 56471027;</code>
6029      *
6030      * @return The bytes for lastDetachTimestamp.
6031      */
getLastDetachTimestampBytes()6032     public com.google.protobuf.ByteString getLastDetachTimestampBytes() {
6033       java.lang.Object ref = lastDetachTimestamp_;
6034       if (ref instanceof String) {
6035         com.google.protobuf.ByteString b =
6036             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
6037         lastDetachTimestamp_ = b;
6038         return b;
6039       } else {
6040         return (com.google.protobuf.ByteString) ref;
6041       }
6042     }
6043     /**
6044      *
6045      *
6046      * <pre>
6047      * [Output Only] Last detach timestamp in RFC3339 text format.
6048      * </pre>
6049      *
6050      * <code>optional string last_detach_timestamp = 56471027;</code>
6051      *
6052      * @param value The lastDetachTimestamp to set.
6053      * @return This builder for chaining.
6054      */
setLastDetachTimestamp(java.lang.String value)6055     public Builder setLastDetachTimestamp(java.lang.String value) {
6056       if (value == null) {
6057         throw new NullPointerException();
6058       }
6059       lastDetachTimestamp_ = value;
6060       bitField0_ |= 0x00000400;
6061       onChanged();
6062       return this;
6063     }
6064     /**
6065      *
6066      *
6067      * <pre>
6068      * [Output Only] Last detach timestamp in RFC3339 text format.
6069      * </pre>
6070      *
6071      * <code>optional string last_detach_timestamp = 56471027;</code>
6072      *
6073      * @return This builder for chaining.
6074      */
clearLastDetachTimestamp()6075     public Builder clearLastDetachTimestamp() {
6076       lastDetachTimestamp_ = getDefaultInstance().getLastDetachTimestamp();
6077       bitField0_ = (bitField0_ & ~0x00000400);
6078       onChanged();
6079       return this;
6080     }
6081     /**
6082      *
6083      *
6084      * <pre>
6085      * [Output Only] Last detach timestamp in RFC3339 text format.
6086      * </pre>
6087      *
6088      * <code>optional string last_detach_timestamp = 56471027;</code>
6089      *
6090      * @param value The bytes for lastDetachTimestamp to set.
6091      * @return This builder for chaining.
6092      */
setLastDetachTimestampBytes(com.google.protobuf.ByteString value)6093     public Builder setLastDetachTimestampBytes(com.google.protobuf.ByteString value) {
6094       if (value == null) {
6095         throw new NullPointerException();
6096       }
6097       checkByteStringIsUtf8(value);
6098       lastDetachTimestamp_ = value;
6099       bitField0_ |= 0x00000400;
6100       onChanged();
6101       return this;
6102     }
6103 
6104     private com.google.protobuf.Internal.LongList licenseCodes_ = emptyLongList();
6105 
ensureLicenseCodesIsMutable()6106     private void ensureLicenseCodesIsMutable() {
6107       if (!((bitField0_ & 0x00000800) != 0)) {
6108         licenseCodes_ = mutableCopy(licenseCodes_);
6109         bitField0_ |= 0x00000800;
6110       }
6111     }
6112     /**
6113      *
6114      *
6115      * <pre>
6116      * Integer license codes indicating which licenses are attached to this disk.
6117      * </pre>
6118      *
6119      * <code>repeated int64 license_codes = 45482664;</code>
6120      *
6121      * @return A list containing the licenseCodes.
6122      */
getLicenseCodesList()6123     public java.util.List<java.lang.Long> getLicenseCodesList() {
6124       return ((bitField0_ & 0x00000800) != 0)
6125           ? java.util.Collections.unmodifiableList(licenseCodes_)
6126           : licenseCodes_;
6127     }
6128     /**
6129      *
6130      *
6131      * <pre>
6132      * Integer license codes indicating which licenses are attached to this disk.
6133      * </pre>
6134      *
6135      * <code>repeated int64 license_codes = 45482664;</code>
6136      *
6137      * @return The count of licenseCodes.
6138      */
getLicenseCodesCount()6139     public int getLicenseCodesCount() {
6140       return licenseCodes_.size();
6141     }
6142     /**
6143      *
6144      *
6145      * <pre>
6146      * Integer license codes indicating which licenses are attached to this disk.
6147      * </pre>
6148      *
6149      * <code>repeated int64 license_codes = 45482664;</code>
6150      *
6151      * @param index The index of the element to return.
6152      * @return The licenseCodes at the given index.
6153      */
getLicenseCodes(int index)6154     public long getLicenseCodes(int index) {
6155       return licenseCodes_.getLong(index);
6156     }
6157     /**
6158      *
6159      *
6160      * <pre>
6161      * Integer license codes indicating which licenses are attached to this disk.
6162      * </pre>
6163      *
6164      * <code>repeated int64 license_codes = 45482664;</code>
6165      *
6166      * @param index The index to set the value at.
6167      * @param value The licenseCodes to set.
6168      * @return This builder for chaining.
6169      */
setLicenseCodes(int index, long value)6170     public Builder setLicenseCodes(int index, long value) {
6171 
6172       ensureLicenseCodesIsMutable();
6173       licenseCodes_.setLong(index, value);
6174       onChanged();
6175       return this;
6176     }
6177     /**
6178      *
6179      *
6180      * <pre>
6181      * Integer license codes indicating which licenses are attached to this disk.
6182      * </pre>
6183      *
6184      * <code>repeated int64 license_codes = 45482664;</code>
6185      *
6186      * @param value The licenseCodes to add.
6187      * @return This builder for chaining.
6188      */
addLicenseCodes(long value)6189     public Builder addLicenseCodes(long value) {
6190 
6191       ensureLicenseCodesIsMutable();
6192       licenseCodes_.addLong(value);
6193       onChanged();
6194       return this;
6195     }
6196     /**
6197      *
6198      *
6199      * <pre>
6200      * Integer license codes indicating which licenses are attached to this disk.
6201      * </pre>
6202      *
6203      * <code>repeated int64 license_codes = 45482664;</code>
6204      *
6205      * @param values The licenseCodes to add.
6206      * @return This builder for chaining.
6207      */
addAllLicenseCodes(java.lang.Iterable<? extends java.lang.Long> values)6208     public Builder addAllLicenseCodes(java.lang.Iterable<? extends java.lang.Long> values) {
6209       ensureLicenseCodesIsMutable();
6210       com.google.protobuf.AbstractMessageLite.Builder.addAll(values, licenseCodes_);
6211       onChanged();
6212       return this;
6213     }
6214     /**
6215      *
6216      *
6217      * <pre>
6218      * Integer license codes indicating which licenses are attached to this disk.
6219      * </pre>
6220      *
6221      * <code>repeated int64 license_codes = 45482664;</code>
6222      *
6223      * @return This builder for chaining.
6224      */
clearLicenseCodes()6225     public Builder clearLicenseCodes() {
6226       licenseCodes_ = emptyLongList();
6227       bitField0_ = (bitField0_ & ~0x00000800);
6228       onChanged();
6229       return this;
6230     }
6231 
6232     private com.google.protobuf.LazyStringList licenses_ =
6233         com.google.protobuf.LazyStringArrayList.EMPTY;
6234 
ensureLicensesIsMutable()6235     private void ensureLicensesIsMutable() {
6236       if (!((bitField0_ & 0x00001000) != 0)) {
6237         licenses_ = new com.google.protobuf.LazyStringArrayList(licenses_);
6238         bitField0_ |= 0x00001000;
6239       }
6240     }
6241     /**
6242      *
6243      *
6244      * <pre>
6245      * A list of publicly visible licenses. Reserved for Google's use.
6246      * </pre>
6247      *
6248      * <code>repeated string licenses = 337642578;</code>
6249      *
6250      * @return A list containing the licenses.
6251      */
getLicensesList()6252     public com.google.protobuf.ProtocolStringList getLicensesList() {
6253       return licenses_.getUnmodifiableView();
6254     }
6255     /**
6256      *
6257      *
6258      * <pre>
6259      * A list of publicly visible licenses. Reserved for Google's use.
6260      * </pre>
6261      *
6262      * <code>repeated string licenses = 337642578;</code>
6263      *
6264      * @return The count of licenses.
6265      */
getLicensesCount()6266     public int getLicensesCount() {
6267       return licenses_.size();
6268     }
6269     /**
6270      *
6271      *
6272      * <pre>
6273      * A list of publicly visible licenses. Reserved for Google's use.
6274      * </pre>
6275      *
6276      * <code>repeated string licenses = 337642578;</code>
6277      *
6278      * @param index The index of the element to return.
6279      * @return The licenses at the given index.
6280      */
getLicenses(int index)6281     public java.lang.String getLicenses(int index) {
6282       return licenses_.get(index);
6283     }
6284     /**
6285      *
6286      *
6287      * <pre>
6288      * A list of publicly visible licenses. Reserved for Google's use.
6289      * </pre>
6290      *
6291      * <code>repeated string licenses = 337642578;</code>
6292      *
6293      * @param index The index of the value to return.
6294      * @return The bytes of the licenses at the given index.
6295      */
getLicensesBytes(int index)6296     public com.google.protobuf.ByteString getLicensesBytes(int index) {
6297       return licenses_.getByteString(index);
6298     }
6299     /**
6300      *
6301      *
6302      * <pre>
6303      * A list of publicly visible licenses. Reserved for Google's use.
6304      * </pre>
6305      *
6306      * <code>repeated string licenses = 337642578;</code>
6307      *
6308      * @param index The index to set the value at.
6309      * @param value The licenses to set.
6310      * @return This builder for chaining.
6311      */
setLicenses(int index, java.lang.String value)6312     public Builder setLicenses(int index, java.lang.String value) {
6313       if (value == null) {
6314         throw new NullPointerException();
6315       }
6316       ensureLicensesIsMutable();
6317       licenses_.set(index, value);
6318       onChanged();
6319       return this;
6320     }
6321     /**
6322      *
6323      *
6324      * <pre>
6325      * A list of publicly visible licenses. Reserved for Google's use.
6326      * </pre>
6327      *
6328      * <code>repeated string licenses = 337642578;</code>
6329      *
6330      * @param value The licenses to add.
6331      * @return This builder for chaining.
6332      */
addLicenses(java.lang.String value)6333     public Builder addLicenses(java.lang.String value) {
6334       if (value == null) {
6335         throw new NullPointerException();
6336       }
6337       ensureLicensesIsMutable();
6338       licenses_.add(value);
6339       onChanged();
6340       return this;
6341     }
6342     /**
6343      *
6344      *
6345      * <pre>
6346      * A list of publicly visible licenses. Reserved for Google's use.
6347      * </pre>
6348      *
6349      * <code>repeated string licenses = 337642578;</code>
6350      *
6351      * @param values The licenses to add.
6352      * @return This builder for chaining.
6353      */
addAllLicenses(java.lang.Iterable<java.lang.String> values)6354     public Builder addAllLicenses(java.lang.Iterable<java.lang.String> values) {
6355       ensureLicensesIsMutable();
6356       com.google.protobuf.AbstractMessageLite.Builder.addAll(values, licenses_);
6357       onChanged();
6358       return this;
6359     }
6360     /**
6361      *
6362      *
6363      * <pre>
6364      * A list of publicly visible licenses. Reserved for Google's use.
6365      * </pre>
6366      *
6367      * <code>repeated string licenses = 337642578;</code>
6368      *
6369      * @return This builder for chaining.
6370      */
clearLicenses()6371     public Builder clearLicenses() {
6372       licenses_ = com.google.protobuf.LazyStringArrayList.EMPTY;
6373       bitField0_ = (bitField0_ & ~0x00001000);
6374       onChanged();
6375       return this;
6376     }
6377     /**
6378      *
6379      *
6380      * <pre>
6381      * A list of publicly visible licenses. Reserved for Google's use.
6382      * </pre>
6383      *
6384      * <code>repeated string licenses = 337642578;</code>
6385      *
6386      * @param value The bytes of the licenses to add.
6387      * @return This builder for chaining.
6388      */
addLicensesBytes(com.google.protobuf.ByteString value)6389     public Builder addLicensesBytes(com.google.protobuf.ByteString value) {
6390       if (value == null) {
6391         throw new NullPointerException();
6392       }
6393       checkByteStringIsUtf8(value);
6394       ensureLicensesIsMutable();
6395       licenses_.add(value);
6396       onChanged();
6397       return this;
6398     }
6399 
6400     private java.lang.Object locationHint_ = "";
6401     /**
6402      *
6403      *
6404      * <pre>
6405      * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
6406      * </pre>
6407      *
6408      * <code>optional string location_hint = 350519505;</code>
6409      *
6410      * @return Whether the locationHint field is set.
6411      */
hasLocationHint()6412     public boolean hasLocationHint() {
6413       return ((bitField0_ & 0x00002000) != 0);
6414     }
6415     /**
6416      *
6417      *
6418      * <pre>
6419      * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
6420      * </pre>
6421      *
6422      * <code>optional string location_hint = 350519505;</code>
6423      *
6424      * @return The locationHint.
6425      */
getLocationHint()6426     public java.lang.String getLocationHint() {
6427       java.lang.Object ref = locationHint_;
6428       if (!(ref instanceof java.lang.String)) {
6429         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
6430         java.lang.String s = bs.toStringUtf8();
6431         locationHint_ = s;
6432         return s;
6433       } else {
6434         return (java.lang.String) ref;
6435       }
6436     }
6437     /**
6438      *
6439      *
6440      * <pre>
6441      * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
6442      * </pre>
6443      *
6444      * <code>optional string location_hint = 350519505;</code>
6445      *
6446      * @return The bytes for locationHint.
6447      */
getLocationHintBytes()6448     public com.google.protobuf.ByteString getLocationHintBytes() {
6449       java.lang.Object ref = locationHint_;
6450       if (ref instanceof String) {
6451         com.google.protobuf.ByteString b =
6452             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
6453         locationHint_ = b;
6454         return b;
6455       } else {
6456         return (com.google.protobuf.ByteString) ref;
6457       }
6458     }
6459     /**
6460      *
6461      *
6462      * <pre>
6463      * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
6464      * </pre>
6465      *
6466      * <code>optional string location_hint = 350519505;</code>
6467      *
6468      * @param value The locationHint to set.
6469      * @return This builder for chaining.
6470      */
setLocationHint(java.lang.String value)6471     public Builder setLocationHint(java.lang.String value) {
6472       if (value == null) {
6473         throw new NullPointerException();
6474       }
6475       locationHint_ = value;
6476       bitField0_ |= 0x00002000;
6477       onChanged();
6478       return this;
6479     }
6480     /**
6481      *
6482      *
6483      * <pre>
6484      * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
6485      * </pre>
6486      *
6487      * <code>optional string location_hint = 350519505;</code>
6488      *
6489      * @return This builder for chaining.
6490      */
clearLocationHint()6491     public Builder clearLocationHint() {
6492       locationHint_ = getDefaultInstance().getLocationHint();
6493       bitField0_ = (bitField0_ & ~0x00002000);
6494       onChanged();
6495       return this;
6496     }
6497     /**
6498      *
6499      *
6500      * <pre>
6501      * An opaque location hint used to place the disk close to other resources. This field is for use by internal tools that use the public API.
6502      * </pre>
6503      *
6504      * <code>optional string location_hint = 350519505;</code>
6505      *
6506      * @param value The bytes for locationHint to set.
6507      * @return This builder for chaining.
6508      */
setLocationHintBytes(com.google.protobuf.ByteString value)6509     public Builder setLocationHintBytes(com.google.protobuf.ByteString value) {
6510       if (value == null) {
6511         throw new NullPointerException();
6512       }
6513       checkByteStringIsUtf8(value);
6514       locationHint_ = value;
6515       bitField0_ |= 0x00002000;
6516       onChanged();
6517       return this;
6518     }
6519 
6520     private java.lang.Object name_ = "";
6521     /**
6522      *
6523      *
6524      * <pre>
6525      * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
6526      * </pre>
6527      *
6528      * <code>optional string name = 3373707;</code>
6529      *
6530      * @return Whether the name field is set.
6531      */
hasName()6532     public boolean hasName() {
6533       return ((bitField0_ & 0x00004000) != 0);
6534     }
6535     /**
6536      *
6537      *
6538      * <pre>
6539      * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
6540      * </pre>
6541      *
6542      * <code>optional string name = 3373707;</code>
6543      *
6544      * @return The name.
6545      */
getName()6546     public java.lang.String getName() {
6547       java.lang.Object ref = name_;
6548       if (!(ref instanceof java.lang.String)) {
6549         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
6550         java.lang.String s = bs.toStringUtf8();
6551         name_ = s;
6552         return s;
6553       } else {
6554         return (java.lang.String) ref;
6555       }
6556     }
6557     /**
6558      *
6559      *
6560      * <pre>
6561      * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
6562      * </pre>
6563      *
6564      * <code>optional string name = 3373707;</code>
6565      *
6566      * @return The bytes for name.
6567      */
getNameBytes()6568     public com.google.protobuf.ByteString getNameBytes() {
6569       java.lang.Object ref = name_;
6570       if (ref instanceof String) {
6571         com.google.protobuf.ByteString b =
6572             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
6573         name_ = b;
6574         return b;
6575       } else {
6576         return (com.google.protobuf.ByteString) ref;
6577       }
6578     }
6579     /**
6580      *
6581      *
6582      * <pre>
6583      * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
6584      * </pre>
6585      *
6586      * <code>optional string name = 3373707;</code>
6587      *
6588      * @param value The name to set.
6589      * @return This builder for chaining.
6590      */
setName(java.lang.String value)6591     public Builder setName(java.lang.String value) {
6592       if (value == null) {
6593         throw new NullPointerException();
6594       }
6595       name_ = value;
6596       bitField0_ |= 0x00004000;
6597       onChanged();
6598       return this;
6599     }
6600     /**
6601      *
6602      *
6603      * <pre>
6604      * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
6605      * </pre>
6606      *
6607      * <code>optional string name = 3373707;</code>
6608      *
6609      * @return This builder for chaining.
6610      */
clearName()6611     public Builder clearName() {
6612       name_ = getDefaultInstance().getName();
6613       bitField0_ = (bitField0_ & ~0x00004000);
6614       onChanged();
6615       return this;
6616     }
6617     /**
6618      *
6619      *
6620      * <pre>
6621      * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
6622      * </pre>
6623      *
6624      * <code>optional string name = 3373707;</code>
6625      *
6626      * @param value The bytes for name to set.
6627      * @return This builder for chaining.
6628      */
setNameBytes(com.google.protobuf.ByteString value)6629     public Builder setNameBytes(com.google.protobuf.ByteString value) {
6630       if (value == null) {
6631         throw new NullPointerException();
6632       }
6633       checkByteStringIsUtf8(value);
6634       name_ = value;
6635       bitField0_ |= 0x00004000;
6636       onChanged();
6637       return this;
6638     }
6639 
6640     private java.lang.Object options_ = "";
6641     /**
6642      *
6643      *
6644      * <pre>
6645      * Internal use only.
6646      * </pre>
6647      *
6648      * <code>optional string options = 361137822;</code>
6649      *
6650      * @return Whether the options field is set.
6651      */
hasOptions()6652     public boolean hasOptions() {
6653       return ((bitField0_ & 0x00008000) != 0);
6654     }
6655     /**
6656      *
6657      *
6658      * <pre>
6659      * Internal use only.
6660      * </pre>
6661      *
6662      * <code>optional string options = 361137822;</code>
6663      *
6664      * @return The options.
6665      */
getOptions()6666     public java.lang.String getOptions() {
6667       java.lang.Object ref = options_;
6668       if (!(ref instanceof java.lang.String)) {
6669         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
6670         java.lang.String s = bs.toStringUtf8();
6671         options_ = s;
6672         return s;
6673       } else {
6674         return (java.lang.String) ref;
6675       }
6676     }
6677     /**
6678      *
6679      *
6680      * <pre>
6681      * Internal use only.
6682      * </pre>
6683      *
6684      * <code>optional string options = 361137822;</code>
6685      *
6686      * @return The bytes for options.
6687      */
getOptionsBytes()6688     public com.google.protobuf.ByteString getOptionsBytes() {
6689       java.lang.Object ref = options_;
6690       if (ref instanceof String) {
6691         com.google.protobuf.ByteString b =
6692             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
6693         options_ = b;
6694         return b;
6695       } else {
6696         return (com.google.protobuf.ByteString) ref;
6697       }
6698     }
6699     /**
6700      *
6701      *
6702      * <pre>
6703      * Internal use only.
6704      * </pre>
6705      *
6706      * <code>optional string options = 361137822;</code>
6707      *
6708      * @param value The options to set.
6709      * @return This builder for chaining.
6710      */
setOptions(java.lang.String value)6711     public Builder setOptions(java.lang.String value) {
6712       if (value == null) {
6713         throw new NullPointerException();
6714       }
6715       options_ = value;
6716       bitField0_ |= 0x00008000;
6717       onChanged();
6718       return this;
6719     }
6720     /**
6721      *
6722      *
6723      * <pre>
6724      * Internal use only.
6725      * </pre>
6726      *
6727      * <code>optional string options = 361137822;</code>
6728      *
6729      * @return This builder for chaining.
6730      */
clearOptions()6731     public Builder clearOptions() {
6732       options_ = getDefaultInstance().getOptions();
6733       bitField0_ = (bitField0_ & ~0x00008000);
6734       onChanged();
6735       return this;
6736     }
6737     /**
6738      *
6739      *
6740      * <pre>
6741      * Internal use only.
6742      * </pre>
6743      *
6744      * <code>optional string options = 361137822;</code>
6745      *
6746      * @param value The bytes for options to set.
6747      * @return This builder for chaining.
6748      */
setOptionsBytes(com.google.protobuf.ByteString value)6749     public Builder setOptionsBytes(com.google.protobuf.ByteString value) {
6750       if (value == null) {
6751         throw new NullPointerException();
6752       }
6753       checkByteStringIsUtf8(value);
6754       options_ = value;
6755       bitField0_ |= 0x00008000;
6756       onChanged();
6757       return this;
6758     }
6759 
6760     private com.google.cloud.compute.v1.DiskParams params_;
6761     private com.google.protobuf.SingleFieldBuilderV3<
6762             com.google.cloud.compute.v1.DiskParams,
6763             com.google.cloud.compute.v1.DiskParams.Builder,
6764             com.google.cloud.compute.v1.DiskParamsOrBuilder>
6765         paramsBuilder_;
6766     /**
6767      *
6768      *
6769      * <pre>
6770      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6771      * </pre>
6772      *
6773      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6774      *
6775      * @return Whether the params field is set.
6776      */
hasParams()6777     public boolean hasParams() {
6778       return ((bitField0_ & 0x00010000) != 0);
6779     }
6780     /**
6781      *
6782      *
6783      * <pre>
6784      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6785      * </pre>
6786      *
6787      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6788      *
6789      * @return The params.
6790      */
getParams()6791     public com.google.cloud.compute.v1.DiskParams getParams() {
6792       if (paramsBuilder_ == null) {
6793         return params_ == null
6794             ? com.google.cloud.compute.v1.DiskParams.getDefaultInstance()
6795             : params_;
6796       } else {
6797         return paramsBuilder_.getMessage();
6798       }
6799     }
6800     /**
6801      *
6802      *
6803      * <pre>
6804      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6805      * </pre>
6806      *
6807      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6808      */
setParams(com.google.cloud.compute.v1.DiskParams value)6809     public Builder setParams(com.google.cloud.compute.v1.DiskParams value) {
6810       if (paramsBuilder_ == null) {
6811         if (value == null) {
6812           throw new NullPointerException();
6813         }
6814         params_ = value;
6815       } else {
6816         paramsBuilder_.setMessage(value);
6817       }
6818       bitField0_ |= 0x00010000;
6819       onChanged();
6820       return this;
6821     }
6822     /**
6823      *
6824      *
6825      * <pre>
6826      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6827      * </pre>
6828      *
6829      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6830      */
setParams(com.google.cloud.compute.v1.DiskParams.Builder builderForValue)6831     public Builder setParams(com.google.cloud.compute.v1.DiskParams.Builder builderForValue) {
6832       if (paramsBuilder_ == null) {
6833         params_ = builderForValue.build();
6834       } else {
6835         paramsBuilder_.setMessage(builderForValue.build());
6836       }
6837       bitField0_ |= 0x00010000;
6838       onChanged();
6839       return this;
6840     }
6841     /**
6842      *
6843      *
6844      * <pre>
6845      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6846      * </pre>
6847      *
6848      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6849      */
mergeParams(com.google.cloud.compute.v1.DiskParams value)6850     public Builder mergeParams(com.google.cloud.compute.v1.DiskParams value) {
6851       if (paramsBuilder_ == null) {
6852         if (((bitField0_ & 0x00010000) != 0)
6853             && params_ != null
6854             && params_ != com.google.cloud.compute.v1.DiskParams.getDefaultInstance()) {
6855           getParamsBuilder().mergeFrom(value);
6856         } else {
6857           params_ = value;
6858         }
6859       } else {
6860         paramsBuilder_.mergeFrom(value);
6861       }
6862       bitField0_ |= 0x00010000;
6863       onChanged();
6864       return this;
6865     }
6866     /**
6867      *
6868      *
6869      * <pre>
6870      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6871      * </pre>
6872      *
6873      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6874      */
clearParams()6875     public Builder clearParams() {
6876       bitField0_ = (bitField0_ & ~0x00010000);
6877       params_ = null;
6878       if (paramsBuilder_ != null) {
6879         paramsBuilder_.dispose();
6880         paramsBuilder_ = null;
6881       }
6882       onChanged();
6883       return this;
6884     }
6885     /**
6886      *
6887      *
6888      * <pre>
6889      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6890      * </pre>
6891      *
6892      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6893      */
getParamsBuilder()6894     public com.google.cloud.compute.v1.DiskParams.Builder getParamsBuilder() {
6895       bitField0_ |= 0x00010000;
6896       onChanged();
6897       return getParamsFieldBuilder().getBuilder();
6898     }
6899     /**
6900      *
6901      *
6902      * <pre>
6903      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6904      * </pre>
6905      *
6906      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6907      */
getParamsOrBuilder()6908     public com.google.cloud.compute.v1.DiskParamsOrBuilder getParamsOrBuilder() {
6909       if (paramsBuilder_ != null) {
6910         return paramsBuilder_.getMessageOrBuilder();
6911       } else {
6912         return params_ == null
6913             ? com.google.cloud.compute.v1.DiskParams.getDefaultInstance()
6914             : params_;
6915       }
6916     }
6917     /**
6918      *
6919      *
6920      * <pre>
6921      * Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
6922      * </pre>
6923      *
6924      * <code>optional .google.cloud.compute.v1.DiskParams params = 78313862;</code>
6925      */
6926     private com.google.protobuf.SingleFieldBuilderV3<
6927             com.google.cloud.compute.v1.DiskParams,
6928             com.google.cloud.compute.v1.DiskParams.Builder,
6929             com.google.cloud.compute.v1.DiskParamsOrBuilder>
getParamsFieldBuilder()6930         getParamsFieldBuilder() {
6931       if (paramsBuilder_ == null) {
6932         paramsBuilder_ =
6933             new com.google.protobuf.SingleFieldBuilderV3<
6934                 com.google.cloud.compute.v1.DiskParams,
6935                 com.google.cloud.compute.v1.DiskParams.Builder,
6936                 com.google.cloud.compute.v1.DiskParamsOrBuilder>(
6937                 getParams(), getParentForChildren(), isClean());
6938         params_ = null;
6939       }
6940       return paramsBuilder_;
6941     }
6942 
6943     private long physicalBlockSizeBytes_;
6944     /**
6945      *
6946      *
6947      * <pre>
6948      * Physical block size of the persistent disk, in bytes. If not present in a request, a default value is used. The currently supported size is 4096, other sizes may be added in the future. If an unsupported value is requested, the error message will list the supported values for the caller's project.
6949      * </pre>
6950      *
6951      * <code>optional int64 physical_block_size_bytes = 420007943;</code>
6952      *
6953      * @return Whether the physicalBlockSizeBytes field is set.
6954      */
6955     @java.lang.Override
hasPhysicalBlockSizeBytes()6956     public boolean hasPhysicalBlockSizeBytes() {
6957       return ((bitField0_ & 0x00020000) != 0);
6958     }
6959     /**
6960      *
6961      *
6962      * <pre>
6963      * Physical block size of the persistent disk, in bytes. If not present in a request, a default value is used. The currently supported size is 4096, other sizes may be added in the future. If an unsupported value is requested, the error message will list the supported values for the caller's project.
6964      * </pre>
6965      *
6966      * <code>optional int64 physical_block_size_bytes = 420007943;</code>
6967      *
6968      * @return The physicalBlockSizeBytes.
6969      */
6970     @java.lang.Override
getPhysicalBlockSizeBytes()6971     public long getPhysicalBlockSizeBytes() {
6972       return physicalBlockSizeBytes_;
6973     }
6974     /**
6975      *
6976      *
6977      * <pre>
6978      * Physical block size of the persistent disk, in bytes. If not present in a request, a default value is used. The currently supported size is 4096, other sizes may be added in the future. If an unsupported value is requested, the error message will list the supported values for the caller's project.
6979      * </pre>
6980      *
6981      * <code>optional int64 physical_block_size_bytes = 420007943;</code>
6982      *
6983      * @param value The physicalBlockSizeBytes to set.
6984      * @return This builder for chaining.
6985      */
setPhysicalBlockSizeBytes(long value)6986     public Builder setPhysicalBlockSizeBytes(long value) {
6987 
6988       physicalBlockSizeBytes_ = value;
6989       bitField0_ |= 0x00020000;
6990       onChanged();
6991       return this;
6992     }
6993     /**
6994      *
6995      *
6996      * <pre>
6997      * Physical block size of the persistent disk, in bytes. If not present in a request, a default value is used. The currently supported size is 4096, other sizes may be added in the future. If an unsupported value is requested, the error message will list the supported values for the caller's project.
6998      * </pre>
6999      *
7000      * <code>optional int64 physical_block_size_bytes = 420007943;</code>
7001      *
7002      * @return This builder for chaining.
7003      */
clearPhysicalBlockSizeBytes()7004     public Builder clearPhysicalBlockSizeBytes() {
7005       bitField0_ = (bitField0_ & ~0x00020000);
7006       physicalBlockSizeBytes_ = 0L;
7007       onChanged();
7008       return this;
7009     }
7010 
7011     private long provisionedIops_;
7012     /**
7013      *
7014      *
7015      * <pre>
7016      * Indicates how many IOPS to provision for the disk. This sets the number of I/O operations per second that the disk can handle. Values must be between 10,000 and 120,000. For more details, see the Extreme persistent disk documentation.
7017      * </pre>
7018      *
7019      * <code>optional int64 provisioned_iops = 186769108;</code>
7020      *
7021      * @return Whether the provisionedIops field is set.
7022      */
7023     @java.lang.Override
hasProvisionedIops()7024     public boolean hasProvisionedIops() {
7025       return ((bitField0_ & 0x00040000) != 0);
7026     }
7027     /**
7028      *
7029      *
7030      * <pre>
7031      * Indicates how many IOPS to provision for the disk. This sets the number of I/O operations per second that the disk can handle. Values must be between 10,000 and 120,000. For more details, see the Extreme persistent disk documentation.
7032      * </pre>
7033      *
7034      * <code>optional int64 provisioned_iops = 186769108;</code>
7035      *
7036      * @return The provisionedIops.
7037      */
7038     @java.lang.Override
getProvisionedIops()7039     public long getProvisionedIops() {
7040       return provisionedIops_;
7041     }
7042     /**
7043      *
7044      *
7045      * <pre>
7046      * Indicates how many IOPS to provision for the disk. This sets the number of I/O operations per second that the disk can handle. Values must be between 10,000 and 120,000. For more details, see the Extreme persistent disk documentation.
7047      * </pre>
7048      *
7049      * <code>optional int64 provisioned_iops = 186769108;</code>
7050      *
7051      * @param value The provisionedIops to set.
7052      * @return This builder for chaining.
7053      */
setProvisionedIops(long value)7054     public Builder setProvisionedIops(long value) {
7055 
7056       provisionedIops_ = value;
7057       bitField0_ |= 0x00040000;
7058       onChanged();
7059       return this;
7060     }
7061     /**
7062      *
7063      *
7064      * <pre>
7065      * Indicates how many IOPS to provision for the disk. This sets the number of I/O operations per second that the disk can handle. Values must be between 10,000 and 120,000. For more details, see the Extreme persistent disk documentation.
7066      * </pre>
7067      *
7068      * <code>optional int64 provisioned_iops = 186769108;</code>
7069      *
7070      * @return This builder for chaining.
7071      */
clearProvisionedIops()7072     public Builder clearProvisionedIops() {
7073       bitField0_ = (bitField0_ & ~0x00040000);
7074       provisionedIops_ = 0L;
7075       onChanged();
7076       return this;
7077     }
7078 
7079     private java.lang.Object region_ = "";
7080     /**
7081      *
7082      *
7083      * <pre>
7084      * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
7085      * </pre>
7086      *
7087      * <code>optional string region = 138946292;</code>
7088      *
7089      * @return Whether the region field is set.
7090      */
hasRegion()7091     public boolean hasRegion() {
7092       return ((bitField0_ & 0x00080000) != 0);
7093     }
7094     /**
7095      *
7096      *
7097      * <pre>
7098      * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
7099      * </pre>
7100      *
7101      * <code>optional string region = 138946292;</code>
7102      *
7103      * @return The region.
7104      */
getRegion()7105     public java.lang.String getRegion() {
7106       java.lang.Object ref = region_;
7107       if (!(ref instanceof java.lang.String)) {
7108         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
7109         java.lang.String s = bs.toStringUtf8();
7110         region_ = s;
7111         return s;
7112       } else {
7113         return (java.lang.String) ref;
7114       }
7115     }
7116     /**
7117      *
7118      *
7119      * <pre>
7120      * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
7121      * </pre>
7122      *
7123      * <code>optional string region = 138946292;</code>
7124      *
7125      * @return The bytes for region.
7126      */
getRegionBytes()7127     public com.google.protobuf.ByteString getRegionBytes() {
7128       java.lang.Object ref = region_;
7129       if (ref instanceof String) {
7130         com.google.protobuf.ByteString b =
7131             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
7132         region_ = b;
7133         return b;
7134       } else {
7135         return (com.google.protobuf.ByteString) ref;
7136       }
7137     }
7138     /**
7139      *
7140      *
7141      * <pre>
7142      * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
7143      * </pre>
7144      *
7145      * <code>optional string region = 138946292;</code>
7146      *
7147      * @param value The region to set.
7148      * @return This builder for chaining.
7149      */
setRegion(java.lang.String value)7150     public Builder setRegion(java.lang.String value) {
7151       if (value == null) {
7152         throw new NullPointerException();
7153       }
7154       region_ = value;
7155       bitField0_ |= 0x00080000;
7156       onChanged();
7157       return this;
7158     }
7159     /**
7160      *
7161      *
7162      * <pre>
7163      * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
7164      * </pre>
7165      *
7166      * <code>optional string region = 138946292;</code>
7167      *
7168      * @return This builder for chaining.
7169      */
clearRegion()7170     public Builder clearRegion() {
7171       region_ = getDefaultInstance().getRegion();
7172       bitField0_ = (bitField0_ & ~0x00080000);
7173       onChanged();
7174       return this;
7175     }
7176     /**
7177      *
7178      *
7179      * <pre>
7180      * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
7181      * </pre>
7182      *
7183      * <code>optional string region = 138946292;</code>
7184      *
7185      * @param value The bytes for region to set.
7186      * @return This builder for chaining.
7187      */
setRegionBytes(com.google.protobuf.ByteString value)7188     public Builder setRegionBytes(com.google.protobuf.ByteString value) {
7189       if (value == null) {
7190         throw new NullPointerException();
7191       }
7192       checkByteStringIsUtf8(value);
7193       region_ = value;
7194       bitField0_ |= 0x00080000;
7195       onChanged();
7196       return this;
7197     }
7198 
7199     private com.google.protobuf.LazyStringList replicaZones_ =
7200         com.google.protobuf.LazyStringArrayList.EMPTY;
7201 
ensureReplicaZonesIsMutable()7202     private void ensureReplicaZonesIsMutable() {
7203       if (!((bitField0_ & 0x00100000) != 0)) {
7204         replicaZones_ = new com.google.protobuf.LazyStringArrayList(replicaZones_);
7205         bitField0_ |= 0x00100000;
7206       }
7207     }
7208     /**
7209      *
7210      *
7211      * <pre>
7212      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7213      * </pre>
7214      *
7215      * <code>repeated string replica_zones = 48438272;</code>
7216      *
7217      * @return A list containing the replicaZones.
7218      */
getReplicaZonesList()7219     public com.google.protobuf.ProtocolStringList getReplicaZonesList() {
7220       return replicaZones_.getUnmodifiableView();
7221     }
7222     /**
7223      *
7224      *
7225      * <pre>
7226      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7227      * </pre>
7228      *
7229      * <code>repeated string replica_zones = 48438272;</code>
7230      *
7231      * @return The count of replicaZones.
7232      */
getReplicaZonesCount()7233     public int getReplicaZonesCount() {
7234       return replicaZones_.size();
7235     }
7236     /**
7237      *
7238      *
7239      * <pre>
7240      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7241      * </pre>
7242      *
7243      * <code>repeated string replica_zones = 48438272;</code>
7244      *
7245      * @param index The index of the element to return.
7246      * @return The replicaZones at the given index.
7247      */
getReplicaZones(int index)7248     public java.lang.String getReplicaZones(int index) {
7249       return replicaZones_.get(index);
7250     }
7251     /**
7252      *
7253      *
7254      * <pre>
7255      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7256      * </pre>
7257      *
7258      * <code>repeated string replica_zones = 48438272;</code>
7259      *
7260      * @param index The index of the value to return.
7261      * @return The bytes of the replicaZones at the given index.
7262      */
getReplicaZonesBytes(int index)7263     public com.google.protobuf.ByteString getReplicaZonesBytes(int index) {
7264       return replicaZones_.getByteString(index);
7265     }
7266     /**
7267      *
7268      *
7269      * <pre>
7270      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7271      * </pre>
7272      *
7273      * <code>repeated string replica_zones = 48438272;</code>
7274      *
7275      * @param index The index to set the value at.
7276      * @param value The replicaZones to set.
7277      * @return This builder for chaining.
7278      */
setReplicaZones(int index, java.lang.String value)7279     public Builder setReplicaZones(int index, java.lang.String value) {
7280       if (value == null) {
7281         throw new NullPointerException();
7282       }
7283       ensureReplicaZonesIsMutable();
7284       replicaZones_.set(index, value);
7285       onChanged();
7286       return this;
7287     }
7288     /**
7289      *
7290      *
7291      * <pre>
7292      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7293      * </pre>
7294      *
7295      * <code>repeated string replica_zones = 48438272;</code>
7296      *
7297      * @param value The replicaZones to add.
7298      * @return This builder for chaining.
7299      */
addReplicaZones(java.lang.String value)7300     public Builder addReplicaZones(java.lang.String value) {
7301       if (value == null) {
7302         throw new NullPointerException();
7303       }
7304       ensureReplicaZonesIsMutable();
7305       replicaZones_.add(value);
7306       onChanged();
7307       return this;
7308     }
7309     /**
7310      *
7311      *
7312      * <pre>
7313      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7314      * </pre>
7315      *
7316      * <code>repeated string replica_zones = 48438272;</code>
7317      *
7318      * @param values The replicaZones to add.
7319      * @return This builder for chaining.
7320      */
addAllReplicaZones(java.lang.Iterable<java.lang.String> values)7321     public Builder addAllReplicaZones(java.lang.Iterable<java.lang.String> values) {
7322       ensureReplicaZonesIsMutable();
7323       com.google.protobuf.AbstractMessageLite.Builder.addAll(values, replicaZones_);
7324       onChanged();
7325       return this;
7326     }
7327     /**
7328      *
7329      *
7330      * <pre>
7331      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7332      * </pre>
7333      *
7334      * <code>repeated string replica_zones = 48438272;</code>
7335      *
7336      * @return This builder for chaining.
7337      */
clearReplicaZones()7338     public Builder clearReplicaZones() {
7339       replicaZones_ = com.google.protobuf.LazyStringArrayList.EMPTY;
7340       bitField0_ = (bitField0_ & ~0x00100000);
7341       onChanged();
7342       return this;
7343     }
7344     /**
7345      *
7346      *
7347      * <pre>
7348      * URLs of the zones where the disk should be replicated to. Only applicable for regional resources.
7349      * </pre>
7350      *
7351      * <code>repeated string replica_zones = 48438272;</code>
7352      *
7353      * @param value The bytes of the replicaZones to add.
7354      * @return This builder for chaining.
7355      */
addReplicaZonesBytes(com.google.protobuf.ByteString value)7356     public Builder addReplicaZonesBytes(com.google.protobuf.ByteString value) {
7357       if (value == null) {
7358         throw new NullPointerException();
7359       }
7360       checkByteStringIsUtf8(value);
7361       ensureReplicaZonesIsMutable();
7362       replicaZones_.add(value);
7363       onChanged();
7364       return this;
7365     }
7366 
7367     private com.google.protobuf.LazyStringList resourcePolicies_ =
7368         com.google.protobuf.LazyStringArrayList.EMPTY;
7369 
ensureResourcePoliciesIsMutable()7370     private void ensureResourcePoliciesIsMutable() {
7371       if (!((bitField0_ & 0x00200000) != 0)) {
7372         resourcePolicies_ = new com.google.protobuf.LazyStringArrayList(resourcePolicies_);
7373         bitField0_ |= 0x00200000;
7374       }
7375     }
7376     /**
7377      *
7378      *
7379      * <pre>
7380      * Resource policies applied to this disk for automatic snapshot creations.
7381      * </pre>
7382      *
7383      * <code>repeated string resource_policies = 22220385;</code>
7384      *
7385      * @return A list containing the resourcePolicies.
7386      */
getResourcePoliciesList()7387     public com.google.protobuf.ProtocolStringList getResourcePoliciesList() {
7388       return resourcePolicies_.getUnmodifiableView();
7389     }
7390     /**
7391      *
7392      *
7393      * <pre>
7394      * Resource policies applied to this disk for automatic snapshot creations.
7395      * </pre>
7396      *
7397      * <code>repeated string resource_policies = 22220385;</code>
7398      *
7399      * @return The count of resourcePolicies.
7400      */
getResourcePoliciesCount()7401     public int getResourcePoliciesCount() {
7402       return resourcePolicies_.size();
7403     }
7404     /**
7405      *
7406      *
7407      * <pre>
7408      * Resource policies applied to this disk for automatic snapshot creations.
7409      * </pre>
7410      *
7411      * <code>repeated string resource_policies = 22220385;</code>
7412      *
7413      * @param index The index of the element to return.
7414      * @return The resourcePolicies at the given index.
7415      */
getResourcePolicies(int index)7416     public java.lang.String getResourcePolicies(int index) {
7417       return resourcePolicies_.get(index);
7418     }
7419     /**
7420      *
7421      *
7422      * <pre>
7423      * Resource policies applied to this disk for automatic snapshot creations.
7424      * </pre>
7425      *
7426      * <code>repeated string resource_policies = 22220385;</code>
7427      *
7428      * @param index The index of the value to return.
7429      * @return The bytes of the resourcePolicies at the given index.
7430      */
getResourcePoliciesBytes(int index)7431     public com.google.protobuf.ByteString getResourcePoliciesBytes(int index) {
7432       return resourcePolicies_.getByteString(index);
7433     }
7434     /**
7435      *
7436      *
7437      * <pre>
7438      * Resource policies applied to this disk for automatic snapshot creations.
7439      * </pre>
7440      *
7441      * <code>repeated string resource_policies = 22220385;</code>
7442      *
7443      * @param index The index to set the value at.
7444      * @param value The resourcePolicies to set.
7445      * @return This builder for chaining.
7446      */
setResourcePolicies(int index, java.lang.String value)7447     public Builder setResourcePolicies(int index, java.lang.String value) {
7448       if (value == null) {
7449         throw new NullPointerException();
7450       }
7451       ensureResourcePoliciesIsMutable();
7452       resourcePolicies_.set(index, value);
7453       onChanged();
7454       return this;
7455     }
7456     /**
7457      *
7458      *
7459      * <pre>
7460      * Resource policies applied to this disk for automatic snapshot creations.
7461      * </pre>
7462      *
7463      * <code>repeated string resource_policies = 22220385;</code>
7464      *
7465      * @param value The resourcePolicies to add.
7466      * @return This builder for chaining.
7467      */
addResourcePolicies(java.lang.String value)7468     public Builder addResourcePolicies(java.lang.String value) {
7469       if (value == null) {
7470         throw new NullPointerException();
7471       }
7472       ensureResourcePoliciesIsMutable();
7473       resourcePolicies_.add(value);
7474       onChanged();
7475       return this;
7476     }
7477     /**
7478      *
7479      *
7480      * <pre>
7481      * Resource policies applied to this disk for automatic snapshot creations.
7482      * </pre>
7483      *
7484      * <code>repeated string resource_policies = 22220385;</code>
7485      *
7486      * @param values The resourcePolicies to add.
7487      * @return This builder for chaining.
7488      */
addAllResourcePolicies(java.lang.Iterable<java.lang.String> values)7489     public Builder addAllResourcePolicies(java.lang.Iterable<java.lang.String> values) {
7490       ensureResourcePoliciesIsMutable();
7491       com.google.protobuf.AbstractMessageLite.Builder.addAll(values, resourcePolicies_);
7492       onChanged();
7493       return this;
7494     }
7495     /**
7496      *
7497      *
7498      * <pre>
7499      * Resource policies applied to this disk for automatic snapshot creations.
7500      * </pre>
7501      *
7502      * <code>repeated string resource_policies = 22220385;</code>
7503      *
7504      * @return This builder for chaining.
7505      */
clearResourcePolicies()7506     public Builder clearResourcePolicies() {
7507       resourcePolicies_ = com.google.protobuf.LazyStringArrayList.EMPTY;
7508       bitField0_ = (bitField0_ & ~0x00200000);
7509       onChanged();
7510       return this;
7511     }
7512     /**
7513      *
7514      *
7515      * <pre>
7516      * Resource policies applied to this disk for automatic snapshot creations.
7517      * </pre>
7518      *
7519      * <code>repeated string resource_policies = 22220385;</code>
7520      *
7521      * @param value The bytes of the resourcePolicies to add.
7522      * @return This builder for chaining.
7523      */
addResourcePoliciesBytes(com.google.protobuf.ByteString value)7524     public Builder addResourcePoliciesBytes(com.google.protobuf.ByteString value) {
7525       if (value == null) {
7526         throw new NullPointerException();
7527       }
7528       checkByteStringIsUtf8(value);
7529       ensureResourcePoliciesIsMutable();
7530       resourcePolicies_.add(value);
7531       onChanged();
7532       return this;
7533     }
7534 
7535     private boolean satisfiesPzs_;
7536     /**
7537      *
7538      *
7539      * <pre>
7540      * [Output Only] Reserved for future use.
7541      * </pre>
7542      *
7543      * <code>optional bool satisfies_pzs = 480964267;</code>
7544      *
7545      * @return Whether the satisfiesPzs field is set.
7546      */
7547     @java.lang.Override
hasSatisfiesPzs()7548     public boolean hasSatisfiesPzs() {
7549       return ((bitField0_ & 0x00400000) != 0);
7550     }
7551     /**
7552      *
7553      *
7554      * <pre>
7555      * [Output Only] Reserved for future use.
7556      * </pre>
7557      *
7558      * <code>optional bool satisfies_pzs = 480964267;</code>
7559      *
7560      * @return The satisfiesPzs.
7561      */
7562     @java.lang.Override
getSatisfiesPzs()7563     public boolean getSatisfiesPzs() {
7564       return satisfiesPzs_;
7565     }
7566     /**
7567      *
7568      *
7569      * <pre>
7570      * [Output Only] Reserved for future use.
7571      * </pre>
7572      *
7573      * <code>optional bool satisfies_pzs = 480964267;</code>
7574      *
7575      * @param value The satisfiesPzs to set.
7576      * @return This builder for chaining.
7577      */
setSatisfiesPzs(boolean value)7578     public Builder setSatisfiesPzs(boolean value) {
7579 
7580       satisfiesPzs_ = value;
7581       bitField0_ |= 0x00400000;
7582       onChanged();
7583       return this;
7584     }
7585     /**
7586      *
7587      *
7588      * <pre>
7589      * [Output Only] Reserved for future use.
7590      * </pre>
7591      *
7592      * <code>optional bool satisfies_pzs = 480964267;</code>
7593      *
7594      * @return This builder for chaining.
7595      */
clearSatisfiesPzs()7596     public Builder clearSatisfiesPzs() {
7597       bitField0_ = (bitField0_ & ~0x00400000);
7598       satisfiesPzs_ = false;
7599       onChanged();
7600       return this;
7601     }
7602 
7603     private java.lang.Object selfLink_ = "";
7604     /**
7605      *
7606      *
7607      * <pre>
7608      * [Output Only] Server-defined fully-qualified URL for this resource.
7609      * </pre>
7610      *
7611      * <code>optional string self_link = 456214797;</code>
7612      *
7613      * @return Whether the selfLink field is set.
7614      */
hasSelfLink()7615     public boolean hasSelfLink() {
7616       return ((bitField0_ & 0x00800000) != 0);
7617     }
7618     /**
7619      *
7620      *
7621      * <pre>
7622      * [Output Only] Server-defined fully-qualified URL for this resource.
7623      * </pre>
7624      *
7625      * <code>optional string self_link = 456214797;</code>
7626      *
7627      * @return The selfLink.
7628      */
getSelfLink()7629     public java.lang.String getSelfLink() {
7630       java.lang.Object ref = selfLink_;
7631       if (!(ref instanceof java.lang.String)) {
7632         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
7633         java.lang.String s = bs.toStringUtf8();
7634         selfLink_ = s;
7635         return s;
7636       } else {
7637         return (java.lang.String) ref;
7638       }
7639     }
7640     /**
7641      *
7642      *
7643      * <pre>
7644      * [Output Only] Server-defined fully-qualified URL for this resource.
7645      * </pre>
7646      *
7647      * <code>optional string self_link = 456214797;</code>
7648      *
7649      * @return The bytes for selfLink.
7650      */
getSelfLinkBytes()7651     public com.google.protobuf.ByteString getSelfLinkBytes() {
7652       java.lang.Object ref = selfLink_;
7653       if (ref instanceof String) {
7654         com.google.protobuf.ByteString b =
7655             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
7656         selfLink_ = b;
7657         return b;
7658       } else {
7659         return (com.google.protobuf.ByteString) ref;
7660       }
7661     }
7662     /**
7663      *
7664      *
7665      * <pre>
7666      * [Output Only] Server-defined fully-qualified URL for this resource.
7667      * </pre>
7668      *
7669      * <code>optional string self_link = 456214797;</code>
7670      *
7671      * @param value The selfLink to set.
7672      * @return This builder for chaining.
7673      */
setSelfLink(java.lang.String value)7674     public Builder setSelfLink(java.lang.String value) {
7675       if (value == null) {
7676         throw new NullPointerException();
7677       }
7678       selfLink_ = value;
7679       bitField0_ |= 0x00800000;
7680       onChanged();
7681       return this;
7682     }
7683     /**
7684      *
7685      *
7686      * <pre>
7687      * [Output Only] Server-defined fully-qualified URL for this resource.
7688      * </pre>
7689      *
7690      * <code>optional string self_link = 456214797;</code>
7691      *
7692      * @return This builder for chaining.
7693      */
clearSelfLink()7694     public Builder clearSelfLink() {
7695       selfLink_ = getDefaultInstance().getSelfLink();
7696       bitField0_ = (bitField0_ & ~0x00800000);
7697       onChanged();
7698       return this;
7699     }
7700     /**
7701      *
7702      *
7703      * <pre>
7704      * [Output Only] Server-defined fully-qualified URL for this resource.
7705      * </pre>
7706      *
7707      * <code>optional string self_link = 456214797;</code>
7708      *
7709      * @param value The bytes for selfLink to set.
7710      * @return This builder for chaining.
7711      */
setSelfLinkBytes(com.google.protobuf.ByteString value)7712     public Builder setSelfLinkBytes(com.google.protobuf.ByteString value) {
7713       if (value == null) {
7714         throw new NullPointerException();
7715       }
7716       checkByteStringIsUtf8(value);
7717       selfLink_ = value;
7718       bitField0_ |= 0x00800000;
7719       onChanged();
7720       return this;
7721     }
7722 
7723     private long sizeGb_;
7724     /**
7725      *
7726      *
7727      * <pre>
7728      * Size, in GB, of the persistent disk. You can specify this field when creating a persistent disk using the sourceImage, sourceSnapshot, or sourceDisk parameter, or specify it alone to create an empty persistent disk. If you specify this field along with a source, the value of sizeGb must not be less than the size of the source. Acceptable values are 1 to 65536, inclusive.
7729      * </pre>
7730      *
7731      * <code>optional int64 size_gb = 494929369;</code>
7732      *
7733      * @return Whether the sizeGb field is set.
7734      */
7735     @java.lang.Override
hasSizeGb()7736     public boolean hasSizeGb() {
7737       return ((bitField0_ & 0x01000000) != 0);
7738     }
7739     /**
7740      *
7741      *
7742      * <pre>
7743      * Size, in GB, of the persistent disk. You can specify this field when creating a persistent disk using the sourceImage, sourceSnapshot, or sourceDisk parameter, or specify it alone to create an empty persistent disk. If you specify this field along with a source, the value of sizeGb must not be less than the size of the source. Acceptable values are 1 to 65536, inclusive.
7744      * </pre>
7745      *
7746      * <code>optional int64 size_gb = 494929369;</code>
7747      *
7748      * @return The sizeGb.
7749      */
7750     @java.lang.Override
getSizeGb()7751     public long getSizeGb() {
7752       return sizeGb_;
7753     }
7754     /**
7755      *
7756      *
7757      * <pre>
7758      * Size, in GB, of the persistent disk. You can specify this field when creating a persistent disk using the sourceImage, sourceSnapshot, or sourceDisk parameter, or specify it alone to create an empty persistent disk. If you specify this field along with a source, the value of sizeGb must not be less than the size of the source. Acceptable values are 1 to 65536, inclusive.
7759      * </pre>
7760      *
7761      * <code>optional int64 size_gb = 494929369;</code>
7762      *
7763      * @param value The sizeGb to set.
7764      * @return This builder for chaining.
7765      */
setSizeGb(long value)7766     public Builder setSizeGb(long value) {
7767 
7768       sizeGb_ = value;
7769       bitField0_ |= 0x01000000;
7770       onChanged();
7771       return this;
7772     }
7773     /**
7774      *
7775      *
7776      * <pre>
7777      * Size, in GB, of the persistent disk. You can specify this field when creating a persistent disk using the sourceImage, sourceSnapshot, or sourceDisk parameter, or specify it alone to create an empty persistent disk. If you specify this field along with a source, the value of sizeGb must not be less than the size of the source. Acceptable values are 1 to 65536, inclusive.
7778      * </pre>
7779      *
7780      * <code>optional int64 size_gb = 494929369;</code>
7781      *
7782      * @return This builder for chaining.
7783      */
clearSizeGb()7784     public Builder clearSizeGb() {
7785       bitField0_ = (bitField0_ & ~0x01000000);
7786       sizeGb_ = 0L;
7787       onChanged();
7788       return this;
7789     }
7790 
7791     private java.lang.Object sourceDisk_ = "";
7792     /**
7793      *
7794      *
7795      * <pre>
7796      * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
7797      * </pre>
7798      *
7799      * <code>optional string source_disk = 451753793;</code>
7800      *
7801      * @return Whether the sourceDisk field is set.
7802      */
hasSourceDisk()7803     public boolean hasSourceDisk() {
7804       return ((bitField0_ & 0x02000000) != 0);
7805     }
7806     /**
7807      *
7808      *
7809      * <pre>
7810      * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
7811      * </pre>
7812      *
7813      * <code>optional string source_disk = 451753793;</code>
7814      *
7815      * @return The sourceDisk.
7816      */
getSourceDisk()7817     public java.lang.String getSourceDisk() {
7818       java.lang.Object ref = sourceDisk_;
7819       if (!(ref instanceof java.lang.String)) {
7820         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
7821         java.lang.String s = bs.toStringUtf8();
7822         sourceDisk_ = s;
7823         return s;
7824       } else {
7825         return (java.lang.String) ref;
7826       }
7827     }
7828     /**
7829      *
7830      *
7831      * <pre>
7832      * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
7833      * </pre>
7834      *
7835      * <code>optional string source_disk = 451753793;</code>
7836      *
7837      * @return The bytes for sourceDisk.
7838      */
getSourceDiskBytes()7839     public com.google.protobuf.ByteString getSourceDiskBytes() {
7840       java.lang.Object ref = sourceDisk_;
7841       if (ref instanceof String) {
7842         com.google.protobuf.ByteString b =
7843             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
7844         sourceDisk_ = b;
7845         return b;
7846       } else {
7847         return (com.google.protobuf.ByteString) ref;
7848       }
7849     }
7850     /**
7851      *
7852      *
7853      * <pre>
7854      * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
7855      * </pre>
7856      *
7857      * <code>optional string source_disk = 451753793;</code>
7858      *
7859      * @param value The sourceDisk to set.
7860      * @return This builder for chaining.
7861      */
setSourceDisk(java.lang.String value)7862     public Builder setSourceDisk(java.lang.String value) {
7863       if (value == null) {
7864         throw new NullPointerException();
7865       }
7866       sourceDisk_ = value;
7867       bitField0_ |= 0x02000000;
7868       onChanged();
7869       return this;
7870     }
7871     /**
7872      *
7873      *
7874      * <pre>
7875      * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
7876      * </pre>
7877      *
7878      * <code>optional string source_disk = 451753793;</code>
7879      *
7880      * @return This builder for chaining.
7881      */
clearSourceDisk()7882     public Builder clearSourceDisk() {
7883       sourceDisk_ = getDefaultInstance().getSourceDisk();
7884       bitField0_ = (bitField0_ & ~0x02000000);
7885       onChanged();
7886       return this;
7887     }
7888     /**
7889      *
7890      *
7891      * <pre>
7892      * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - https://www.googleapis.com/compute/v1/projects/project/regions/region /disks/disk - projects/project/zones/zone/disks/disk - projects/project/regions/region/disks/disk - zones/zone/disks/disk - regions/region/disks/disk
7893      * </pre>
7894      *
7895      * <code>optional string source_disk = 451753793;</code>
7896      *
7897      * @param value The bytes for sourceDisk to set.
7898      * @return This builder for chaining.
7899      */
setSourceDiskBytes(com.google.protobuf.ByteString value)7900     public Builder setSourceDiskBytes(com.google.protobuf.ByteString value) {
7901       if (value == null) {
7902         throw new NullPointerException();
7903       }
7904       checkByteStringIsUtf8(value);
7905       sourceDisk_ = value;
7906       bitField0_ |= 0x02000000;
7907       onChanged();
7908       return this;
7909     }
7910 
7911     private java.lang.Object sourceDiskId_ = "";
7912     /**
7913      *
7914      *
7915      * <pre>
7916      * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
7917      * </pre>
7918      *
7919      * <code>optional string source_disk_id = 454190809;</code>
7920      *
7921      * @return Whether the sourceDiskId field is set.
7922      */
hasSourceDiskId()7923     public boolean hasSourceDiskId() {
7924       return ((bitField0_ & 0x04000000) != 0);
7925     }
7926     /**
7927      *
7928      *
7929      * <pre>
7930      * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
7931      * </pre>
7932      *
7933      * <code>optional string source_disk_id = 454190809;</code>
7934      *
7935      * @return The sourceDiskId.
7936      */
getSourceDiskId()7937     public java.lang.String getSourceDiskId() {
7938       java.lang.Object ref = sourceDiskId_;
7939       if (!(ref instanceof java.lang.String)) {
7940         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
7941         java.lang.String s = bs.toStringUtf8();
7942         sourceDiskId_ = s;
7943         return s;
7944       } else {
7945         return (java.lang.String) ref;
7946       }
7947     }
7948     /**
7949      *
7950      *
7951      * <pre>
7952      * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
7953      * </pre>
7954      *
7955      * <code>optional string source_disk_id = 454190809;</code>
7956      *
7957      * @return The bytes for sourceDiskId.
7958      */
getSourceDiskIdBytes()7959     public com.google.protobuf.ByteString getSourceDiskIdBytes() {
7960       java.lang.Object ref = sourceDiskId_;
7961       if (ref instanceof String) {
7962         com.google.protobuf.ByteString b =
7963             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
7964         sourceDiskId_ = b;
7965         return b;
7966       } else {
7967         return (com.google.protobuf.ByteString) ref;
7968       }
7969     }
7970     /**
7971      *
7972      *
7973      * <pre>
7974      * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
7975      * </pre>
7976      *
7977      * <code>optional string source_disk_id = 454190809;</code>
7978      *
7979      * @param value The sourceDiskId to set.
7980      * @return This builder for chaining.
7981      */
setSourceDiskId(java.lang.String value)7982     public Builder setSourceDiskId(java.lang.String value) {
7983       if (value == null) {
7984         throw new NullPointerException();
7985       }
7986       sourceDiskId_ = value;
7987       bitField0_ |= 0x04000000;
7988       onChanged();
7989       return this;
7990     }
7991     /**
7992      *
7993      *
7994      * <pre>
7995      * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
7996      * </pre>
7997      *
7998      * <code>optional string source_disk_id = 454190809;</code>
7999      *
8000      * @return This builder for chaining.
8001      */
clearSourceDiskId()8002     public Builder clearSourceDiskId() {
8003       sourceDiskId_ = getDefaultInstance().getSourceDiskId();
8004       bitField0_ = (bitField0_ & ~0x04000000);
8005       onChanged();
8006       return this;
8007     }
8008     /**
8009      *
8010      *
8011      * <pre>
8012      * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used.
8013      * </pre>
8014      *
8015      * <code>optional string source_disk_id = 454190809;</code>
8016      *
8017      * @param value The bytes for sourceDiskId to set.
8018      * @return This builder for chaining.
8019      */
setSourceDiskIdBytes(com.google.protobuf.ByteString value)8020     public Builder setSourceDiskIdBytes(com.google.protobuf.ByteString value) {
8021       if (value == null) {
8022         throw new NullPointerException();
8023       }
8024       checkByteStringIsUtf8(value);
8025       sourceDiskId_ = value;
8026       bitField0_ |= 0x04000000;
8027       onChanged();
8028       return this;
8029     }
8030 
8031     private java.lang.Object sourceImage_ = "";
8032     /**
8033      *
8034      *
8035      * <pre>
8036      * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
8037      * </pre>
8038      *
8039      * <code>optional string source_image = 50443319;</code>
8040      *
8041      * @return Whether the sourceImage field is set.
8042      */
hasSourceImage()8043     public boolean hasSourceImage() {
8044       return ((bitField0_ & 0x08000000) != 0);
8045     }
8046     /**
8047      *
8048      *
8049      * <pre>
8050      * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
8051      * </pre>
8052      *
8053      * <code>optional string source_image = 50443319;</code>
8054      *
8055      * @return The sourceImage.
8056      */
getSourceImage()8057     public java.lang.String getSourceImage() {
8058       java.lang.Object ref = sourceImage_;
8059       if (!(ref instanceof java.lang.String)) {
8060         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
8061         java.lang.String s = bs.toStringUtf8();
8062         sourceImage_ = s;
8063         return s;
8064       } else {
8065         return (java.lang.String) ref;
8066       }
8067     }
8068     /**
8069      *
8070      *
8071      * <pre>
8072      * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
8073      * </pre>
8074      *
8075      * <code>optional string source_image = 50443319;</code>
8076      *
8077      * @return The bytes for sourceImage.
8078      */
getSourceImageBytes()8079     public com.google.protobuf.ByteString getSourceImageBytes() {
8080       java.lang.Object ref = sourceImage_;
8081       if (ref instanceof String) {
8082         com.google.protobuf.ByteString b =
8083             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
8084         sourceImage_ = b;
8085         return b;
8086       } else {
8087         return (com.google.protobuf.ByteString) ref;
8088       }
8089     }
8090     /**
8091      *
8092      *
8093      * <pre>
8094      * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
8095      * </pre>
8096      *
8097      * <code>optional string source_image = 50443319;</code>
8098      *
8099      * @param value The sourceImage to set.
8100      * @return This builder for chaining.
8101      */
setSourceImage(java.lang.String value)8102     public Builder setSourceImage(java.lang.String value) {
8103       if (value == null) {
8104         throw new NullPointerException();
8105       }
8106       sourceImage_ = value;
8107       bitField0_ |= 0x08000000;
8108       onChanged();
8109       return this;
8110     }
8111     /**
8112      *
8113      *
8114      * <pre>
8115      * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
8116      * </pre>
8117      *
8118      * <code>optional string source_image = 50443319;</code>
8119      *
8120      * @return This builder for chaining.
8121      */
clearSourceImage()8122     public Builder clearSourceImage() {
8123       sourceImage_ = getDefaultInstance().getSourceImage();
8124       bitField0_ = (bitField0_ & ~0x08000000);
8125       onChanged();
8126       return this;
8127     }
8128     /**
8129      *
8130      *
8131      * <pre>
8132      * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family
8133      * </pre>
8134      *
8135      * <code>optional string source_image = 50443319;</code>
8136      *
8137      * @param value The bytes for sourceImage to set.
8138      * @return This builder for chaining.
8139      */
setSourceImageBytes(com.google.protobuf.ByteString value)8140     public Builder setSourceImageBytes(com.google.protobuf.ByteString value) {
8141       if (value == null) {
8142         throw new NullPointerException();
8143       }
8144       checkByteStringIsUtf8(value);
8145       sourceImage_ = value;
8146       bitField0_ |= 0x08000000;
8147       onChanged();
8148       return this;
8149     }
8150 
8151     private com.google.cloud.compute.v1.CustomerEncryptionKey sourceImageEncryptionKey_;
8152     private com.google.protobuf.SingleFieldBuilderV3<
8153             com.google.cloud.compute.v1.CustomerEncryptionKey,
8154             com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
8155             com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>
8156         sourceImageEncryptionKeyBuilder_;
8157     /**
8158      *
8159      *
8160      * <pre>
8161      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8162      * </pre>
8163      *
8164      * <code>
8165      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8166      * </code>
8167      *
8168      * @return Whether the sourceImageEncryptionKey field is set.
8169      */
hasSourceImageEncryptionKey()8170     public boolean hasSourceImageEncryptionKey() {
8171       return ((bitField0_ & 0x10000000) != 0);
8172     }
8173     /**
8174      *
8175      *
8176      * <pre>
8177      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8178      * </pre>
8179      *
8180      * <code>
8181      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8182      * </code>
8183      *
8184      * @return The sourceImageEncryptionKey.
8185      */
getSourceImageEncryptionKey()8186     public com.google.cloud.compute.v1.CustomerEncryptionKey getSourceImageEncryptionKey() {
8187       if (sourceImageEncryptionKeyBuilder_ == null) {
8188         return sourceImageEncryptionKey_ == null
8189             ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
8190             : sourceImageEncryptionKey_;
8191       } else {
8192         return sourceImageEncryptionKeyBuilder_.getMessage();
8193       }
8194     }
8195     /**
8196      *
8197      *
8198      * <pre>
8199      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8200      * </pre>
8201      *
8202      * <code>
8203      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8204      * </code>
8205      */
setSourceImageEncryptionKey( com.google.cloud.compute.v1.CustomerEncryptionKey value)8206     public Builder setSourceImageEncryptionKey(
8207         com.google.cloud.compute.v1.CustomerEncryptionKey value) {
8208       if (sourceImageEncryptionKeyBuilder_ == null) {
8209         if (value == null) {
8210           throw new NullPointerException();
8211         }
8212         sourceImageEncryptionKey_ = value;
8213       } else {
8214         sourceImageEncryptionKeyBuilder_.setMessage(value);
8215       }
8216       bitField0_ |= 0x10000000;
8217       onChanged();
8218       return this;
8219     }
8220     /**
8221      *
8222      *
8223      * <pre>
8224      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8225      * </pre>
8226      *
8227      * <code>
8228      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8229      * </code>
8230      */
setSourceImageEncryptionKey( com.google.cloud.compute.v1.CustomerEncryptionKey.Builder builderForValue)8231     public Builder setSourceImageEncryptionKey(
8232         com.google.cloud.compute.v1.CustomerEncryptionKey.Builder builderForValue) {
8233       if (sourceImageEncryptionKeyBuilder_ == null) {
8234         sourceImageEncryptionKey_ = builderForValue.build();
8235       } else {
8236         sourceImageEncryptionKeyBuilder_.setMessage(builderForValue.build());
8237       }
8238       bitField0_ |= 0x10000000;
8239       onChanged();
8240       return this;
8241     }
8242     /**
8243      *
8244      *
8245      * <pre>
8246      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8247      * </pre>
8248      *
8249      * <code>
8250      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8251      * </code>
8252      */
mergeSourceImageEncryptionKey( com.google.cloud.compute.v1.CustomerEncryptionKey value)8253     public Builder mergeSourceImageEncryptionKey(
8254         com.google.cloud.compute.v1.CustomerEncryptionKey value) {
8255       if (sourceImageEncryptionKeyBuilder_ == null) {
8256         if (((bitField0_ & 0x10000000) != 0)
8257             && sourceImageEncryptionKey_ != null
8258             && sourceImageEncryptionKey_
8259                 != com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()) {
8260           getSourceImageEncryptionKeyBuilder().mergeFrom(value);
8261         } else {
8262           sourceImageEncryptionKey_ = value;
8263         }
8264       } else {
8265         sourceImageEncryptionKeyBuilder_.mergeFrom(value);
8266       }
8267       bitField0_ |= 0x10000000;
8268       onChanged();
8269       return this;
8270     }
8271     /**
8272      *
8273      *
8274      * <pre>
8275      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8276      * </pre>
8277      *
8278      * <code>
8279      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8280      * </code>
8281      */
clearSourceImageEncryptionKey()8282     public Builder clearSourceImageEncryptionKey() {
8283       bitField0_ = (bitField0_ & ~0x10000000);
8284       sourceImageEncryptionKey_ = null;
8285       if (sourceImageEncryptionKeyBuilder_ != null) {
8286         sourceImageEncryptionKeyBuilder_.dispose();
8287         sourceImageEncryptionKeyBuilder_ = null;
8288       }
8289       onChanged();
8290       return this;
8291     }
8292     /**
8293      *
8294      *
8295      * <pre>
8296      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8297      * </pre>
8298      *
8299      * <code>
8300      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8301      * </code>
8302      */
8303     public com.google.cloud.compute.v1.CustomerEncryptionKey.Builder
getSourceImageEncryptionKeyBuilder()8304         getSourceImageEncryptionKeyBuilder() {
8305       bitField0_ |= 0x10000000;
8306       onChanged();
8307       return getSourceImageEncryptionKeyFieldBuilder().getBuilder();
8308     }
8309     /**
8310      *
8311      *
8312      * <pre>
8313      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8314      * </pre>
8315      *
8316      * <code>
8317      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8318      * </code>
8319      */
8320     public com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder
getSourceImageEncryptionKeyOrBuilder()8321         getSourceImageEncryptionKeyOrBuilder() {
8322       if (sourceImageEncryptionKeyBuilder_ != null) {
8323         return sourceImageEncryptionKeyBuilder_.getMessageOrBuilder();
8324       } else {
8325         return sourceImageEncryptionKey_ == null
8326             ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
8327             : sourceImageEncryptionKey_;
8328       }
8329     }
8330     /**
8331      *
8332      *
8333      * <pre>
8334      * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
8335      * </pre>
8336      *
8337      * <code>
8338      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;
8339      * </code>
8340      */
8341     private com.google.protobuf.SingleFieldBuilderV3<
8342             com.google.cloud.compute.v1.CustomerEncryptionKey,
8343             com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
8344             com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>
getSourceImageEncryptionKeyFieldBuilder()8345         getSourceImageEncryptionKeyFieldBuilder() {
8346       if (sourceImageEncryptionKeyBuilder_ == null) {
8347         sourceImageEncryptionKeyBuilder_ =
8348             new com.google.protobuf.SingleFieldBuilderV3<
8349                 com.google.cloud.compute.v1.CustomerEncryptionKey,
8350                 com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
8351                 com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>(
8352                 getSourceImageEncryptionKey(), getParentForChildren(), isClean());
8353         sourceImageEncryptionKey_ = null;
8354       }
8355       return sourceImageEncryptionKeyBuilder_;
8356     }
8357 
8358     private java.lang.Object sourceImageId_ = "";
8359     /**
8360      *
8361      *
8362      * <pre>
8363      * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
8364      * </pre>
8365      *
8366      * <code>optional string source_image_id = 55328291;</code>
8367      *
8368      * @return Whether the sourceImageId field is set.
8369      */
hasSourceImageId()8370     public boolean hasSourceImageId() {
8371       return ((bitField0_ & 0x20000000) != 0);
8372     }
8373     /**
8374      *
8375      *
8376      * <pre>
8377      * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
8378      * </pre>
8379      *
8380      * <code>optional string source_image_id = 55328291;</code>
8381      *
8382      * @return The sourceImageId.
8383      */
getSourceImageId()8384     public java.lang.String getSourceImageId() {
8385       java.lang.Object ref = sourceImageId_;
8386       if (!(ref instanceof java.lang.String)) {
8387         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
8388         java.lang.String s = bs.toStringUtf8();
8389         sourceImageId_ = s;
8390         return s;
8391       } else {
8392         return (java.lang.String) ref;
8393       }
8394     }
8395     /**
8396      *
8397      *
8398      * <pre>
8399      * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
8400      * </pre>
8401      *
8402      * <code>optional string source_image_id = 55328291;</code>
8403      *
8404      * @return The bytes for sourceImageId.
8405      */
getSourceImageIdBytes()8406     public com.google.protobuf.ByteString getSourceImageIdBytes() {
8407       java.lang.Object ref = sourceImageId_;
8408       if (ref instanceof String) {
8409         com.google.protobuf.ByteString b =
8410             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
8411         sourceImageId_ = b;
8412         return b;
8413       } else {
8414         return (com.google.protobuf.ByteString) ref;
8415       }
8416     }
8417     /**
8418      *
8419      *
8420      * <pre>
8421      * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
8422      * </pre>
8423      *
8424      * <code>optional string source_image_id = 55328291;</code>
8425      *
8426      * @param value The sourceImageId to set.
8427      * @return This builder for chaining.
8428      */
setSourceImageId(java.lang.String value)8429     public Builder setSourceImageId(java.lang.String value) {
8430       if (value == null) {
8431         throw new NullPointerException();
8432       }
8433       sourceImageId_ = value;
8434       bitField0_ |= 0x20000000;
8435       onChanged();
8436       return this;
8437     }
8438     /**
8439      *
8440      *
8441      * <pre>
8442      * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
8443      * </pre>
8444      *
8445      * <code>optional string source_image_id = 55328291;</code>
8446      *
8447      * @return This builder for chaining.
8448      */
clearSourceImageId()8449     public Builder clearSourceImageId() {
8450       sourceImageId_ = getDefaultInstance().getSourceImageId();
8451       bitField0_ = (bitField0_ & ~0x20000000);
8452       onChanged();
8453       return this;
8454     }
8455     /**
8456      *
8457      *
8458      * <pre>
8459      * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used.
8460      * </pre>
8461      *
8462      * <code>optional string source_image_id = 55328291;</code>
8463      *
8464      * @param value The bytes for sourceImageId to set.
8465      * @return This builder for chaining.
8466      */
setSourceImageIdBytes(com.google.protobuf.ByteString value)8467     public Builder setSourceImageIdBytes(com.google.protobuf.ByteString value) {
8468       if (value == null) {
8469         throw new NullPointerException();
8470       }
8471       checkByteStringIsUtf8(value);
8472       sourceImageId_ = value;
8473       bitField0_ |= 0x20000000;
8474       onChanged();
8475       return this;
8476     }
8477 
8478     private java.lang.Object sourceSnapshot_ = "";
8479     /**
8480      *
8481      *
8482      * <pre>
8483      * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
8484      * </pre>
8485      *
8486      * <code>optional string source_snapshot = 126061928;</code>
8487      *
8488      * @return Whether the sourceSnapshot field is set.
8489      */
hasSourceSnapshot()8490     public boolean hasSourceSnapshot() {
8491       return ((bitField0_ & 0x40000000) != 0);
8492     }
8493     /**
8494      *
8495      *
8496      * <pre>
8497      * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
8498      * </pre>
8499      *
8500      * <code>optional string source_snapshot = 126061928;</code>
8501      *
8502      * @return The sourceSnapshot.
8503      */
getSourceSnapshot()8504     public java.lang.String getSourceSnapshot() {
8505       java.lang.Object ref = sourceSnapshot_;
8506       if (!(ref instanceof java.lang.String)) {
8507         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
8508         java.lang.String s = bs.toStringUtf8();
8509         sourceSnapshot_ = s;
8510         return s;
8511       } else {
8512         return (java.lang.String) ref;
8513       }
8514     }
8515     /**
8516      *
8517      *
8518      * <pre>
8519      * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
8520      * </pre>
8521      *
8522      * <code>optional string source_snapshot = 126061928;</code>
8523      *
8524      * @return The bytes for sourceSnapshot.
8525      */
getSourceSnapshotBytes()8526     public com.google.protobuf.ByteString getSourceSnapshotBytes() {
8527       java.lang.Object ref = sourceSnapshot_;
8528       if (ref instanceof String) {
8529         com.google.protobuf.ByteString b =
8530             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
8531         sourceSnapshot_ = b;
8532         return b;
8533       } else {
8534         return (com.google.protobuf.ByteString) ref;
8535       }
8536     }
8537     /**
8538      *
8539      *
8540      * <pre>
8541      * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
8542      * </pre>
8543      *
8544      * <code>optional string source_snapshot = 126061928;</code>
8545      *
8546      * @param value The sourceSnapshot to set.
8547      * @return This builder for chaining.
8548      */
setSourceSnapshot(java.lang.String value)8549     public Builder setSourceSnapshot(java.lang.String value) {
8550       if (value == null) {
8551         throw new NullPointerException();
8552       }
8553       sourceSnapshot_ = value;
8554       bitField0_ |= 0x40000000;
8555       onChanged();
8556       return this;
8557     }
8558     /**
8559      *
8560      *
8561      * <pre>
8562      * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
8563      * </pre>
8564      *
8565      * <code>optional string source_snapshot = 126061928;</code>
8566      *
8567      * @return This builder for chaining.
8568      */
clearSourceSnapshot()8569     public Builder clearSourceSnapshot() {
8570       sourceSnapshot_ = getDefaultInstance().getSourceSnapshot();
8571       bitField0_ = (bitField0_ & ~0x40000000);
8572       onChanged();
8573       return this;
8574     }
8575     /**
8576      *
8577      *
8578      * <pre>
8579      * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project /global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot
8580      * </pre>
8581      *
8582      * <code>optional string source_snapshot = 126061928;</code>
8583      *
8584      * @param value The bytes for sourceSnapshot to set.
8585      * @return This builder for chaining.
8586      */
setSourceSnapshotBytes(com.google.protobuf.ByteString value)8587     public Builder setSourceSnapshotBytes(com.google.protobuf.ByteString value) {
8588       if (value == null) {
8589         throw new NullPointerException();
8590       }
8591       checkByteStringIsUtf8(value);
8592       sourceSnapshot_ = value;
8593       bitField0_ |= 0x40000000;
8594       onChanged();
8595       return this;
8596     }
8597 
8598     private com.google.cloud.compute.v1.CustomerEncryptionKey sourceSnapshotEncryptionKey_;
8599     private com.google.protobuf.SingleFieldBuilderV3<
8600             com.google.cloud.compute.v1.CustomerEncryptionKey,
8601             com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
8602             com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>
8603         sourceSnapshotEncryptionKeyBuilder_;
8604     /**
8605      *
8606      *
8607      * <pre>
8608      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8609      * </pre>
8610      *
8611      * <code>
8612      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8613      * </code>
8614      *
8615      * @return Whether the sourceSnapshotEncryptionKey field is set.
8616      */
hasSourceSnapshotEncryptionKey()8617     public boolean hasSourceSnapshotEncryptionKey() {
8618       return ((bitField0_ & 0x80000000) != 0);
8619     }
8620     /**
8621      *
8622      *
8623      * <pre>
8624      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8625      * </pre>
8626      *
8627      * <code>
8628      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8629      * </code>
8630      *
8631      * @return The sourceSnapshotEncryptionKey.
8632      */
getSourceSnapshotEncryptionKey()8633     public com.google.cloud.compute.v1.CustomerEncryptionKey getSourceSnapshotEncryptionKey() {
8634       if (sourceSnapshotEncryptionKeyBuilder_ == null) {
8635         return sourceSnapshotEncryptionKey_ == null
8636             ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
8637             : sourceSnapshotEncryptionKey_;
8638       } else {
8639         return sourceSnapshotEncryptionKeyBuilder_.getMessage();
8640       }
8641     }
8642     /**
8643      *
8644      *
8645      * <pre>
8646      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8647      * </pre>
8648      *
8649      * <code>
8650      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8651      * </code>
8652      */
setSourceSnapshotEncryptionKey( com.google.cloud.compute.v1.CustomerEncryptionKey value)8653     public Builder setSourceSnapshotEncryptionKey(
8654         com.google.cloud.compute.v1.CustomerEncryptionKey value) {
8655       if (sourceSnapshotEncryptionKeyBuilder_ == null) {
8656         if (value == null) {
8657           throw new NullPointerException();
8658         }
8659         sourceSnapshotEncryptionKey_ = value;
8660       } else {
8661         sourceSnapshotEncryptionKeyBuilder_.setMessage(value);
8662       }
8663       bitField0_ |= 0x80000000;
8664       onChanged();
8665       return this;
8666     }
8667     /**
8668      *
8669      *
8670      * <pre>
8671      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8672      * </pre>
8673      *
8674      * <code>
8675      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8676      * </code>
8677      */
setSourceSnapshotEncryptionKey( com.google.cloud.compute.v1.CustomerEncryptionKey.Builder builderForValue)8678     public Builder setSourceSnapshotEncryptionKey(
8679         com.google.cloud.compute.v1.CustomerEncryptionKey.Builder builderForValue) {
8680       if (sourceSnapshotEncryptionKeyBuilder_ == null) {
8681         sourceSnapshotEncryptionKey_ = builderForValue.build();
8682       } else {
8683         sourceSnapshotEncryptionKeyBuilder_.setMessage(builderForValue.build());
8684       }
8685       bitField0_ |= 0x80000000;
8686       onChanged();
8687       return this;
8688     }
8689     /**
8690      *
8691      *
8692      * <pre>
8693      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8694      * </pre>
8695      *
8696      * <code>
8697      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8698      * </code>
8699      */
mergeSourceSnapshotEncryptionKey( com.google.cloud.compute.v1.CustomerEncryptionKey value)8700     public Builder mergeSourceSnapshotEncryptionKey(
8701         com.google.cloud.compute.v1.CustomerEncryptionKey value) {
8702       if (sourceSnapshotEncryptionKeyBuilder_ == null) {
8703         if (((bitField0_ & 0x80000000) != 0)
8704             && sourceSnapshotEncryptionKey_ != null
8705             && sourceSnapshotEncryptionKey_
8706                 != com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()) {
8707           getSourceSnapshotEncryptionKeyBuilder().mergeFrom(value);
8708         } else {
8709           sourceSnapshotEncryptionKey_ = value;
8710         }
8711       } else {
8712         sourceSnapshotEncryptionKeyBuilder_.mergeFrom(value);
8713       }
8714       bitField0_ |= 0x80000000;
8715       onChanged();
8716       return this;
8717     }
8718     /**
8719      *
8720      *
8721      * <pre>
8722      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8723      * </pre>
8724      *
8725      * <code>
8726      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8727      * </code>
8728      */
clearSourceSnapshotEncryptionKey()8729     public Builder clearSourceSnapshotEncryptionKey() {
8730       bitField0_ = (bitField0_ & ~0x80000000);
8731       sourceSnapshotEncryptionKey_ = null;
8732       if (sourceSnapshotEncryptionKeyBuilder_ != null) {
8733         sourceSnapshotEncryptionKeyBuilder_.dispose();
8734         sourceSnapshotEncryptionKeyBuilder_ = null;
8735       }
8736       onChanged();
8737       return this;
8738     }
8739     /**
8740      *
8741      *
8742      * <pre>
8743      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8744      * </pre>
8745      *
8746      * <code>
8747      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8748      * </code>
8749      */
8750     public com.google.cloud.compute.v1.CustomerEncryptionKey.Builder
getSourceSnapshotEncryptionKeyBuilder()8751         getSourceSnapshotEncryptionKeyBuilder() {
8752       bitField0_ |= 0x80000000;
8753       onChanged();
8754       return getSourceSnapshotEncryptionKeyFieldBuilder().getBuilder();
8755     }
8756     /**
8757      *
8758      *
8759      * <pre>
8760      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8761      * </pre>
8762      *
8763      * <code>
8764      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8765      * </code>
8766      */
8767     public com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder
getSourceSnapshotEncryptionKeyOrBuilder()8768         getSourceSnapshotEncryptionKeyOrBuilder() {
8769       if (sourceSnapshotEncryptionKeyBuilder_ != null) {
8770         return sourceSnapshotEncryptionKeyBuilder_.getMessageOrBuilder();
8771       } else {
8772         return sourceSnapshotEncryptionKey_ == null
8773             ? com.google.cloud.compute.v1.CustomerEncryptionKey.getDefaultInstance()
8774             : sourceSnapshotEncryptionKey_;
8775       }
8776     }
8777     /**
8778      *
8779      *
8780      * <pre>
8781      * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
8782      * </pre>
8783      *
8784      * <code>
8785      * optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;
8786      * </code>
8787      */
8788     private com.google.protobuf.SingleFieldBuilderV3<
8789             com.google.cloud.compute.v1.CustomerEncryptionKey,
8790             com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
8791             com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>
getSourceSnapshotEncryptionKeyFieldBuilder()8792         getSourceSnapshotEncryptionKeyFieldBuilder() {
8793       if (sourceSnapshotEncryptionKeyBuilder_ == null) {
8794         sourceSnapshotEncryptionKeyBuilder_ =
8795             new com.google.protobuf.SingleFieldBuilderV3<
8796                 com.google.cloud.compute.v1.CustomerEncryptionKey,
8797                 com.google.cloud.compute.v1.CustomerEncryptionKey.Builder,
8798                 com.google.cloud.compute.v1.CustomerEncryptionKeyOrBuilder>(
8799                 getSourceSnapshotEncryptionKey(), getParentForChildren(), isClean());
8800         sourceSnapshotEncryptionKey_ = null;
8801       }
8802       return sourceSnapshotEncryptionKeyBuilder_;
8803     }
8804 
8805     private java.lang.Object sourceSnapshotId_ = "";
8806     /**
8807      *
8808      *
8809      * <pre>
8810      * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
8811      * </pre>
8812      *
8813      * <code>optional string source_snapshot_id = 98962258;</code>
8814      *
8815      * @return Whether the sourceSnapshotId field is set.
8816      */
hasSourceSnapshotId()8817     public boolean hasSourceSnapshotId() {
8818       return ((bitField1_ & 0x00000001) != 0);
8819     }
8820     /**
8821      *
8822      *
8823      * <pre>
8824      * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
8825      * </pre>
8826      *
8827      * <code>optional string source_snapshot_id = 98962258;</code>
8828      *
8829      * @return The sourceSnapshotId.
8830      */
getSourceSnapshotId()8831     public java.lang.String getSourceSnapshotId() {
8832       java.lang.Object ref = sourceSnapshotId_;
8833       if (!(ref instanceof java.lang.String)) {
8834         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
8835         java.lang.String s = bs.toStringUtf8();
8836         sourceSnapshotId_ = s;
8837         return s;
8838       } else {
8839         return (java.lang.String) ref;
8840       }
8841     }
8842     /**
8843      *
8844      *
8845      * <pre>
8846      * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
8847      * </pre>
8848      *
8849      * <code>optional string source_snapshot_id = 98962258;</code>
8850      *
8851      * @return The bytes for sourceSnapshotId.
8852      */
getSourceSnapshotIdBytes()8853     public com.google.protobuf.ByteString getSourceSnapshotIdBytes() {
8854       java.lang.Object ref = sourceSnapshotId_;
8855       if (ref instanceof String) {
8856         com.google.protobuf.ByteString b =
8857             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
8858         sourceSnapshotId_ = b;
8859         return b;
8860       } else {
8861         return (com.google.protobuf.ByteString) ref;
8862       }
8863     }
8864     /**
8865      *
8866      *
8867      * <pre>
8868      * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
8869      * </pre>
8870      *
8871      * <code>optional string source_snapshot_id = 98962258;</code>
8872      *
8873      * @param value The sourceSnapshotId to set.
8874      * @return This builder for chaining.
8875      */
setSourceSnapshotId(java.lang.String value)8876     public Builder setSourceSnapshotId(java.lang.String value) {
8877       if (value == null) {
8878         throw new NullPointerException();
8879       }
8880       sourceSnapshotId_ = value;
8881       bitField1_ |= 0x00000001;
8882       onChanged();
8883       return this;
8884     }
8885     /**
8886      *
8887      *
8888      * <pre>
8889      * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
8890      * </pre>
8891      *
8892      * <code>optional string source_snapshot_id = 98962258;</code>
8893      *
8894      * @return This builder for chaining.
8895      */
clearSourceSnapshotId()8896     public Builder clearSourceSnapshotId() {
8897       sourceSnapshotId_ = getDefaultInstance().getSourceSnapshotId();
8898       bitField1_ = (bitField1_ & ~0x00000001);
8899       onChanged();
8900       return this;
8901     }
8902     /**
8903      *
8904      *
8905      * <pre>
8906      * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used.
8907      * </pre>
8908      *
8909      * <code>optional string source_snapshot_id = 98962258;</code>
8910      *
8911      * @param value The bytes for sourceSnapshotId to set.
8912      * @return This builder for chaining.
8913      */
setSourceSnapshotIdBytes(com.google.protobuf.ByteString value)8914     public Builder setSourceSnapshotIdBytes(com.google.protobuf.ByteString value) {
8915       if (value == null) {
8916         throw new NullPointerException();
8917       }
8918       checkByteStringIsUtf8(value);
8919       sourceSnapshotId_ = value;
8920       bitField1_ |= 0x00000001;
8921       onChanged();
8922       return this;
8923     }
8924 
8925     private java.lang.Object sourceStorageObject_ = "";
8926     /**
8927      *
8928      *
8929      * <pre>
8930      * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
8931      * </pre>
8932      *
8933      * <code>optional string source_storage_object = 233052711;</code>
8934      *
8935      * @return Whether the sourceStorageObject field is set.
8936      */
hasSourceStorageObject()8937     public boolean hasSourceStorageObject() {
8938       return ((bitField1_ & 0x00000002) != 0);
8939     }
8940     /**
8941      *
8942      *
8943      * <pre>
8944      * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
8945      * </pre>
8946      *
8947      * <code>optional string source_storage_object = 233052711;</code>
8948      *
8949      * @return The sourceStorageObject.
8950      */
getSourceStorageObject()8951     public java.lang.String getSourceStorageObject() {
8952       java.lang.Object ref = sourceStorageObject_;
8953       if (!(ref instanceof java.lang.String)) {
8954         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
8955         java.lang.String s = bs.toStringUtf8();
8956         sourceStorageObject_ = s;
8957         return s;
8958       } else {
8959         return (java.lang.String) ref;
8960       }
8961     }
8962     /**
8963      *
8964      *
8965      * <pre>
8966      * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
8967      * </pre>
8968      *
8969      * <code>optional string source_storage_object = 233052711;</code>
8970      *
8971      * @return The bytes for sourceStorageObject.
8972      */
getSourceStorageObjectBytes()8973     public com.google.protobuf.ByteString getSourceStorageObjectBytes() {
8974       java.lang.Object ref = sourceStorageObject_;
8975       if (ref instanceof String) {
8976         com.google.protobuf.ByteString b =
8977             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
8978         sourceStorageObject_ = b;
8979         return b;
8980       } else {
8981         return (com.google.protobuf.ByteString) ref;
8982       }
8983     }
8984     /**
8985      *
8986      *
8987      * <pre>
8988      * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
8989      * </pre>
8990      *
8991      * <code>optional string source_storage_object = 233052711;</code>
8992      *
8993      * @param value The sourceStorageObject to set.
8994      * @return This builder for chaining.
8995      */
setSourceStorageObject(java.lang.String value)8996     public Builder setSourceStorageObject(java.lang.String value) {
8997       if (value == null) {
8998         throw new NullPointerException();
8999       }
9000       sourceStorageObject_ = value;
9001       bitField1_ |= 0x00000002;
9002       onChanged();
9003       return this;
9004     }
9005     /**
9006      *
9007      *
9008      * <pre>
9009      * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
9010      * </pre>
9011      *
9012      * <code>optional string source_storage_object = 233052711;</code>
9013      *
9014      * @return This builder for chaining.
9015      */
clearSourceStorageObject()9016     public Builder clearSourceStorageObject() {
9017       sourceStorageObject_ = getDefaultInstance().getSourceStorageObject();
9018       bitField1_ = (bitField1_ & ~0x00000002);
9019       onChanged();
9020       return this;
9021     }
9022     /**
9023      *
9024      *
9025      * <pre>
9026      * The full Google Cloud Storage URI where the disk image is stored. This file must be a gzip-compressed tarball whose name ends in .tar.gz or virtual machine disk whose name ends in vmdk. Valid URIs may start with gs:// or https://storage.googleapis.com/. This flag is not optimized for creating multiple disks from a source storage object. To create many disks from a source storage object, use gcloud compute images import instead.
9027      * </pre>
9028      *
9029      * <code>optional string source_storage_object = 233052711;</code>
9030      *
9031      * @param value The bytes for sourceStorageObject to set.
9032      * @return This builder for chaining.
9033      */
setSourceStorageObjectBytes(com.google.protobuf.ByteString value)9034     public Builder setSourceStorageObjectBytes(com.google.protobuf.ByteString value) {
9035       if (value == null) {
9036         throw new NullPointerException();
9037       }
9038       checkByteStringIsUtf8(value);
9039       sourceStorageObject_ = value;
9040       bitField1_ |= 0x00000002;
9041       onChanged();
9042       return this;
9043     }
9044 
9045     private java.lang.Object status_ = "";
9046     /**
9047      *
9048      *
9049      * <pre>
9050      * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
9051      * Check the Status enum for the list of possible values.
9052      * </pre>
9053      *
9054      * <code>optional string status = 181260274;</code>
9055      *
9056      * @return Whether the status field is set.
9057      */
hasStatus()9058     public boolean hasStatus() {
9059       return ((bitField1_ & 0x00000004) != 0);
9060     }
9061     /**
9062      *
9063      *
9064      * <pre>
9065      * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
9066      * Check the Status enum for the list of possible values.
9067      * </pre>
9068      *
9069      * <code>optional string status = 181260274;</code>
9070      *
9071      * @return The status.
9072      */
getStatus()9073     public java.lang.String getStatus() {
9074       java.lang.Object ref = status_;
9075       if (!(ref instanceof java.lang.String)) {
9076         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
9077         java.lang.String s = bs.toStringUtf8();
9078         status_ = s;
9079         return s;
9080       } else {
9081         return (java.lang.String) ref;
9082       }
9083     }
9084     /**
9085      *
9086      *
9087      * <pre>
9088      * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
9089      * Check the Status enum for the list of possible values.
9090      * </pre>
9091      *
9092      * <code>optional string status = 181260274;</code>
9093      *
9094      * @return The bytes for status.
9095      */
getStatusBytes()9096     public com.google.protobuf.ByteString getStatusBytes() {
9097       java.lang.Object ref = status_;
9098       if (ref instanceof String) {
9099         com.google.protobuf.ByteString b =
9100             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
9101         status_ = b;
9102         return b;
9103       } else {
9104         return (com.google.protobuf.ByteString) ref;
9105       }
9106     }
9107     /**
9108      *
9109      *
9110      * <pre>
9111      * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
9112      * Check the Status enum for the list of possible values.
9113      * </pre>
9114      *
9115      * <code>optional string status = 181260274;</code>
9116      *
9117      * @param value The status to set.
9118      * @return This builder for chaining.
9119      */
setStatus(java.lang.String value)9120     public Builder setStatus(java.lang.String value) {
9121       if (value == null) {
9122         throw new NullPointerException();
9123       }
9124       status_ = value;
9125       bitField1_ |= 0x00000004;
9126       onChanged();
9127       return this;
9128     }
9129     /**
9130      *
9131      *
9132      * <pre>
9133      * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
9134      * Check the Status enum for the list of possible values.
9135      * </pre>
9136      *
9137      * <code>optional string status = 181260274;</code>
9138      *
9139      * @return This builder for chaining.
9140      */
clearStatus()9141     public Builder clearStatus() {
9142       status_ = getDefaultInstance().getStatus();
9143       bitField1_ = (bitField1_ & ~0x00000004);
9144       onChanged();
9145       return this;
9146     }
9147     /**
9148      *
9149      *
9150      * <pre>
9151      * [Output Only] The status of disk creation. - CREATING: Disk is provisioning. - RESTORING: Source data is being copied into the disk. - FAILED: Disk creation failed. - READY: Disk is ready for use. - DELETING: Disk is deleting.
9152      * Check the Status enum for the list of possible values.
9153      * </pre>
9154      *
9155      * <code>optional string status = 181260274;</code>
9156      *
9157      * @param value The bytes for status to set.
9158      * @return This builder for chaining.
9159      */
setStatusBytes(com.google.protobuf.ByteString value)9160     public Builder setStatusBytes(com.google.protobuf.ByteString value) {
9161       if (value == null) {
9162         throw new NullPointerException();
9163       }
9164       checkByteStringIsUtf8(value);
9165       status_ = value;
9166       bitField1_ |= 0x00000004;
9167       onChanged();
9168       return this;
9169     }
9170 
9171     private java.lang.Object type_ = "";
9172     /**
9173      *
9174      *
9175      * <pre>
9176      * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
9177      * </pre>
9178      *
9179      * <code>optional string type = 3575610;</code>
9180      *
9181      * @return Whether the type field is set.
9182      */
hasType()9183     public boolean hasType() {
9184       return ((bitField1_ & 0x00000008) != 0);
9185     }
9186     /**
9187      *
9188      *
9189      * <pre>
9190      * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
9191      * </pre>
9192      *
9193      * <code>optional string type = 3575610;</code>
9194      *
9195      * @return The type.
9196      */
getType()9197     public java.lang.String getType() {
9198       java.lang.Object ref = type_;
9199       if (!(ref instanceof java.lang.String)) {
9200         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
9201         java.lang.String s = bs.toStringUtf8();
9202         type_ = s;
9203         return s;
9204       } else {
9205         return (java.lang.String) ref;
9206       }
9207     }
9208     /**
9209      *
9210      *
9211      * <pre>
9212      * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
9213      * </pre>
9214      *
9215      * <code>optional string type = 3575610;</code>
9216      *
9217      * @return The bytes for type.
9218      */
getTypeBytes()9219     public com.google.protobuf.ByteString getTypeBytes() {
9220       java.lang.Object ref = type_;
9221       if (ref instanceof String) {
9222         com.google.protobuf.ByteString b =
9223             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
9224         type_ = b;
9225         return b;
9226       } else {
9227         return (com.google.protobuf.ByteString) ref;
9228       }
9229     }
9230     /**
9231      *
9232      *
9233      * <pre>
9234      * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
9235      * </pre>
9236      *
9237      * <code>optional string type = 3575610;</code>
9238      *
9239      * @param value The type to set.
9240      * @return This builder for chaining.
9241      */
setType(java.lang.String value)9242     public Builder setType(java.lang.String value) {
9243       if (value == null) {
9244         throw new NullPointerException();
9245       }
9246       type_ = value;
9247       bitField1_ |= 0x00000008;
9248       onChanged();
9249       return this;
9250     }
9251     /**
9252      *
9253      *
9254      * <pre>
9255      * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
9256      * </pre>
9257      *
9258      * <code>optional string type = 3575610;</code>
9259      *
9260      * @return This builder for chaining.
9261      */
clearType()9262     public Builder clearType() {
9263       type_ = getDefaultInstance().getType();
9264       bitField1_ = (bitField1_ & ~0x00000008);
9265       onChanged();
9266       return this;
9267     }
9268     /**
9269      *
9270      *
9271      * <pre>
9272      * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project /zones/zone/diskTypes/pd-ssd . See Persistent disk types.
9273      * </pre>
9274      *
9275      * <code>optional string type = 3575610;</code>
9276      *
9277      * @param value The bytes for type to set.
9278      * @return This builder for chaining.
9279      */
setTypeBytes(com.google.protobuf.ByteString value)9280     public Builder setTypeBytes(com.google.protobuf.ByteString value) {
9281       if (value == null) {
9282         throw new NullPointerException();
9283       }
9284       checkByteStringIsUtf8(value);
9285       type_ = value;
9286       bitField1_ |= 0x00000008;
9287       onChanged();
9288       return this;
9289     }
9290 
9291     private com.google.protobuf.LazyStringList users_ =
9292         com.google.protobuf.LazyStringArrayList.EMPTY;
9293 
ensureUsersIsMutable()9294     private void ensureUsersIsMutable() {
9295       if (!((bitField1_ & 0x00000010) != 0)) {
9296         users_ = new com.google.protobuf.LazyStringArrayList(users_);
9297         bitField1_ |= 0x00000010;
9298       }
9299     }
9300     /**
9301      *
9302      *
9303      * <pre>
9304      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9305      * </pre>
9306      *
9307      * <code>repeated string users = 111578632;</code>
9308      *
9309      * @return A list containing the users.
9310      */
getUsersList()9311     public com.google.protobuf.ProtocolStringList getUsersList() {
9312       return users_.getUnmodifiableView();
9313     }
9314     /**
9315      *
9316      *
9317      * <pre>
9318      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9319      * </pre>
9320      *
9321      * <code>repeated string users = 111578632;</code>
9322      *
9323      * @return The count of users.
9324      */
getUsersCount()9325     public int getUsersCount() {
9326       return users_.size();
9327     }
9328     /**
9329      *
9330      *
9331      * <pre>
9332      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9333      * </pre>
9334      *
9335      * <code>repeated string users = 111578632;</code>
9336      *
9337      * @param index The index of the element to return.
9338      * @return The users at the given index.
9339      */
getUsers(int index)9340     public java.lang.String getUsers(int index) {
9341       return users_.get(index);
9342     }
9343     /**
9344      *
9345      *
9346      * <pre>
9347      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9348      * </pre>
9349      *
9350      * <code>repeated string users = 111578632;</code>
9351      *
9352      * @param index The index of the value to return.
9353      * @return The bytes of the users at the given index.
9354      */
getUsersBytes(int index)9355     public com.google.protobuf.ByteString getUsersBytes(int index) {
9356       return users_.getByteString(index);
9357     }
9358     /**
9359      *
9360      *
9361      * <pre>
9362      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9363      * </pre>
9364      *
9365      * <code>repeated string users = 111578632;</code>
9366      *
9367      * @param index The index to set the value at.
9368      * @param value The users to set.
9369      * @return This builder for chaining.
9370      */
setUsers(int index, java.lang.String value)9371     public Builder setUsers(int index, java.lang.String value) {
9372       if (value == null) {
9373         throw new NullPointerException();
9374       }
9375       ensureUsersIsMutable();
9376       users_.set(index, value);
9377       onChanged();
9378       return this;
9379     }
9380     /**
9381      *
9382      *
9383      * <pre>
9384      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9385      * </pre>
9386      *
9387      * <code>repeated string users = 111578632;</code>
9388      *
9389      * @param value The users to add.
9390      * @return This builder for chaining.
9391      */
addUsers(java.lang.String value)9392     public Builder addUsers(java.lang.String value) {
9393       if (value == null) {
9394         throw new NullPointerException();
9395       }
9396       ensureUsersIsMutable();
9397       users_.add(value);
9398       onChanged();
9399       return this;
9400     }
9401     /**
9402      *
9403      *
9404      * <pre>
9405      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9406      * </pre>
9407      *
9408      * <code>repeated string users = 111578632;</code>
9409      *
9410      * @param values The users to add.
9411      * @return This builder for chaining.
9412      */
addAllUsers(java.lang.Iterable<java.lang.String> values)9413     public Builder addAllUsers(java.lang.Iterable<java.lang.String> values) {
9414       ensureUsersIsMutable();
9415       com.google.protobuf.AbstractMessageLite.Builder.addAll(values, users_);
9416       onChanged();
9417       return this;
9418     }
9419     /**
9420      *
9421      *
9422      * <pre>
9423      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9424      * </pre>
9425      *
9426      * <code>repeated string users = 111578632;</code>
9427      *
9428      * @return This builder for chaining.
9429      */
clearUsers()9430     public Builder clearUsers() {
9431       users_ = com.google.protobuf.LazyStringArrayList.EMPTY;
9432       bitField1_ = (bitField1_ & ~0x00000010);
9433       onChanged();
9434       return this;
9435     }
9436     /**
9437      *
9438      *
9439      * <pre>
9440      * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance
9441      * </pre>
9442      *
9443      * <code>repeated string users = 111578632;</code>
9444      *
9445      * @param value The bytes of the users to add.
9446      * @return This builder for chaining.
9447      */
addUsersBytes(com.google.protobuf.ByteString value)9448     public Builder addUsersBytes(com.google.protobuf.ByteString value) {
9449       if (value == null) {
9450         throw new NullPointerException();
9451       }
9452       checkByteStringIsUtf8(value);
9453       ensureUsersIsMutable();
9454       users_.add(value);
9455       onChanged();
9456       return this;
9457     }
9458 
9459     private java.lang.Object zone_ = "";
9460     /**
9461      *
9462      *
9463      * <pre>
9464      * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
9465      * </pre>
9466      *
9467      * <code>optional string zone = 3744684;</code>
9468      *
9469      * @return Whether the zone field is set.
9470      */
hasZone()9471     public boolean hasZone() {
9472       return ((bitField1_ & 0x00000020) != 0);
9473     }
9474     /**
9475      *
9476      *
9477      * <pre>
9478      * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
9479      * </pre>
9480      *
9481      * <code>optional string zone = 3744684;</code>
9482      *
9483      * @return The zone.
9484      */
getZone()9485     public java.lang.String getZone() {
9486       java.lang.Object ref = zone_;
9487       if (!(ref instanceof java.lang.String)) {
9488         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
9489         java.lang.String s = bs.toStringUtf8();
9490         zone_ = s;
9491         return s;
9492       } else {
9493         return (java.lang.String) ref;
9494       }
9495     }
9496     /**
9497      *
9498      *
9499      * <pre>
9500      * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
9501      * </pre>
9502      *
9503      * <code>optional string zone = 3744684;</code>
9504      *
9505      * @return The bytes for zone.
9506      */
getZoneBytes()9507     public com.google.protobuf.ByteString getZoneBytes() {
9508       java.lang.Object ref = zone_;
9509       if (ref instanceof String) {
9510         com.google.protobuf.ByteString b =
9511             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
9512         zone_ = b;
9513         return b;
9514       } else {
9515         return (com.google.protobuf.ByteString) ref;
9516       }
9517     }
9518     /**
9519      *
9520      *
9521      * <pre>
9522      * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
9523      * </pre>
9524      *
9525      * <code>optional string zone = 3744684;</code>
9526      *
9527      * @param value The zone to set.
9528      * @return This builder for chaining.
9529      */
setZone(java.lang.String value)9530     public Builder setZone(java.lang.String value) {
9531       if (value == null) {
9532         throw new NullPointerException();
9533       }
9534       zone_ = value;
9535       bitField1_ |= 0x00000020;
9536       onChanged();
9537       return this;
9538     }
9539     /**
9540      *
9541      *
9542      * <pre>
9543      * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
9544      * </pre>
9545      *
9546      * <code>optional string zone = 3744684;</code>
9547      *
9548      * @return This builder for chaining.
9549      */
clearZone()9550     public Builder clearZone() {
9551       zone_ = getDefaultInstance().getZone();
9552       bitField1_ = (bitField1_ & ~0x00000020);
9553       onChanged();
9554       return this;
9555     }
9556     /**
9557      *
9558      *
9559      * <pre>
9560      * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
9561      * </pre>
9562      *
9563      * <code>optional string zone = 3744684;</code>
9564      *
9565      * @param value The bytes for zone to set.
9566      * @return This builder for chaining.
9567      */
setZoneBytes(com.google.protobuf.ByteString value)9568     public Builder setZoneBytes(com.google.protobuf.ByteString value) {
9569       if (value == null) {
9570         throw new NullPointerException();
9571       }
9572       checkByteStringIsUtf8(value);
9573       zone_ = value;
9574       bitField1_ |= 0x00000020;
9575       onChanged();
9576       return this;
9577     }
9578 
9579     @java.lang.Override
setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)9580     public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
9581       return super.setUnknownFields(unknownFields);
9582     }
9583 
9584     @java.lang.Override
mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)9585     public final Builder mergeUnknownFields(
9586         final com.google.protobuf.UnknownFieldSet unknownFields) {
9587       return super.mergeUnknownFields(unknownFields);
9588     }
9589 
9590     // @@protoc_insertion_point(builder_scope:google.cloud.compute.v1.Disk)
9591   }
9592 
9593   // @@protoc_insertion_point(class_scope:google.cloud.compute.v1.Disk)
9594   private static final com.google.cloud.compute.v1.Disk DEFAULT_INSTANCE;
9595 
9596   static {
9597     DEFAULT_INSTANCE = new com.google.cloud.compute.v1.Disk();
9598   }
9599 
getDefaultInstance()9600   public static com.google.cloud.compute.v1.Disk getDefaultInstance() {
9601     return DEFAULT_INSTANCE;
9602   }
9603 
9604   private static final com.google.protobuf.Parser<Disk> PARSER =
9605       new com.google.protobuf.AbstractParser<Disk>() {
9606         @java.lang.Override
9607         public Disk parsePartialFrom(
9608             com.google.protobuf.CodedInputStream input,
9609             com.google.protobuf.ExtensionRegistryLite extensionRegistry)
9610             throws com.google.protobuf.InvalidProtocolBufferException {
9611           Builder builder = newBuilder();
9612           try {
9613             builder.mergeFrom(input, extensionRegistry);
9614           } catch (com.google.protobuf.InvalidProtocolBufferException e) {
9615             throw e.setUnfinishedMessage(builder.buildPartial());
9616           } catch (com.google.protobuf.UninitializedMessageException e) {
9617             throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
9618           } catch (java.io.IOException e) {
9619             throw new com.google.protobuf.InvalidProtocolBufferException(e)
9620                 .setUnfinishedMessage(builder.buildPartial());
9621           }
9622           return builder.buildPartial();
9623         }
9624       };
9625 
parser()9626   public static com.google.protobuf.Parser<Disk> parser() {
9627     return PARSER;
9628   }
9629 
9630   @java.lang.Override
getParserForType()9631   public com.google.protobuf.Parser<Disk> getParserForType() {
9632     return PARSER;
9633   }
9634 
9635   @java.lang.Override
getDefaultInstanceForType()9636   public com.google.cloud.compute.v1.Disk getDefaultInstanceForType() {
9637     return DEFAULT_INSTANCE;
9638   }
9639 }
9640