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

com.google.cloud.notebooks.v1.Instance Maven / Gradle / Ivy

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

// Protobuf Java Version: 3.25.5
package com.google.cloud.notebooks.v1;

/**
 *
 *
 * 
 * The definition of a notebook instance.
 * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance} */ public final class Instance extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.notebooks.v1.Instance) InstanceOrBuilder { private static final long serialVersionUID = 0L; // Use Instance.newBuilder() to construct. private Instance(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private Instance() { name_ = ""; postStartupScript_ = ""; proxyUri_ = ""; instanceOwners_ = com.google.protobuf.LazyStringArrayList.emptyList(); serviceAccount_ = ""; serviceAccountScopes_ = com.google.protobuf.LazyStringArrayList.emptyList(); machineType_ = ""; state_ = 0; customGpuDriverPath_ = ""; bootDiskType_ = 0; dataDiskType_ = 0; diskEncryption_ = 0; kmsKey_ = ""; disks_ = java.util.Collections.emptyList(); network_ = ""; subnet_ = ""; tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); upgradeHistory_ = java.util.Collections.emptyList(); nicType_ = 0; creator_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new Instance(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_descriptor; } @SuppressWarnings({"rawtypes"}) @java.lang.Override protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( int number) { switch (number) { case 21: return internalGetLabels(); case 22: return internalGetMetadata(); default: throw new RuntimeException("Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.class, com.google.cloud.notebooks.v1.Instance.Builder.class); } /** * * *
   * Definition of the types of hardware accelerators that can be used on this
   * instance.
   * 
* * Protobuf enum {@code google.cloud.notebooks.v1.Instance.AcceleratorType} */ public enum AcceleratorType implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * Accelerator type is not specified.
     * 
* * ACCELERATOR_TYPE_UNSPECIFIED = 0; */ ACCELERATOR_TYPE_UNSPECIFIED(0), /** * * *
     * Accelerator type is Nvidia Tesla K80.
     * 
* * NVIDIA_TESLA_K80 = 1; */ NVIDIA_TESLA_K80(1), /** * * *
     * Accelerator type is Nvidia Tesla P100.
     * 
* * NVIDIA_TESLA_P100 = 2; */ NVIDIA_TESLA_P100(2), /** * * *
     * Accelerator type is Nvidia Tesla V100.
     * 
* * NVIDIA_TESLA_V100 = 3; */ NVIDIA_TESLA_V100(3), /** * * *
     * Accelerator type is Nvidia Tesla P4.
     * 
* * NVIDIA_TESLA_P4 = 4; */ NVIDIA_TESLA_P4(4), /** * * *
     * Accelerator type is Nvidia Tesla T4.
     * 
* * NVIDIA_TESLA_T4 = 5; */ NVIDIA_TESLA_T4(5), /** * * *
     * Accelerator type is Nvidia Tesla A100.
     * 
* * NVIDIA_TESLA_A100 = 11; */ NVIDIA_TESLA_A100(11), /** * * *
     * Accelerator type is NVIDIA Tesla T4 Virtual Workstations.
     * 
* * NVIDIA_TESLA_T4_VWS = 8; */ NVIDIA_TESLA_T4_VWS(8), /** * * *
     * Accelerator type is NVIDIA Tesla P100 Virtual Workstations.
     * 
* * NVIDIA_TESLA_P100_VWS = 9; */ NVIDIA_TESLA_P100_VWS(9), /** * * *
     * Accelerator type is NVIDIA Tesla P4 Virtual Workstations.
     * 
* * NVIDIA_TESLA_P4_VWS = 10; */ NVIDIA_TESLA_P4_VWS(10), /** * * *
     * (Coming soon) Accelerator type is TPU V2.
     * 
* * TPU_V2 = 6; */ TPU_V2(6), /** * * *
     * (Coming soon) Accelerator type is TPU V3.
     * 
* * TPU_V3 = 7; */ TPU_V3(7), UNRECOGNIZED(-1), ; /** * * *
     * Accelerator type is not specified.
     * 
* * ACCELERATOR_TYPE_UNSPECIFIED = 0; */ public static final int ACCELERATOR_TYPE_UNSPECIFIED_VALUE = 0; /** * * *
     * Accelerator type is Nvidia Tesla K80.
     * 
* * NVIDIA_TESLA_K80 = 1; */ public static final int NVIDIA_TESLA_K80_VALUE = 1; /** * * *
     * Accelerator type is Nvidia Tesla P100.
     * 
* * NVIDIA_TESLA_P100 = 2; */ public static final int NVIDIA_TESLA_P100_VALUE = 2; /** * * *
     * Accelerator type is Nvidia Tesla V100.
     * 
* * NVIDIA_TESLA_V100 = 3; */ public static final int NVIDIA_TESLA_V100_VALUE = 3; /** * * *
     * Accelerator type is Nvidia Tesla P4.
     * 
* * NVIDIA_TESLA_P4 = 4; */ public static final int NVIDIA_TESLA_P4_VALUE = 4; /** * * *
     * Accelerator type is Nvidia Tesla T4.
     * 
* * NVIDIA_TESLA_T4 = 5; */ public static final int NVIDIA_TESLA_T4_VALUE = 5; /** * * *
     * Accelerator type is Nvidia Tesla A100.
     * 
* * NVIDIA_TESLA_A100 = 11; */ public static final int NVIDIA_TESLA_A100_VALUE = 11; /** * * *
     * Accelerator type is NVIDIA Tesla T4 Virtual Workstations.
     * 
* * NVIDIA_TESLA_T4_VWS = 8; */ public static final int NVIDIA_TESLA_T4_VWS_VALUE = 8; /** * * *
     * Accelerator type is NVIDIA Tesla P100 Virtual Workstations.
     * 
* * NVIDIA_TESLA_P100_VWS = 9; */ public static final int NVIDIA_TESLA_P100_VWS_VALUE = 9; /** * * *
     * Accelerator type is NVIDIA Tesla P4 Virtual Workstations.
     * 
* * NVIDIA_TESLA_P4_VWS = 10; */ public static final int NVIDIA_TESLA_P4_VWS_VALUE = 10; /** * * *
     * (Coming soon) Accelerator type is TPU V2.
     * 
* * TPU_V2 = 6; */ public static final int TPU_V2_VALUE = 6; /** * * *
     * (Coming soon) Accelerator type is TPU V3.
     * 
* * TPU_V3 = 7; */ public static final int TPU_V3_VALUE = 7; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static AcceleratorType valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static AcceleratorType forNumber(int value) { switch (value) { case 0: return ACCELERATOR_TYPE_UNSPECIFIED; case 1: return NVIDIA_TESLA_K80; case 2: return NVIDIA_TESLA_P100; case 3: return NVIDIA_TESLA_V100; case 4: return NVIDIA_TESLA_P4; case 5: return NVIDIA_TESLA_T4; case 11: return NVIDIA_TESLA_A100; case 8: return NVIDIA_TESLA_T4_VWS; case 9: return NVIDIA_TESLA_P100_VWS; case 10: return NVIDIA_TESLA_P4_VWS; case 6: return TPU_V2; case 7: return TPU_V3; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public AcceleratorType findValueByNumber(int number) { return AcceleratorType.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.notebooks.v1.Instance.getDescriptor().getEnumTypes().get(0); } private static final AcceleratorType[] VALUES = values(); public static AcceleratorType valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private AcceleratorType(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.notebooks.v1.Instance.AcceleratorType) } /** * * *
   * The definition of the states of this instance.
   * 
* * Protobuf enum {@code google.cloud.notebooks.v1.Instance.State} */ public enum State implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * State is not specified.
     * 
* * STATE_UNSPECIFIED = 0; */ STATE_UNSPECIFIED(0), /** * * *
     * The control logic is starting the instance.
     * 
* * STARTING = 1; */ STARTING(1), /** * * *
     * The control logic is installing required frameworks and registering the
     * instance with notebook proxy
     * 
* * PROVISIONING = 2; */ PROVISIONING(2), /** * * *
     * The instance is running.
     * 
* * ACTIVE = 3; */ ACTIVE(3), /** * * *
     * The control logic is stopping the instance.
     * 
* * STOPPING = 4; */ STOPPING(4), /** * * *
     * The instance is stopped.
     * 
* * STOPPED = 5; */ STOPPED(5), /** * * *
     * The instance is deleted.
     * 
* * DELETED = 6; */ DELETED(6), /** * * *
     * The instance is upgrading.
     * 
* * UPGRADING = 7; */ UPGRADING(7), /** * * *
     * The instance is being created.
     * 
* * INITIALIZING = 8; */ INITIALIZING(8), /** * * *
     * The instance is getting registered.
     * 
* * REGISTERING = 9; */ REGISTERING(9), /** * * *
     * The instance is suspending.
     * 
* * SUSPENDING = 10; */ SUSPENDING(10), /** * * *
     * The instance is suspended.
     * 
* * SUSPENDED = 11; */ SUSPENDED(11), UNRECOGNIZED(-1), ; /** * * *
     * State is not specified.
     * 
* * STATE_UNSPECIFIED = 0; */ public static final int STATE_UNSPECIFIED_VALUE = 0; /** * * *
     * The control logic is starting the instance.
     * 
* * STARTING = 1; */ public static final int STARTING_VALUE = 1; /** * * *
     * The control logic is installing required frameworks and registering the
     * instance with notebook proxy
     * 
* * PROVISIONING = 2; */ public static final int PROVISIONING_VALUE = 2; /** * * *
     * The instance is running.
     * 
* * ACTIVE = 3; */ public static final int ACTIVE_VALUE = 3; /** * * *
     * The control logic is stopping the instance.
     * 
* * STOPPING = 4; */ public static final int STOPPING_VALUE = 4; /** * * *
     * The instance is stopped.
     * 
* * STOPPED = 5; */ public static final int STOPPED_VALUE = 5; /** * * *
     * The instance is deleted.
     * 
* * DELETED = 6; */ public static final int DELETED_VALUE = 6; /** * * *
     * The instance is upgrading.
     * 
* * UPGRADING = 7; */ public static final int UPGRADING_VALUE = 7; /** * * *
     * The instance is being created.
     * 
* * INITIALIZING = 8; */ public static final int INITIALIZING_VALUE = 8; /** * * *
     * The instance is getting registered.
     * 
* * REGISTERING = 9; */ public static final int REGISTERING_VALUE = 9; /** * * *
     * The instance is suspending.
     * 
* * SUSPENDING = 10; */ public static final int SUSPENDING_VALUE = 10; /** * * *
     * The instance is suspended.
     * 
* * SUSPENDED = 11; */ public static final int SUSPENDED_VALUE = 11; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static State valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static State forNumber(int value) { switch (value) { case 0: return STATE_UNSPECIFIED; case 1: return STARTING; case 2: return PROVISIONING; case 3: return ACTIVE; case 4: return STOPPING; case 5: return STOPPED; case 6: return DELETED; case 7: return UPGRADING; case 8: return INITIALIZING; case 9: return REGISTERING; case 10: return SUSPENDING; case 11: return SUSPENDED; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public State findValueByNumber(int number) { return State.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.notebooks.v1.Instance.getDescriptor().getEnumTypes().get(1); } private static final State[] VALUES = values(); public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private State(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.notebooks.v1.Instance.State) } /** * * *
   * Possible disk types for notebook instances.
   * 
* * Protobuf enum {@code google.cloud.notebooks.v1.Instance.DiskType} */ public enum DiskType implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * Disk type not set.
     * 
* * DISK_TYPE_UNSPECIFIED = 0; */ DISK_TYPE_UNSPECIFIED(0), /** * * *
     * Standard persistent disk type.
     * 
* * PD_STANDARD = 1; */ PD_STANDARD(1), /** * * *
     * SSD persistent disk type.
     * 
* * PD_SSD = 2; */ PD_SSD(2), /** * * *
     * Balanced persistent disk type.
     * 
* * PD_BALANCED = 3; */ PD_BALANCED(3), /** * * *
     * Extreme persistent disk type.
     * 
* * PD_EXTREME = 4; */ PD_EXTREME(4), UNRECOGNIZED(-1), ; /** * * *
     * Disk type not set.
     * 
* * DISK_TYPE_UNSPECIFIED = 0; */ public static final int DISK_TYPE_UNSPECIFIED_VALUE = 0; /** * * *
     * Standard persistent disk type.
     * 
* * PD_STANDARD = 1; */ public static final int PD_STANDARD_VALUE = 1; /** * * *
     * SSD persistent disk type.
     * 
* * PD_SSD = 2; */ public static final int PD_SSD_VALUE = 2; /** * * *
     * Balanced persistent disk type.
     * 
* * PD_BALANCED = 3; */ public static final int PD_BALANCED_VALUE = 3; /** * * *
     * Extreme persistent disk type.
     * 
* * PD_EXTREME = 4; */ public static final int PD_EXTREME_VALUE = 4; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static DiskType valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static DiskType forNumber(int value) { switch (value) { case 0: return DISK_TYPE_UNSPECIFIED; case 1: return PD_STANDARD; case 2: return PD_SSD; case 3: return PD_BALANCED; case 4: return PD_EXTREME; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public DiskType findValueByNumber(int number) { return DiskType.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.notebooks.v1.Instance.getDescriptor().getEnumTypes().get(2); } private static final DiskType[] VALUES = values(); public static DiskType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private DiskType(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.notebooks.v1.Instance.DiskType) } /** * * *
   * Definition of the disk encryption options.
   * 
* * Protobuf enum {@code google.cloud.notebooks.v1.Instance.DiskEncryption} */ public enum DiskEncryption implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * Disk encryption is not specified.
     * 
* * DISK_ENCRYPTION_UNSPECIFIED = 0; */ DISK_ENCRYPTION_UNSPECIFIED(0), /** * * *
     * Use Google managed encryption keys to encrypt the boot disk.
     * 
* * GMEK = 1; */ GMEK(1), /** * * *
     * Use customer managed encryption keys to encrypt the boot disk.
     * 
* * CMEK = 2; */ CMEK(2), UNRECOGNIZED(-1), ; /** * * *
     * Disk encryption is not specified.
     * 
* * DISK_ENCRYPTION_UNSPECIFIED = 0; */ public static final int DISK_ENCRYPTION_UNSPECIFIED_VALUE = 0; /** * * *
     * Use Google managed encryption keys to encrypt the boot disk.
     * 
* * GMEK = 1; */ public static final int GMEK_VALUE = 1; /** * * *
     * Use customer managed encryption keys to encrypt the boot disk.
     * 
* * CMEK = 2; */ public static final int CMEK_VALUE = 2; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static DiskEncryption valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static DiskEncryption forNumber(int value) { switch (value) { case 0: return DISK_ENCRYPTION_UNSPECIFIED; case 1: return GMEK; case 2: return CMEK; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public DiskEncryption findValueByNumber(int number) { return DiskEncryption.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.notebooks.v1.Instance.getDescriptor().getEnumTypes().get(3); } private static final DiskEncryption[] VALUES = values(); public static DiskEncryption valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private DiskEncryption(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.notebooks.v1.Instance.DiskEncryption) } /** * * *
   * The type of vNIC driver.
   * Default should be UNSPECIFIED_NIC_TYPE.
   * 
* * Protobuf enum {@code google.cloud.notebooks.v1.Instance.NicType} */ public enum NicType implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * No type specified.
     * 
* * UNSPECIFIED_NIC_TYPE = 0; */ UNSPECIFIED_NIC_TYPE(0), /** * * *
     * VIRTIO
     * 
* * VIRTIO_NET = 1; */ VIRTIO_NET(1), /** * * *
     * GVNIC
     * 
* * GVNIC = 2; */ GVNIC(2), UNRECOGNIZED(-1), ; /** * * *
     * No type specified.
     * 
* * UNSPECIFIED_NIC_TYPE = 0; */ public static final int UNSPECIFIED_NIC_TYPE_VALUE = 0; /** * * *
     * VIRTIO
     * 
* * VIRTIO_NET = 1; */ public static final int VIRTIO_NET_VALUE = 1; /** * * *
     * GVNIC
     * 
* * GVNIC = 2; */ public static final int GVNIC_VALUE = 2; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static NicType valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static NicType forNumber(int value) { switch (value) { case 0: return UNSPECIFIED_NIC_TYPE; case 1: return VIRTIO_NET; case 2: return GVNIC; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public NicType findValueByNumber(int number) { return NicType.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.notebooks.v1.Instance.getDescriptor().getEnumTypes().get(4); } private static final NicType[] VALUES = values(); public static NicType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private NicType(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.notebooks.v1.Instance.NicType) } public interface AcceleratorConfigOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.notebooks.v1.Instance.AcceleratorConfig) com.google.protobuf.MessageOrBuilder { /** * * *
     * Type of this accelerator.
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @return The enum numeric value on the wire for type. */ int getTypeValue(); /** * * *
     * Type of this accelerator.
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @return The type. */ com.google.cloud.notebooks.v1.Instance.AcceleratorType getType(); /** * * *
     * Count of cores of this accelerator.
     * 
* * int64 core_count = 2; * * @return The coreCount. */ long getCoreCount(); } /** * * *
   * Definition of a hardware accelerator. Note that not all combinations
   * of `type` and `core_count` are valid. Check [GPUs on Compute
   * Engine](https://cloud.google.com/compute/docs/gpus/#gpus-list) to find a
   * valid combination. TPUs are not supported.
   * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.AcceleratorConfig} */ public static final class AcceleratorConfig extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.notebooks.v1.Instance.AcceleratorConfig) AcceleratorConfigOrBuilder { private static final long serialVersionUID = 0L; // Use AcceleratorConfig.newBuilder() to construct. private AcceleratorConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private AcceleratorConfig() { type_ = 0; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new AcceleratorConfig(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_AcceleratorConfig_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_AcceleratorConfig_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.class, com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.Builder.class); } public static final int TYPE_FIELD_NUMBER = 1; private int type_ = 0; /** * * *
     * Type of this accelerator.
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @return The enum numeric value on the wire for type. */ @java.lang.Override public int getTypeValue() { return type_; } /** * * *
     * Type of this accelerator.
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @return The type. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.AcceleratorType getType() { com.google.cloud.notebooks.v1.Instance.AcceleratorType result = com.google.cloud.notebooks.v1.Instance.AcceleratorType.forNumber(type_); return result == null ? com.google.cloud.notebooks.v1.Instance.AcceleratorType.UNRECOGNIZED : result; } public static final int CORE_COUNT_FIELD_NUMBER = 2; private long coreCount_ = 0L; /** * * *
     * Count of cores of this accelerator.
     * 
* * int64 core_count = 2; * * @return The coreCount. */ @java.lang.Override public long getCoreCount() { return coreCount_; } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (type_ != com.google.cloud.notebooks.v1.Instance.AcceleratorType.ACCELERATOR_TYPE_UNSPECIFIED .getNumber()) { output.writeEnum(1, type_); } if (coreCount_ != 0L) { output.writeInt64(2, coreCount_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (type_ != com.google.cloud.notebooks.v1.Instance.AcceleratorType.ACCELERATOR_TYPE_UNSPECIFIED .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); } if (coreCount_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, coreCount_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.notebooks.v1.Instance.AcceleratorConfig)) { return super.equals(obj); } com.google.cloud.notebooks.v1.Instance.AcceleratorConfig other = (com.google.cloud.notebooks.v1.Instance.AcceleratorConfig) obj; if (type_ != other.type_) return false; if (getCoreCount() != other.getCoreCount()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + TYPE_FIELD_NUMBER; hash = (53 * hash) + type_; hash = (37 * hash) + CORE_COUNT_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getCoreCount()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.notebooks.v1.Instance.AcceleratorConfig prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * Definition of a hardware accelerator. Note that not all combinations
     * of `type` and `core_count` are valid. Check [GPUs on Compute
     * Engine](https://cloud.google.com/compute/docs/gpus/#gpus-list) to find a
     * valid combination. TPUs are not supported.
     * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.AcceleratorConfig} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.notebooks.v1.Instance.AcceleratorConfig) com.google.cloud.notebooks.v1.Instance.AcceleratorConfigOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_AcceleratorConfig_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_AcceleratorConfig_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.class, com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.Builder.class); } // Construct using com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; type_ = 0; coreCount_ = 0L; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_AcceleratorConfig_descriptor; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.AcceleratorConfig getDefaultInstanceForType() { return com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.getDefaultInstance(); } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.AcceleratorConfig build() { com.google.cloud.notebooks.v1.Instance.AcceleratorConfig result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.AcceleratorConfig buildPartial() { com.google.cloud.notebooks.v1.Instance.AcceleratorConfig result = new com.google.cloud.notebooks.v1.Instance.AcceleratorConfig(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0(com.google.cloud.notebooks.v1.Instance.AcceleratorConfig result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.type_ = type_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.coreCount_ = coreCount_; } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.notebooks.v1.Instance.AcceleratorConfig) { return mergeFrom((com.google.cloud.notebooks.v1.Instance.AcceleratorConfig) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.notebooks.v1.Instance.AcceleratorConfig other) { if (other == com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.getDefaultInstance()) return this; if (other.type_ != 0) { setTypeValue(other.getTypeValue()); } if (other.getCoreCount() != 0L) { setCoreCount(other.getCoreCount()); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 8: { type_ = input.readEnum(); bitField0_ |= 0x00000001; break; } // case 8 case 16: { coreCount_ = input.readInt64(); bitField0_ |= 0x00000002; break; } // case 16 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private int type_ = 0; /** * * *
       * Type of this accelerator.
       * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @return The enum numeric value on the wire for type. */ @java.lang.Override public int getTypeValue() { return type_; } /** * * *
       * Type of this accelerator.
       * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @param value The enum numeric value on the wire for type to set. * @return This builder for chaining. */ public Builder setTypeValue(int value) { type_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * Type of this accelerator.
       * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @return The type. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.AcceleratorType getType() { com.google.cloud.notebooks.v1.Instance.AcceleratorType result = com.google.cloud.notebooks.v1.Instance.AcceleratorType.forNumber(type_); return result == null ? com.google.cloud.notebooks.v1.Instance.AcceleratorType.UNRECOGNIZED : result; } /** * * *
       * Type of this accelerator.
       * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @param value The type to set. * @return This builder for chaining. */ public Builder setType(com.google.cloud.notebooks.v1.Instance.AcceleratorType value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000001; type_ = value.getNumber(); onChanged(); return this; } /** * * *
       * Type of this accelerator.
       * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorType type = 1; * * @return This builder for chaining. */ public Builder clearType() { bitField0_ = (bitField0_ & ~0x00000001); type_ = 0; onChanged(); return this; } private long coreCount_; /** * * *
       * Count of cores of this accelerator.
       * 
* * int64 core_count = 2; * * @return The coreCount. */ @java.lang.Override public long getCoreCount() { return coreCount_; } /** * * *
       * Count of cores of this accelerator.
       * 
* * int64 core_count = 2; * * @param value The coreCount to set. * @return This builder for chaining. */ public Builder setCoreCount(long value) { coreCount_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * Count of cores of this accelerator.
       * 
* * int64 core_count = 2; * * @return This builder for chaining. */ public Builder clearCoreCount() { bitField0_ = (bitField0_ & ~0x00000002); coreCount_ = 0L; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.notebooks.v1.Instance.AcceleratorConfig) } // @@protoc_insertion_point(class_scope:google.cloud.notebooks.v1.Instance.AcceleratorConfig) private static final com.google.cloud.notebooks.v1.Instance.AcceleratorConfig DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.notebooks.v1.Instance.AcceleratorConfig(); } public static com.google.cloud.notebooks.v1.Instance.AcceleratorConfig getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public AcceleratorConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.AcceleratorConfig getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface DiskOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.notebooks.v1.Instance.Disk) com.google.protobuf.MessageOrBuilder { /** * * *
     * Indicates whether the disk will be auto-deleted when the instance is
     * deleted (but not when the disk is detached from the instance).
     * 
* * bool auto_delete = 1; * * @return The autoDelete. */ boolean getAutoDelete(); /** * * *
     * Indicates that this is a boot disk. The virtual machine will use the
     * first partition of the disk for its root filesystem.
     * 
* * bool boot = 2; * * @return The boot. */ boolean getBoot(); /** * * *
     * Indicates a unique device name of your choice that is reflected into the
     * `/dev/disk/by-id/google-*` tree of a Linux operating system running
     * within the instance. This name can be used to reference the device for
     * mounting, resizing, and so on, from within the instance.
     *
     * If not specified, the server chooses a default device name to apply to
     * this disk, in the form persistent-disk-x, where x is a number assigned by
     * Google Compute Engine.This field is only applicable for persistent disks.
     * 
* * string device_name = 3; * * @return The deviceName. */ java.lang.String getDeviceName(); /** * * *
     * Indicates a unique device name of your choice that is reflected into the
     * `/dev/disk/by-id/google-*` tree of a Linux operating system running
     * within the instance. This name can be used to reference the device for
     * mounting, resizing, and so on, from within the instance.
     *
     * If not specified, the server chooses a default device name to apply to
     * this disk, in the form persistent-disk-x, where x is a number assigned by
     * Google Compute Engine.This field is only applicable for persistent disks.
     * 
* * string device_name = 3; * * @return The bytes for deviceName. */ com.google.protobuf.ByteString getDeviceNameBytes(); /** * * *
     * Indicates the size of the disk in base-2 GB.
     * 
* * int64 disk_size_gb = 4; * * @return The diskSizeGb. */ long getDiskSizeGb(); /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ java.util.List getGuestOsFeaturesList(); /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature getGuestOsFeatures(int index); /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ int getGuestOsFeaturesCount(); /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ java.util.List getGuestOsFeaturesOrBuilderList(); /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder getGuestOsFeaturesOrBuilder( int index); /** * * *
     * A zero-based index to this disk, where 0 is reserved for the
     * boot disk. If you have many disks attached to an instance, each disk
     * would have a unique index number.
     * 
* * int64 index = 6; * * @return The index. */ long getIndex(); /** * * *
     * Indicates the disk interface to use for attaching this disk, which is
     * either SCSI or NVME. The default is SCSI. Persistent disks must always
     * use SCSI and the request will fail if you attempt to attach a persistent
     * disk in any other format than SCSI. Local SSDs can use either NVME or
     * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
     * performance.
     * Valid values:
     *
     * * `NVME`
     * * `SCSI`
     * 
* * string interface = 7; * * @return The interface. */ java.lang.String getInterface(); /** * * *
     * Indicates the disk interface to use for attaching this disk, which is
     * either SCSI or NVME. The default is SCSI. Persistent disks must always
     * use SCSI and the request will fail if you attempt to attach a persistent
     * disk in any other format than SCSI. Local SSDs can use either NVME or
     * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
     * performance.
     * Valid values:
     *
     * * `NVME`
     * * `SCSI`
     * 
* * string interface = 7; * * @return The bytes for interface. */ com.google.protobuf.ByteString getInterfaceBytes(); /** * * *
     * Type of the resource. Always compute#attachedDisk for attached
     * disks.
     * 
* * string kind = 8; * * @return The kind. */ java.lang.String getKind(); /** * * *
     * Type of the resource. Always compute#attachedDisk for attached
     * disks.
     * 
* * string kind = 8; * * @return The bytes for kind. */ com.google.protobuf.ByteString getKindBytes(); /** * * *
     * A list of publicly visible licenses. Reserved for Google's use.
     * A License represents billing and aggregate usage data for public
     * and marketplace images.
     * 
* * repeated string licenses = 9; * * @return A list containing the licenses. */ java.util.List getLicensesList(); /** * * *
     * A list of publicly visible licenses. Reserved for Google's use.
     * A License represents billing and aggregate usage data for public
     * and marketplace images.
     * 
* * repeated string licenses = 9; * * @return The count of licenses. */ int getLicensesCount(); /** * * *
     * A list of publicly visible licenses. Reserved for Google's use.
     * A License represents billing and aggregate usage data for public
     * and marketplace images.
     * 
* * repeated string licenses = 9; * * @param index The index of the element to return. * @return The licenses at the given index. */ java.lang.String getLicenses(int index); /** * * *
     * A list of publicly visible licenses. Reserved for Google's use.
     * A License represents billing and aggregate usage data for public
     * and marketplace images.
     * 
* * repeated string licenses = 9; * * @param index The index of the value to return. * @return The bytes of the licenses at the given index. */ com.google.protobuf.ByteString getLicensesBytes(int index); /** * * *
     * The mode in which to attach this disk, either `READ_WRITE` or
     * `READ_ONLY`. If not specified, the default is to attach the disk in
     * `READ_WRITE` mode. Valid values:
     *
     * * `READ_ONLY`
     * * `READ_WRITE`
     * 
* * string mode = 10; * * @return The mode. */ java.lang.String getMode(); /** * * *
     * The mode in which to attach this disk, either `READ_WRITE` or
     * `READ_ONLY`. If not specified, the default is to attach the disk in
     * `READ_WRITE` mode. Valid values:
     *
     * * `READ_ONLY`
     * * `READ_WRITE`
     * 
* * string mode = 10; * * @return The bytes for mode. */ com.google.protobuf.ByteString getModeBytes(); /** * * *
     * Indicates a valid partial or full URL to an existing Persistent Disk
     * resource.
     * 
* * string source = 11; * * @return The source. */ java.lang.String getSource(); /** * * *
     * Indicates a valid partial or full URL to an existing Persistent Disk
     * resource.
     * 
* * string source = 11; * * @return The bytes for source. */ com.google.protobuf.ByteString getSourceBytes(); /** * * *
     * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
     * Valid values:
     *
     * * `PERSISTENT`
     * * `SCRATCH`
     * 
* * string type = 12; * * @return The type. */ java.lang.String getType(); /** * * *
     * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
     * Valid values:
     *
     * * `PERSISTENT`
     * * `SCRATCH`
     * 
* * string type = 12; * * @return The bytes for type. */ com.google.protobuf.ByteString getTypeBytes(); } /** * * *
   * An instance-attached disk resource.
   * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.Disk} */ public static final class Disk extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.notebooks.v1.Instance.Disk) DiskOrBuilder { private static final long serialVersionUID = 0L; // Use Disk.newBuilder() to construct. private Disk(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private Disk() { deviceName_ = ""; guestOsFeatures_ = java.util.Collections.emptyList(); interface_ = ""; kind_ = ""; licenses_ = com.google.protobuf.LazyStringArrayList.emptyList(); mode_ = ""; source_ = ""; type_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new Disk(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.Disk.class, com.google.cloud.notebooks.v1.Instance.Disk.Builder.class); } public interface GuestOsFeatureOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature) com.google.protobuf.MessageOrBuilder { /** * * *
       * The ID of a supported feature. Read  Enabling guest operating system
       * features to see a list of available options.
       * Valid values:
       *
       * * `FEATURE_TYPE_UNSPECIFIED`
       * * `MULTI_IP_SUBNET`
       * * `SECURE_BOOT`
       * * `UEFI_COMPATIBLE`
       * * `VIRTIO_SCSI_MULTIQUEUE`
       * * `WINDOWS`
       * 
* * string type = 1; * * @return The type. */ java.lang.String getType(); /** * * *
       * The ID of a supported feature. Read  Enabling guest operating system
       * features to see a list of available options.
       * Valid values:
       *
       * * `FEATURE_TYPE_UNSPECIFIED`
       * * `MULTI_IP_SUBNET`
       * * `SECURE_BOOT`
       * * `UEFI_COMPATIBLE`
       * * `VIRTIO_SCSI_MULTIQUEUE`
       * * `WINDOWS`
       * 
* * string type = 1; * * @return The bytes for type. */ com.google.protobuf.ByteString getTypeBytes(); } /** * * *
     * Guest OS features for boot disk.
     * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature} */ public static final class GuestOsFeature extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature) GuestOsFeatureOrBuilder { private static final long serialVersionUID = 0L; // Use GuestOsFeature.newBuilder() to construct. private GuestOsFeature(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private GuestOsFeature() { type_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new GuestOsFeature(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_GuestOsFeature_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_GuestOsFeature_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.class, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder.class); } public static final int TYPE_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object type_ = ""; /** * * *
       * The ID of a supported feature. Read  Enabling guest operating system
       * features to see a list of available options.
       * Valid values:
       *
       * * `FEATURE_TYPE_UNSPECIFIED`
       * * `MULTI_IP_SUBNET`
       * * `SECURE_BOOT`
       * * `UEFI_COMPATIBLE`
       * * `VIRTIO_SCSI_MULTIQUEUE`
       * * `WINDOWS`
       * 
* * string type = 1; * * @return The type. */ @java.lang.Override public java.lang.String getType() { java.lang.Object ref = type_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); type_ = s; return s; } } /** * * *
       * The ID of a supported feature. Read  Enabling guest operating system
       * features to see a list of available options.
       * Valid values:
       *
       * * `FEATURE_TYPE_UNSPECIFIED`
       * * `MULTI_IP_SUBNET`
       * * `SECURE_BOOT`
       * * `UEFI_COMPATIBLE`
       * * `VIRTIO_SCSI_MULTIQUEUE`
       * * `WINDOWS`
       * 
* * string type = 1; * * @return The bytes for type. */ @java.lang.Override public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); type_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, type_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, type_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature)) { return super.equals(obj); } com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature other = (com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature) obj; if (!getType().equals(other.getType())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + TYPE_FIELD_NUMBER; hash = (53 * hash) + getType().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
       * Guest OS features for boot disk.
       * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature) com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_GuestOsFeature_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_GuestOsFeature_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.class, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder.class); } // Construct using com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; type_ = ""; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_GuestOsFeature_descriptor; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature getDefaultInstanceForType() { return com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.getDefaultInstance(); } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature build() { com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature buildPartial() { com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature result = new com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0( com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.type_ = type_; } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature) { return mergeFrom((com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature other) { if (other == com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.getDefaultInstance()) return this; if (!other.getType().isEmpty()) { type_ = other.type_; bitField0_ |= 0x00000001; onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { type_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.lang.Object type_ = ""; /** * * *
         * The ID of a supported feature. Read  Enabling guest operating system
         * features to see a list of available options.
         * Valid values:
         *
         * * `FEATURE_TYPE_UNSPECIFIED`
         * * `MULTI_IP_SUBNET`
         * * `SECURE_BOOT`
         * * `UEFI_COMPATIBLE`
         * * `VIRTIO_SCSI_MULTIQUEUE`
         * * `WINDOWS`
         * 
* * string type = 1; * * @return The type. */ public java.lang.String getType() { java.lang.Object ref = type_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); type_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
         * The ID of a supported feature. Read  Enabling guest operating system
         * features to see a list of available options.
         * Valid values:
         *
         * * `FEATURE_TYPE_UNSPECIFIED`
         * * `MULTI_IP_SUBNET`
         * * `SECURE_BOOT`
         * * `UEFI_COMPATIBLE`
         * * `VIRTIO_SCSI_MULTIQUEUE`
         * * `WINDOWS`
         * 
* * string type = 1; * * @return The bytes for type. */ public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); type_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
         * The ID of a supported feature. Read  Enabling guest operating system
         * features to see a list of available options.
         * Valid values:
         *
         * * `FEATURE_TYPE_UNSPECIFIED`
         * * `MULTI_IP_SUBNET`
         * * `SECURE_BOOT`
         * * `UEFI_COMPATIBLE`
         * * `VIRTIO_SCSI_MULTIQUEUE`
         * * `WINDOWS`
         * 
* * string type = 1; * * @param value The type to set. * @return This builder for chaining. */ public Builder setType(java.lang.String value) { if (value == null) { throw new NullPointerException(); } type_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
         * The ID of a supported feature. Read  Enabling guest operating system
         * features to see a list of available options.
         * Valid values:
         *
         * * `FEATURE_TYPE_UNSPECIFIED`
         * * `MULTI_IP_SUBNET`
         * * `SECURE_BOOT`
         * * `UEFI_COMPATIBLE`
         * * `VIRTIO_SCSI_MULTIQUEUE`
         * * `WINDOWS`
         * 
* * string type = 1; * * @return This builder for chaining. */ public Builder clearType() { type_ = getDefaultInstance().getType(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * * *
         * The ID of a supported feature. Read  Enabling guest operating system
         * features to see a list of available options.
         * Valid values:
         *
         * * `FEATURE_TYPE_UNSPECIFIED`
         * * `MULTI_IP_SUBNET`
         * * `SECURE_BOOT`
         * * `UEFI_COMPATIBLE`
         * * `VIRTIO_SCSI_MULTIQUEUE`
         * * `WINDOWS`
         * 
* * string type = 1; * * @param value The bytes for type to set. * @return This builder for chaining. */ public Builder setTypeBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); type_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature) } // @@protoc_insertion_point(class_scope:google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature) private static final com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature(); } public static com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public GuestOsFeature parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public static final int AUTO_DELETE_FIELD_NUMBER = 1; private boolean autoDelete_ = false; /** * * *
     * Indicates whether the disk will be auto-deleted when the instance is
     * deleted (but not when the disk is detached from the instance).
     * 
* * bool auto_delete = 1; * * @return The autoDelete. */ @java.lang.Override public boolean getAutoDelete() { return autoDelete_; } public static final int BOOT_FIELD_NUMBER = 2; private boolean boot_ = false; /** * * *
     * Indicates that this is a boot disk. The virtual machine will use the
     * first partition of the disk for its root filesystem.
     * 
* * bool boot = 2; * * @return The boot. */ @java.lang.Override public boolean getBoot() { return boot_; } public static final int DEVICE_NAME_FIELD_NUMBER = 3; @SuppressWarnings("serial") private volatile java.lang.Object deviceName_ = ""; /** * * *
     * Indicates a unique device name of your choice that is reflected into the
     * `/dev/disk/by-id/google-*` tree of a Linux operating system running
     * within the instance. This name can be used to reference the device for
     * mounting, resizing, and so on, from within the instance.
     *
     * If not specified, the server chooses a default device name to apply to
     * this disk, in the form persistent-disk-x, where x is a number assigned by
     * Google Compute Engine.This field is only applicable for persistent disks.
     * 
* * string device_name = 3; * * @return The deviceName. */ @java.lang.Override public java.lang.String getDeviceName() { java.lang.Object ref = deviceName_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); deviceName_ = s; return s; } } /** * * *
     * Indicates a unique device name of your choice that is reflected into the
     * `/dev/disk/by-id/google-*` tree of a Linux operating system running
     * within the instance. This name can be used to reference the device for
     * mounting, resizing, and so on, from within the instance.
     *
     * If not specified, the server chooses a default device name to apply to
     * this disk, in the form persistent-disk-x, where x is a number assigned by
     * Google Compute Engine.This field is only applicable for persistent disks.
     * 
* * string device_name = 3; * * @return The bytes for deviceName. */ @java.lang.Override public com.google.protobuf.ByteString getDeviceNameBytes() { java.lang.Object ref = deviceName_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); deviceName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int DISK_SIZE_GB_FIELD_NUMBER = 4; private long diskSizeGb_ = 0L; /** * * *
     * Indicates the size of the disk in base-2 GB.
     * 
* * int64 disk_size_gb = 4; * * @return The diskSizeGb. */ @java.lang.Override public long getDiskSizeGb() { return diskSizeGb_; } public static final int GUEST_OS_FEATURES_FIELD_NUMBER = 5; @SuppressWarnings("serial") private java.util.List guestOsFeatures_; /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ @java.lang.Override public java.util.List getGuestOsFeaturesList() { return guestOsFeatures_; } /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ @java.lang.Override public java.util.List< ? extends com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder> getGuestOsFeaturesOrBuilderList() { return guestOsFeatures_; } /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ @java.lang.Override public int getGuestOsFeaturesCount() { return guestOsFeatures_.size(); } /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature getGuestOsFeatures( int index) { return guestOsFeatures_.get(index); } /** * * *
     * Indicates 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.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder getGuestOsFeaturesOrBuilder(int index) { return guestOsFeatures_.get(index); } public static final int INDEX_FIELD_NUMBER = 6; private long index_ = 0L; /** * * *
     * A zero-based index to this disk, where 0 is reserved for the
     * boot disk. If you have many disks attached to an instance, each disk
     * would have a unique index number.
     * 
* * int64 index = 6; * * @return The index. */ @java.lang.Override public long getIndex() { return index_; } public static final int INTERFACE_FIELD_NUMBER = 7; @SuppressWarnings("serial") private volatile java.lang.Object interface_ = ""; /** * * *
     * Indicates the disk interface to use for attaching this disk, which is
     * either SCSI or NVME. The default is SCSI. Persistent disks must always
     * use SCSI and the request will fail if you attempt to attach a persistent
     * disk in any other format than SCSI. Local SSDs can use either NVME or
     * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
     * performance.
     * Valid values:
     *
     * * `NVME`
     * * `SCSI`
     * 
* * string interface = 7; * * @return The interface. */ @java.lang.Override public java.lang.String getInterface() { java.lang.Object ref = interface_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); interface_ = s; return s; } } /** * * *
     * Indicates the disk interface to use for attaching this disk, which is
     * either SCSI or NVME. The default is SCSI. Persistent disks must always
     * use SCSI and the request will fail if you attempt to attach a persistent
     * disk in any other format than SCSI. Local SSDs can use either NVME or
     * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
     * performance.
     * Valid values:
     *
     * * `NVME`
     * * `SCSI`
     * 
* * string interface = 7; * * @return The bytes for interface. */ @java.lang.Override public com.google.protobuf.ByteString getInterfaceBytes() { java.lang.Object ref = interface_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); interface_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int KIND_FIELD_NUMBER = 8; @SuppressWarnings("serial") private volatile java.lang.Object kind_ = ""; /** * * *
     * Type of the resource. Always compute#attachedDisk for attached
     * disks.
     * 
* * string kind = 8; * * @return The kind. */ @java.lang.Override public java.lang.String getKind() { java.lang.Object ref = kind_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); kind_ = s; return s; } } /** * * *
     * Type of the resource. Always compute#attachedDisk for attached
     * disks.
     * 
* * string kind = 8; * * @return The bytes for kind. */ @java.lang.Override public com.google.protobuf.ByteString getKindBytes() { java.lang.Object ref = kind_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); kind_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int LICENSES_FIELD_NUMBER = 9; @SuppressWarnings("serial") private com.google.protobuf.LazyStringArrayList licenses_ = com.google.protobuf.LazyStringArrayList.emptyList(); /** * * *
     * A list of publicly visible licenses. Reserved for Google's use.
     * A License represents billing and aggregate usage data for public
     * and marketplace images.
     * 
* * repeated string licenses = 9; * * @return A list containing the licenses. */ public com.google.protobuf.ProtocolStringList getLicensesList() { return licenses_; } /** * * *
     * A list of publicly visible licenses. Reserved for Google's use.
     * A License represents billing and aggregate usage data for public
     * and marketplace images.
     * 
* * repeated string licenses = 9; * * @return The count of licenses. */ public int getLicensesCount() { return licenses_.size(); } /** * * *
     * A list of publicly visible licenses. Reserved for Google's use.
     * A License represents billing and aggregate usage data for public
     * and marketplace images.
     * 
* * repeated string licenses = 9; * * @param index The index of the element to return. * @return The licenses at the given index. */ public java.lang.String getLicenses(int index) { return licenses_.get(index); } /** * * *
     * A list of publicly visible licenses. Reserved for Google's use.
     * A License represents billing and aggregate usage data for public
     * and marketplace images.
     * 
* * repeated string licenses = 9; * * @param index The index of the value to return. * @return The bytes of the licenses at the given index. */ public com.google.protobuf.ByteString getLicensesBytes(int index) { return licenses_.getByteString(index); } public static final int MODE_FIELD_NUMBER = 10; @SuppressWarnings("serial") private volatile java.lang.Object mode_ = ""; /** * * *
     * The mode in which to attach this disk, either `READ_WRITE` or
     * `READ_ONLY`. If not specified, the default is to attach the disk in
     * `READ_WRITE` mode. Valid values:
     *
     * * `READ_ONLY`
     * * `READ_WRITE`
     * 
* * string mode = 10; * * @return The mode. */ @java.lang.Override public java.lang.String getMode() { java.lang.Object ref = mode_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); mode_ = s; return s; } } /** * * *
     * The mode in which to attach this disk, either `READ_WRITE` or
     * `READ_ONLY`. If not specified, the default is to attach the disk in
     * `READ_WRITE` mode. Valid values:
     *
     * * `READ_ONLY`
     * * `READ_WRITE`
     * 
* * string mode = 10; * * @return The bytes for mode. */ @java.lang.Override public com.google.protobuf.ByteString getModeBytes() { java.lang.Object ref = mode_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); mode_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int SOURCE_FIELD_NUMBER = 11; @SuppressWarnings("serial") private volatile java.lang.Object source_ = ""; /** * * *
     * Indicates a valid partial or full URL to an existing Persistent Disk
     * resource.
     * 
* * string source = 11; * * @return The source. */ @java.lang.Override public java.lang.String getSource() { java.lang.Object ref = source_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); source_ = s; return s; } } /** * * *
     * Indicates a valid partial or full URL to an existing Persistent Disk
     * resource.
     * 
* * string source = 11; * * @return The bytes for source. */ @java.lang.Override public com.google.protobuf.ByteString getSourceBytes() { java.lang.Object ref = source_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); source_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int TYPE_FIELD_NUMBER = 12; @SuppressWarnings("serial") private volatile java.lang.Object type_ = ""; /** * * *
     * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
     * Valid values:
     *
     * * `PERSISTENT`
     * * `SCRATCH`
     * 
* * string type = 12; * * @return The type. */ @java.lang.Override public java.lang.String getType() { java.lang.Object ref = type_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); type_ = s; return s; } } /** * * *
     * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
     * Valid values:
     *
     * * `PERSISTENT`
     * * `SCRATCH`
     * 
* * string type = 12; * * @return The bytes for type. */ @java.lang.Override public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); type_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (autoDelete_ != false) { output.writeBool(1, autoDelete_); } if (boot_ != false) { output.writeBool(2, boot_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(deviceName_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, deviceName_); } if (diskSizeGb_ != 0L) { output.writeInt64(4, diskSizeGb_); } for (int i = 0; i < guestOsFeatures_.size(); i++) { output.writeMessage(5, guestOsFeatures_.get(i)); } if (index_ != 0L) { output.writeInt64(6, index_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(interface_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 7, interface_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kind_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 8, kind_); } for (int i = 0; i < licenses_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 9, licenses_.getRaw(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(mode_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 10, mode_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(source_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 11, source_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 12, type_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (autoDelete_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, autoDelete_); } if (boot_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, boot_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(deviceName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, deviceName_); } if (diskSizeGb_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(4, diskSizeGb_); } for (int i = 0; i < guestOsFeatures_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, guestOsFeatures_.get(i)); } if (index_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(6, index_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(interface_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, interface_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kind_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, kind_); } { int dataSize = 0; for (int i = 0; i < licenses_.size(); i++) { dataSize += computeStringSizeNoTag(licenses_.getRaw(i)); } size += dataSize; size += 1 * getLicensesList().size(); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(mode_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, mode_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(source_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(11, source_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(12, type_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.notebooks.v1.Instance.Disk)) { return super.equals(obj); } com.google.cloud.notebooks.v1.Instance.Disk other = (com.google.cloud.notebooks.v1.Instance.Disk) obj; if (getAutoDelete() != other.getAutoDelete()) return false; if (getBoot() != other.getBoot()) return false; if (!getDeviceName().equals(other.getDeviceName())) return false; if (getDiskSizeGb() != other.getDiskSizeGb()) return false; if (!getGuestOsFeaturesList().equals(other.getGuestOsFeaturesList())) return false; if (getIndex() != other.getIndex()) return false; if (!getInterface().equals(other.getInterface())) return false; if (!getKind().equals(other.getKind())) return false; if (!getLicensesList().equals(other.getLicensesList())) return false; if (!getMode().equals(other.getMode())) return false; if (!getSource().equals(other.getSource())) return false; if (!getType().equals(other.getType())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + AUTO_DELETE_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAutoDelete()); hash = (37 * hash) + BOOT_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getBoot()); hash = (37 * hash) + DEVICE_NAME_FIELD_NUMBER; hash = (53 * hash) + getDeviceName().hashCode(); hash = (37 * hash) + DISK_SIZE_GB_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getDiskSizeGb()); if (getGuestOsFeaturesCount() > 0) { hash = (37 * hash) + GUEST_OS_FEATURES_FIELD_NUMBER; hash = (53 * hash) + getGuestOsFeaturesList().hashCode(); } hash = (37 * hash) + INDEX_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIndex()); hash = (37 * hash) + INTERFACE_FIELD_NUMBER; hash = (53 * hash) + getInterface().hashCode(); hash = (37 * hash) + KIND_FIELD_NUMBER; hash = (53 * hash) + getKind().hashCode(); if (getLicensesCount() > 0) { hash = (37 * hash) + LICENSES_FIELD_NUMBER; hash = (53 * hash) + getLicensesList().hashCode(); } hash = (37 * hash) + MODE_FIELD_NUMBER; hash = (53 * hash) + getMode().hashCode(); hash = (37 * hash) + SOURCE_FIELD_NUMBER; hash = (53 * hash) + getSource().hashCode(); hash = (37 * hash) + TYPE_FIELD_NUMBER; hash = (53 * hash) + getType().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.Disk parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.Disk parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(com.google.cloud.notebooks.v1.Instance.Disk prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * An instance-attached disk resource.
     * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.Disk} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.notebooks.v1.Instance.Disk) com.google.cloud.notebooks.v1.Instance.DiskOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.Disk.class, com.google.cloud.notebooks.v1.Instance.Disk.Builder.class); } // Construct using com.google.cloud.notebooks.v1.Instance.Disk.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; autoDelete_ = false; boot_ = false; deviceName_ = ""; diskSizeGb_ = 0L; if (guestOsFeaturesBuilder_ == null) { guestOsFeatures_ = java.util.Collections.emptyList(); } else { guestOsFeatures_ = null; guestOsFeaturesBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000010); index_ = 0L; interface_ = ""; kind_ = ""; licenses_ = com.google.protobuf.LazyStringArrayList.emptyList(); mode_ = ""; source_ = ""; type_ = ""; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_Disk_descriptor; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk getDefaultInstanceForType() { return com.google.cloud.notebooks.v1.Instance.Disk.getDefaultInstance(); } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk build() { com.google.cloud.notebooks.v1.Instance.Disk result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk buildPartial() { com.google.cloud.notebooks.v1.Instance.Disk result = new com.google.cloud.notebooks.v1.Instance.Disk(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartialRepeatedFields(com.google.cloud.notebooks.v1.Instance.Disk result) { if (guestOsFeaturesBuilder_ == null) { if (((bitField0_ & 0x00000010) != 0)) { guestOsFeatures_ = java.util.Collections.unmodifiableList(guestOsFeatures_); bitField0_ = (bitField0_ & ~0x00000010); } result.guestOsFeatures_ = guestOsFeatures_; } else { result.guestOsFeatures_ = guestOsFeaturesBuilder_.build(); } } private void buildPartial0(com.google.cloud.notebooks.v1.Instance.Disk result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.autoDelete_ = autoDelete_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.boot_ = boot_; } if (((from_bitField0_ & 0x00000004) != 0)) { result.deviceName_ = deviceName_; } if (((from_bitField0_ & 0x00000008) != 0)) { result.diskSizeGb_ = diskSizeGb_; } if (((from_bitField0_ & 0x00000020) != 0)) { result.index_ = index_; } if (((from_bitField0_ & 0x00000040) != 0)) { result.interface_ = interface_; } if (((from_bitField0_ & 0x00000080) != 0)) { result.kind_ = kind_; } if (((from_bitField0_ & 0x00000100) != 0)) { licenses_.makeImmutable(); result.licenses_ = licenses_; } if (((from_bitField0_ & 0x00000200) != 0)) { result.mode_ = mode_; } if (((from_bitField0_ & 0x00000400) != 0)) { result.source_ = source_; } if (((from_bitField0_ & 0x00000800) != 0)) { result.type_ = type_; } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.notebooks.v1.Instance.Disk) { return mergeFrom((com.google.cloud.notebooks.v1.Instance.Disk) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.notebooks.v1.Instance.Disk other) { if (other == com.google.cloud.notebooks.v1.Instance.Disk.getDefaultInstance()) return this; if (other.getAutoDelete() != false) { setAutoDelete(other.getAutoDelete()); } if (other.getBoot() != false) { setBoot(other.getBoot()); } if (!other.getDeviceName().isEmpty()) { deviceName_ = other.deviceName_; bitField0_ |= 0x00000004; onChanged(); } if (other.getDiskSizeGb() != 0L) { setDiskSizeGb(other.getDiskSizeGb()); } if (guestOsFeaturesBuilder_ == null) { if (!other.guestOsFeatures_.isEmpty()) { if (guestOsFeatures_.isEmpty()) { guestOsFeatures_ = other.guestOsFeatures_; bitField0_ = (bitField0_ & ~0x00000010); } else { ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.addAll(other.guestOsFeatures_); } onChanged(); } } else { if (!other.guestOsFeatures_.isEmpty()) { if (guestOsFeaturesBuilder_.isEmpty()) { guestOsFeaturesBuilder_.dispose(); guestOsFeaturesBuilder_ = null; guestOsFeatures_ = other.guestOsFeatures_; bitField0_ = (bitField0_ & ~0x00000010); guestOsFeaturesBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getGuestOsFeaturesFieldBuilder() : null; } else { guestOsFeaturesBuilder_.addAllMessages(other.guestOsFeatures_); } } } if (other.getIndex() != 0L) { setIndex(other.getIndex()); } if (!other.getInterface().isEmpty()) { interface_ = other.interface_; bitField0_ |= 0x00000040; onChanged(); } if (!other.getKind().isEmpty()) { kind_ = other.kind_; bitField0_ |= 0x00000080; onChanged(); } if (!other.licenses_.isEmpty()) { if (licenses_.isEmpty()) { licenses_ = other.licenses_; bitField0_ |= 0x00000100; } else { ensureLicensesIsMutable(); licenses_.addAll(other.licenses_); } onChanged(); } if (!other.getMode().isEmpty()) { mode_ = other.mode_; bitField0_ |= 0x00000200; onChanged(); } if (!other.getSource().isEmpty()) { source_ = other.source_; bitField0_ |= 0x00000400; onChanged(); } if (!other.getType().isEmpty()) { type_ = other.type_; bitField0_ |= 0x00000800; onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 8: { autoDelete_ = input.readBool(); bitField0_ |= 0x00000001; break; } // case 8 case 16: { boot_ = input.readBool(); bitField0_ |= 0x00000002; break; } // case 16 case 26: { deviceName_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000004; break; } // case 26 case 32: { diskSizeGb_ = input.readInt64(); bitField0_ |= 0x00000008; break; } // case 32 case 42: { com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature m = input.readMessage( com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.parser(), extensionRegistry); if (guestOsFeaturesBuilder_ == null) { ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.add(m); } else { guestOsFeaturesBuilder_.addMessage(m); } break; } // case 42 case 48: { index_ = input.readInt64(); bitField0_ |= 0x00000020; break; } // case 48 case 58: { interface_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000040; break; } // case 58 case 66: { kind_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000080; break; } // case 66 case 74: { java.lang.String s = input.readStringRequireUtf8(); ensureLicensesIsMutable(); licenses_.add(s); break; } // case 74 case 82: { mode_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000200; break; } // case 82 case 90: { source_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000400; break; } // case 90 case 98: { type_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000800; break; } // case 98 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private boolean autoDelete_; /** * * *
       * Indicates whether the disk will be auto-deleted when the instance is
       * deleted (but not when the disk is detached from the instance).
       * 
* * bool auto_delete = 1; * * @return The autoDelete. */ @java.lang.Override public boolean getAutoDelete() { return autoDelete_; } /** * * *
       * Indicates whether the disk will be auto-deleted when the instance is
       * deleted (but not when the disk is detached from the instance).
       * 
* * bool auto_delete = 1; * * @param value The autoDelete to set. * @return This builder for chaining. */ public Builder setAutoDelete(boolean value) { autoDelete_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * Indicates whether the disk will be auto-deleted when the instance is
       * deleted (but not when the disk is detached from the instance).
       * 
* * bool auto_delete = 1; * * @return This builder for chaining. */ public Builder clearAutoDelete() { bitField0_ = (bitField0_ & ~0x00000001); autoDelete_ = false; onChanged(); return this; } private boolean boot_; /** * * *
       * Indicates that this is a boot disk. The virtual machine will use the
       * first partition of the disk for its root filesystem.
       * 
* * bool boot = 2; * * @return The boot. */ @java.lang.Override public boolean getBoot() { return boot_; } /** * * *
       * Indicates that this is a boot disk. The virtual machine will use the
       * first partition of the disk for its root filesystem.
       * 
* * bool boot = 2; * * @param value The boot to set. * @return This builder for chaining. */ public Builder setBoot(boolean value) { boot_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * Indicates that this is a boot disk. The virtual machine will use the
       * first partition of the disk for its root filesystem.
       * 
* * bool boot = 2; * * @return This builder for chaining. */ public Builder clearBoot() { bitField0_ = (bitField0_ & ~0x00000002); boot_ = false; onChanged(); return this; } private java.lang.Object deviceName_ = ""; /** * * *
       * Indicates a unique device name of your choice that is reflected into the
       * `/dev/disk/by-id/google-*` tree of a Linux operating system running
       * within the instance. This name can be used to reference the device for
       * mounting, resizing, and so on, from within the instance.
       *
       * If not specified, the server chooses a default device name to apply to
       * this disk, in the form persistent-disk-x, where x is a number assigned by
       * Google Compute Engine.This field is only applicable for persistent disks.
       * 
* * string device_name = 3; * * @return The deviceName. */ public java.lang.String getDeviceName() { java.lang.Object ref = deviceName_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); deviceName_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Indicates a unique device name of your choice that is reflected into the
       * `/dev/disk/by-id/google-*` tree of a Linux operating system running
       * within the instance. This name can be used to reference the device for
       * mounting, resizing, and so on, from within the instance.
       *
       * If not specified, the server chooses a default device name to apply to
       * this disk, in the form persistent-disk-x, where x is a number assigned by
       * Google Compute Engine.This field is only applicable for persistent disks.
       * 
* * string device_name = 3; * * @return The bytes for deviceName. */ public com.google.protobuf.ByteString getDeviceNameBytes() { java.lang.Object ref = deviceName_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); deviceName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Indicates a unique device name of your choice that is reflected into the
       * `/dev/disk/by-id/google-*` tree of a Linux operating system running
       * within the instance. This name can be used to reference the device for
       * mounting, resizing, and so on, from within the instance.
       *
       * If not specified, the server chooses a default device name to apply to
       * this disk, in the form persistent-disk-x, where x is a number assigned by
       * Google Compute Engine.This field is only applicable for persistent disks.
       * 
* * string device_name = 3; * * @param value The deviceName to set. * @return This builder for chaining. */ public Builder setDeviceName(java.lang.String value) { if (value == null) { throw new NullPointerException(); } deviceName_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } /** * * *
       * Indicates a unique device name of your choice that is reflected into the
       * `/dev/disk/by-id/google-*` tree of a Linux operating system running
       * within the instance. This name can be used to reference the device for
       * mounting, resizing, and so on, from within the instance.
       *
       * If not specified, the server chooses a default device name to apply to
       * this disk, in the form persistent-disk-x, where x is a number assigned by
       * Google Compute Engine.This field is only applicable for persistent disks.
       * 
* * string device_name = 3; * * @return This builder for chaining. */ public Builder clearDeviceName() { deviceName_ = getDefaultInstance().getDeviceName(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } /** * * *
       * Indicates a unique device name of your choice that is reflected into the
       * `/dev/disk/by-id/google-*` tree of a Linux operating system running
       * within the instance. This name can be used to reference the device for
       * mounting, resizing, and so on, from within the instance.
       *
       * If not specified, the server chooses a default device name to apply to
       * this disk, in the form persistent-disk-x, where x is a number assigned by
       * Google Compute Engine.This field is only applicable for persistent disks.
       * 
* * string device_name = 3; * * @param value The bytes for deviceName to set. * @return This builder for chaining. */ public Builder setDeviceNameBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); deviceName_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } private long diskSizeGb_; /** * * *
       * Indicates the size of the disk in base-2 GB.
       * 
* * int64 disk_size_gb = 4; * * @return The diskSizeGb. */ @java.lang.Override public long getDiskSizeGb() { return diskSizeGb_; } /** * * *
       * Indicates the size of the disk in base-2 GB.
       * 
* * int64 disk_size_gb = 4; * * @param value The diskSizeGb to set. * @return This builder for chaining. */ public Builder setDiskSizeGb(long value) { diskSizeGb_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } /** * * *
       * Indicates the size of the disk in base-2 GB.
       * 
* * int64 disk_size_gb = 4; * * @return This builder for chaining. */ public Builder clearDiskSizeGb() { bitField0_ = (bitField0_ & ~0x00000008); diskSizeGb_ = 0L; onChanged(); return this; } private java.util.List guestOsFeatures_ = java.util.Collections.emptyList(); private void ensureGuestOsFeaturesIsMutable() { if (!((bitField0_ & 0x00000010) != 0)) { guestOsFeatures_ = new java.util.ArrayList( guestOsFeatures_); bitField0_ |= 0x00000010; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder> guestOsFeaturesBuilder_; /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public java.util.List getGuestOsFeaturesList() { if (guestOsFeaturesBuilder_ == null) { return java.util.Collections.unmodifiableList(guestOsFeatures_); } else { return guestOsFeaturesBuilder_.getMessageList(); } } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public int getGuestOsFeaturesCount() { if (guestOsFeaturesBuilder_ == null) { return guestOsFeatures_.size(); } else { return guestOsFeaturesBuilder_.getCount(); } } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature getGuestOsFeatures( int index) { if (guestOsFeaturesBuilder_ == null) { return guestOsFeatures_.get(index); } else { return guestOsFeaturesBuilder_.getMessage(index); } } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder setGuestOsFeatures( int index, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature value) { if (guestOsFeaturesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.set(index, value); onChanged(); } else { guestOsFeaturesBuilder_.setMessage(index, value); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder setGuestOsFeatures( int index, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder builderForValue) { if (guestOsFeaturesBuilder_ == null) { ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.set(index, builderForValue.build()); onChanged(); } else { guestOsFeaturesBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder addGuestOsFeatures( com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature value) { if (guestOsFeaturesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.add(value); onChanged(); } else { guestOsFeaturesBuilder_.addMessage(value); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder addGuestOsFeatures( int index, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature value) { if (guestOsFeaturesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.add(index, value); onChanged(); } else { guestOsFeaturesBuilder_.addMessage(index, value); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder addGuestOsFeatures( com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder builderForValue) { if (guestOsFeaturesBuilder_ == null) { ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.add(builderForValue.build()); onChanged(); } else { guestOsFeaturesBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder addGuestOsFeatures( int index, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder builderForValue) { if (guestOsFeaturesBuilder_ == null) { ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.add(index, builderForValue.build()); onChanged(); } else { guestOsFeaturesBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder addAllGuestOsFeatures( java.lang.Iterable values) { if (guestOsFeaturesBuilder_ == null) { ensureGuestOsFeaturesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, guestOsFeatures_); onChanged(); } else { guestOsFeaturesBuilder_.addAllMessages(values); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder clearGuestOsFeatures() { if (guestOsFeaturesBuilder_ == null) { guestOsFeatures_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000010); onChanged(); } else { guestOsFeaturesBuilder_.clear(); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public Builder removeGuestOsFeatures(int index) { if (guestOsFeaturesBuilder_ == null) { ensureGuestOsFeaturesIsMutable(); guestOsFeatures_.remove(index); onChanged(); } else { guestOsFeaturesBuilder_.remove(index); } return this; } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder getGuestOsFeaturesBuilder(int index) { return getGuestOsFeaturesFieldBuilder().getBuilder(index); } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder getGuestOsFeaturesOrBuilder(int index) { if (guestOsFeaturesBuilder_ == null) { return guestOsFeatures_.get(index); } else { return guestOsFeaturesBuilder_.getMessageOrBuilder(index); } } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public java.util.List< ? extends com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder> getGuestOsFeaturesOrBuilderList() { if (guestOsFeaturesBuilder_ != null) { return guestOsFeaturesBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(guestOsFeatures_); } } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder addGuestOsFeaturesBuilder() { return getGuestOsFeaturesFieldBuilder() .addBuilder( com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.getDefaultInstance()); } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder addGuestOsFeaturesBuilder(int index) { return getGuestOsFeaturesFieldBuilder() .addBuilder( index, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.getDefaultInstance()); } /** * * *
       * Indicates 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.
       * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature guest_os_features = 5; * */ public java.util.List getGuestOsFeaturesBuilderList() { return getGuestOsFeaturesFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder> getGuestOsFeaturesFieldBuilder() { if (guestOsFeaturesBuilder_ == null) { guestOsFeaturesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeature.Builder, com.google.cloud.notebooks.v1.Instance.Disk.GuestOsFeatureOrBuilder>( guestOsFeatures_, ((bitField0_ & 0x00000010) != 0), getParentForChildren(), isClean()); guestOsFeatures_ = null; } return guestOsFeaturesBuilder_; } private long index_; /** * * *
       * A zero-based index to this disk, where 0 is reserved for the
       * boot disk. If you have many disks attached to an instance, each disk
       * would have a unique index number.
       * 
* * int64 index = 6; * * @return The index. */ @java.lang.Override public long getIndex() { return index_; } /** * * *
       * A zero-based index to this disk, where 0 is reserved for the
       * boot disk. If you have many disks attached to an instance, each disk
       * would have a unique index number.
       * 
* * int64 index = 6; * * @param value The index to set. * @return This builder for chaining. */ public Builder setIndex(long value) { index_ = value; bitField0_ |= 0x00000020; onChanged(); return this; } /** * * *
       * A zero-based index to this disk, where 0 is reserved for the
       * boot disk. If you have many disks attached to an instance, each disk
       * would have a unique index number.
       * 
* * int64 index = 6; * * @return This builder for chaining. */ public Builder clearIndex() { bitField0_ = (bitField0_ & ~0x00000020); index_ = 0L; onChanged(); return this; } private java.lang.Object interface_ = ""; /** * * *
       * Indicates the disk interface to use for attaching this disk, which is
       * either SCSI or NVME. The default is SCSI. Persistent disks must always
       * use SCSI and the request will fail if you attempt to attach a persistent
       * disk in any other format than SCSI. Local SSDs can use either NVME or
       * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
       * performance.
       * Valid values:
       *
       * * `NVME`
       * * `SCSI`
       * 
* * string interface = 7; * * @return The interface. */ public java.lang.String getInterface() { java.lang.Object ref = interface_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); interface_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Indicates the disk interface to use for attaching this disk, which is
       * either SCSI or NVME. The default is SCSI. Persistent disks must always
       * use SCSI and the request will fail if you attempt to attach a persistent
       * disk in any other format than SCSI. Local SSDs can use either NVME or
       * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
       * performance.
       * Valid values:
       *
       * * `NVME`
       * * `SCSI`
       * 
* * string interface = 7; * * @return The bytes for interface. */ public com.google.protobuf.ByteString getInterfaceBytes() { java.lang.Object ref = interface_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); interface_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Indicates the disk interface to use for attaching this disk, which is
       * either SCSI or NVME. The default is SCSI. Persistent disks must always
       * use SCSI and the request will fail if you attempt to attach a persistent
       * disk in any other format than SCSI. Local SSDs can use either NVME or
       * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
       * performance.
       * Valid values:
       *
       * * `NVME`
       * * `SCSI`
       * 
* * string interface = 7; * * @param value The interface to set. * @return This builder for chaining. */ public Builder setInterface(java.lang.String value) { if (value == null) { throw new NullPointerException(); } interface_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } /** * * *
       * Indicates the disk interface to use for attaching this disk, which is
       * either SCSI or NVME. The default is SCSI. Persistent disks must always
       * use SCSI and the request will fail if you attempt to attach a persistent
       * disk in any other format than SCSI. Local SSDs can use either NVME or
       * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
       * performance.
       * Valid values:
       *
       * * `NVME`
       * * `SCSI`
       * 
* * string interface = 7; * * @return This builder for chaining. */ public Builder clearInterface() { interface_ = getDefaultInstance().getInterface(); bitField0_ = (bitField0_ & ~0x00000040); onChanged(); return this; } /** * * *
       * Indicates the disk interface to use for attaching this disk, which is
       * either SCSI or NVME. The default is SCSI. Persistent disks must always
       * use SCSI and the request will fail if you attempt to attach a persistent
       * disk in any other format than SCSI. Local SSDs can use either NVME or
       * SCSI. For performance characteristics of SCSI over NVMe, see Local SSD
       * performance.
       * Valid values:
       *
       * * `NVME`
       * * `SCSI`
       * 
* * string interface = 7; * * @param value The bytes for interface to set. * @return This builder for chaining. */ public Builder setInterfaceBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); interface_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } private java.lang.Object kind_ = ""; /** * * *
       * Type of the resource. Always compute#attachedDisk for attached
       * disks.
       * 
* * string kind = 8; * * @return The kind. */ public java.lang.String getKind() { java.lang.Object ref = kind_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); kind_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Type of the resource. Always compute#attachedDisk for attached
       * disks.
       * 
* * string kind = 8; * * @return The bytes for kind. */ public com.google.protobuf.ByteString getKindBytes() { java.lang.Object ref = kind_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); kind_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Type of the resource. Always compute#attachedDisk for attached
       * disks.
       * 
* * string kind = 8; * * @param value The kind to set. * @return This builder for chaining. */ public Builder setKind(java.lang.String value) { if (value == null) { throw new NullPointerException(); } kind_ = value; bitField0_ |= 0x00000080; onChanged(); return this; } /** * * *
       * Type of the resource. Always compute#attachedDisk for attached
       * disks.
       * 
* * string kind = 8; * * @return This builder for chaining. */ public Builder clearKind() { kind_ = getDefaultInstance().getKind(); bitField0_ = (bitField0_ & ~0x00000080); onChanged(); return this; } /** * * *
       * Type of the resource. Always compute#attachedDisk for attached
       * disks.
       * 
* * string kind = 8; * * @param value The bytes for kind to set. * @return This builder for chaining. */ public Builder setKindBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); kind_ = value; bitField0_ |= 0x00000080; onChanged(); return this; } private com.google.protobuf.LazyStringArrayList licenses_ = com.google.protobuf.LazyStringArrayList.emptyList(); private void ensureLicensesIsMutable() { if (!licenses_.isModifiable()) { licenses_ = new com.google.protobuf.LazyStringArrayList(licenses_); } bitField0_ |= 0x00000100; } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @return A list containing the licenses. */ public com.google.protobuf.ProtocolStringList getLicensesList() { licenses_.makeImmutable(); return licenses_; } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @return The count of licenses. */ public int getLicensesCount() { return licenses_.size(); } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @param index The index of the element to return. * @return The licenses at the given index. */ public java.lang.String getLicenses(int index) { return licenses_.get(index); } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @param index The index of the value to return. * @return The bytes of the licenses at the given index. */ public com.google.protobuf.ByteString getLicensesBytes(int index) { return licenses_.getByteString(index); } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @param index The index to set the value at. * @param value The licenses to set. * @return This builder for chaining. */ public Builder setLicenses(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureLicensesIsMutable(); licenses_.set(index, value); bitField0_ |= 0x00000100; onChanged(); return this; } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @param value The licenses to add. * @return This builder for chaining. */ public Builder addLicenses(java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureLicensesIsMutable(); licenses_.add(value); bitField0_ |= 0x00000100; onChanged(); return this; } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @param values The licenses to add. * @return This builder for chaining. */ public Builder addAllLicenses(java.lang.Iterable values) { ensureLicensesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, licenses_); bitField0_ |= 0x00000100; onChanged(); return this; } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @return This builder for chaining. */ public Builder clearLicenses() { licenses_ = com.google.protobuf.LazyStringArrayList.emptyList(); bitField0_ = (bitField0_ & ~0x00000100); ; onChanged(); return this; } /** * * *
       * A list of publicly visible licenses. Reserved for Google's use.
       * A License represents billing and aggregate usage data for public
       * and marketplace images.
       * 
* * repeated string licenses = 9; * * @param value The bytes of the licenses to add. * @return This builder for chaining. */ public Builder addLicensesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); ensureLicensesIsMutable(); licenses_.add(value); bitField0_ |= 0x00000100; onChanged(); return this; } private java.lang.Object mode_ = ""; /** * * *
       * The mode in which to attach this disk, either `READ_WRITE` or
       * `READ_ONLY`. If not specified, the default is to attach the disk in
       * `READ_WRITE` mode. Valid values:
       *
       * * `READ_ONLY`
       * * `READ_WRITE`
       * 
* * string mode = 10; * * @return The mode. */ public java.lang.String getMode() { java.lang.Object ref = mode_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); mode_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * The mode in which to attach this disk, either `READ_WRITE` or
       * `READ_ONLY`. If not specified, the default is to attach the disk in
       * `READ_WRITE` mode. Valid values:
       *
       * * `READ_ONLY`
       * * `READ_WRITE`
       * 
* * string mode = 10; * * @return The bytes for mode. */ public com.google.protobuf.ByteString getModeBytes() { java.lang.Object ref = mode_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); mode_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * The mode in which to attach this disk, either `READ_WRITE` or
       * `READ_ONLY`. If not specified, the default is to attach the disk in
       * `READ_WRITE` mode. Valid values:
       *
       * * `READ_ONLY`
       * * `READ_WRITE`
       * 
* * string mode = 10; * * @param value The mode to set. * @return This builder for chaining. */ public Builder setMode(java.lang.String value) { if (value == null) { throw new NullPointerException(); } mode_ = value; bitField0_ |= 0x00000200; onChanged(); return this; } /** * * *
       * The mode in which to attach this disk, either `READ_WRITE` or
       * `READ_ONLY`. If not specified, the default is to attach the disk in
       * `READ_WRITE` mode. Valid values:
       *
       * * `READ_ONLY`
       * * `READ_WRITE`
       * 
* * string mode = 10; * * @return This builder for chaining. */ public Builder clearMode() { mode_ = getDefaultInstance().getMode(); bitField0_ = (bitField0_ & ~0x00000200); onChanged(); return this; } /** * * *
       * The mode in which to attach this disk, either `READ_WRITE` or
       * `READ_ONLY`. If not specified, the default is to attach the disk in
       * `READ_WRITE` mode. Valid values:
       *
       * * `READ_ONLY`
       * * `READ_WRITE`
       * 
* * string mode = 10; * * @param value The bytes for mode to set. * @return This builder for chaining. */ public Builder setModeBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); mode_ = value; bitField0_ |= 0x00000200; onChanged(); return this; } private java.lang.Object source_ = ""; /** * * *
       * Indicates a valid partial or full URL to an existing Persistent Disk
       * resource.
       * 
* * string source = 11; * * @return The source. */ public java.lang.String getSource() { java.lang.Object ref = source_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); source_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Indicates a valid partial or full URL to an existing Persistent Disk
       * resource.
       * 
* * string source = 11; * * @return The bytes for source. */ public com.google.protobuf.ByteString getSourceBytes() { java.lang.Object ref = source_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); source_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Indicates a valid partial or full URL to an existing Persistent Disk
       * resource.
       * 
* * string source = 11; * * @param value The source to set. * @return This builder for chaining. */ public Builder setSource(java.lang.String value) { if (value == null) { throw new NullPointerException(); } source_ = value; bitField0_ |= 0x00000400; onChanged(); return this; } /** * * *
       * Indicates a valid partial or full URL to an existing Persistent Disk
       * resource.
       * 
* * string source = 11; * * @return This builder for chaining. */ public Builder clearSource() { source_ = getDefaultInstance().getSource(); bitField0_ = (bitField0_ & ~0x00000400); onChanged(); return this; } /** * * *
       * Indicates a valid partial or full URL to an existing Persistent Disk
       * resource.
       * 
* * string source = 11; * * @param value The bytes for source to set. * @return This builder for chaining. */ public Builder setSourceBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); source_ = value; bitField0_ |= 0x00000400; onChanged(); return this; } private java.lang.Object type_ = ""; /** * * *
       * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
       * Valid values:
       *
       * * `PERSISTENT`
       * * `SCRATCH`
       * 
* * string type = 12; * * @return The type. */ public java.lang.String getType() { java.lang.Object ref = type_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); type_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
       * Valid values:
       *
       * * `PERSISTENT`
       * * `SCRATCH`
       * 
* * string type = 12; * * @return The bytes for type. */ public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); type_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
       * Valid values:
       *
       * * `PERSISTENT`
       * * `SCRATCH`
       * 
* * string type = 12; * * @param value The type to set. * @return This builder for chaining. */ public Builder setType(java.lang.String value) { if (value == null) { throw new NullPointerException(); } type_ = value; bitField0_ |= 0x00000800; onChanged(); return this; } /** * * *
       * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
       * Valid values:
       *
       * * `PERSISTENT`
       * * `SCRATCH`
       * 
* * string type = 12; * * @return This builder for chaining. */ public Builder clearType() { type_ = getDefaultInstance().getType(); bitField0_ = (bitField0_ & ~0x00000800); onChanged(); return this; } /** * * *
       * Indicates the type of the disk, either `SCRATCH` or `PERSISTENT`.
       * Valid values:
       *
       * * `PERSISTENT`
       * * `SCRATCH`
       * 
* * string type = 12; * * @param value The bytes for type to set. * @return This builder for chaining. */ public Builder setTypeBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); type_ = value; bitField0_ |= 0x00000800; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.notebooks.v1.Instance.Disk) } // @@protoc_insertion_point(class_scope:google.cloud.notebooks.v1.Instance.Disk) private static final com.google.cloud.notebooks.v1.Instance.Disk DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.notebooks.v1.Instance.Disk(); } public static com.google.cloud.notebooks.v1.Instance.Disk getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public Disk parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface ShieldedInstanceConfigOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig) com.google.protobuf.MessageOrBuilder { /** * * *
     * Defines whether the instance has Secure Boot enabled.
     *
     * Secure Boot helps ensure that the system only runs authentic software by
     * verifying the digital signature of all boot components, and halting the
     * boot process if signature verification fails. Disabled by default.
     * 
* * bool enable_secure_boot = 1; * * @return The enableSecureBoot. */ boolean getEnableSecureBoot(); /** * * *
     * Defines whether the instance has the vTPM enabled. Enabled by default.
     * 
* * bool enable_vtpm = 2; * * @return The enableVtpm. */ boolean getEnableVtpm(); /** * * *
     * Defines whether the instance has integrity monitoring enabled.
     *
     * Enables monitoring and attestation of the boot integrity of the instance.
     * The attestation is performed against the integrity policy baseline. This
     * baseline is initially derived from the implicitly trusted boot image when
     * the instance is created. Enabled by default.
     * 
* * bool enable_integrity_monitoring = 3; * * @return The enableIntegrityMonitoring. */ boolean getEnableIntegrityMonitoring(); } /** * * *
   * A set of Shielded Instance options.
   * Check [Images using supported Shielded VM
   * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
   * Not all combinations are valid.
   * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig} */ public static final class ShieldedInstanceConfig extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig) ShieldedInstanceConfigOrBuilder { private static final long serialVersionUID = 0L; // Use ShieldedInstanceConfig.newBuilder() to construct. private ShieldedInstanceConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private ShieldedInstanceConfig() {} @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ShieldedInstanceConfig(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_ShieldedInstanceConfig_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_ShieldedInstanceConfig_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.class, com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.Builder.class); } public static final int ENABLE_SECURE_BOOT_FIELD_NUMBER = 1; private boolean enableSecureBoot_ = false; /** * * *
     * Defines whether the instance has Secure Boot enabled.
     *
     * Secure Boot helps ensure that the system only runs authentic software by
     * verifying the digital signature of all boot components, and halting the
     * boot process if signature verification fails. Disabled by default.
     * 
* * bool enable_secure_boot = 1; * * @return The enableSecureBoot. */ @java.lang.Override public boolean getEnableSecureBoot() { return enableSecureBoot_; } public static final int ENABLE_VTPM_FIELD_NUMBER = 2; private boolean enableVtpm_ = false; /** * * *
     * Defines whether the instance has the vTPM enabled. Enabled by default.
     * 
* * bool enable_vtpm = 2; * * @return The enableVtpm. */ @java.lang.Override public boolean getEnableVtpm() { return enableVtpm_; } public static final int ENABLE_INTEGRITY_MONITORING_FIELD_NUMBER = 3; private boolean enableIntegrityMonitoring_ = false; /** * * *
     * Defines whether the instance has integrity monitoring enabled.
     *
     * Enables monitoring and attestation of the boot integrity of the instance.
     * The attestation is performed against the integrity policy baseline. This
     * baseline is initially derived from the implicitly trusted boot image when
     * the instance is created. Enabled by default.
     * 
* * bool enable_integrity_monitoring = 3; * * @return The enableIntegrityMonitoring. */ @java.lang.Override public boolean getEnableIntegrityMonitoring() { return enableIntegrityMonitoring_; } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (enableSecureBoot_ != false) { output.writeBool(1, enableSecureBoot_); } if (enableVtpm_ != false) { output.writeBool(2, enableVtpm_); } if (enableIntegrityMonitoring_ != false) { output.writeBool(3, enableIntegrityMonitoring_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (enableSecureBoot_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, enableSecureBoot_); } if (enableVtpm_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, enableVtpm_); } if (enableIntegrityMonitoring_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, enableIntegrityMonitoring_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig)) { return super.equals(obj); } com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig other = (com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig) obj; if (getEnableSecureBoot() != other.getEnableSecureBoot()) return false; if (getEnableVtpm() != other.getEnableVtpm()) return false; if (getEnableIntegrityMonitoring() != other.getEnableIntegrityMonitoring()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + ENABLE_SECURE_BOOT_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnableSecureBoot()); hash = (37 * hash) + ENABLE_VTPM_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnableVtpm()); hash = (37 * hash) + ENABLE_INTEGRITY_MONITORING_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnableIntegrityMonitoring()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * A set of Shielded Instance options.
     * Check [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * Not all combinations are valid.
     * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig) com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfigOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_ShieldedInstanceConfig_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_ShieldedInstanceConfig_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.class, com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.Builder.class); } // Construct using com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; enableSecureBoot_ = false; enableVtpm_ = false; enableIntegrityMonitoring_ = false; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_ShieldedInstanceConfig_descriptor; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig getDefaultInstanceForType() { return com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.getDefaultInstance(); } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig build() { com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig buildPartial() { com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig result = new com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0( com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.enableSecureBoot_ = enableSecureBoot_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.enableVtpm_ = enableVtpm_; } if (((from_bitField0_ & 0x00000004) != 0)) { result.enableIntegrityMonitoring_ = enableIntegrityMonitoring_; } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig) { return mergeFrom((com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom( com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig other) { if (other == com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.getDefaultInstance()) return this; if (other.getEnableSecureBoot() != false) { setEnableSecureBoot(other.getEnableSecureBoot()); } if (other.getEnableVtpm() != false) { setEnableVtpm(other.getEnableVtpm()); } if (other.getEnableIntegrityMonitoring() != false) { setEnableIntegrityMonitoring(other.getEnableIntegrityMonitoring()); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 8: { enableSecureBoot_ = input.readBool(); bitField0_ |= 0x00000001; break; } // case 8 case 16: { enableVtpm_ = input.readBool(); bitField0_ |= 0x00000002; break; } // case 16 case 24: { enableIntegrityMonitoring_ = input.readBool(); bitField0_ |= 0x00000004; break; } // case 24 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private boolean enableSecureBoot_; /** * * *
       * Defines whether the instance has Secure Boot enabled.
       *
       * Secure Boot helps ensure that the system only runs authentic software by
       * verifying the digital signature of all boot components, and halting the
       * boot process if signature verification fails. Disabled by default.
       * 
* * bool enable_secure_boot = 1; * * @return The enableSecureBoot. */ @java.lang.Override public boolean getEnableSecureBoot() { return enableSecureBoot_; } /** * * *
       * Defines whether the instance has Secure Boot enabled.
       *
       * Secure Boot helps ensure that the system only runs authentic software by
       * verifying the digital signature of all boot components, and halting the
       * boot process if signature verification fails. Disabled by default.
       * 
* * bool enable_secure_boot = 1; * * @param value The enableSecureBoot to set. * @return This builder for chaining. */ public Builder setEnableSecureBoot(boolean value) { enableSecureBoot_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * Defines whether the instance has Secure Boot enabled.
       *
       * Secure Boot helps ensure that the system only runs authentic software by
       * verifying the digital signature of all boot components, and halting the
       * boot process if signature verification fails. Disabled by default.
       * 
* * bool enable_secure_boot = 1; * * @return This builder for chaining. */ public Builder clearEnableSecureBoot() { bitField0_ = (bitField0_ & ~0x00000001); enableSecureBoot_ = false; onChanged(); return this; } private boolean enableVtpm_; /** * * *
       * Defines whether the instance has the vTPM enabled. Enabled by default.
       * 
* * bool enable_vtpm = 2; * * @return The enableVtpm. */ @java.lang.Override public boolean getEnableVtpm() { return enableVtpm_; } /** * * *
       * Defines whether the instance has the vTPM enabled. Enabled by default.
       * 
* * bool enable_vtpm = 2; * * @param value The enableVtpm to set. * @return This builder for chaining. */ public Builder setEnableVtpm(boolean value) { enableVtpm_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * Defines whether the instance has the vTPM enabled. Enabled by default.
       * 
* * bool enable_vtpm = 2; * * @return This builder for chaining. */ public Builder clearEnableVtpm() { bitField0_ = (bitField0_ & ~0x00000002); enableVtpm_ = false; onChanged(); return this; } private boolean enableIntegrityMonitoring_; /** * * *
       * Defines whether the instance has integrity monitoring enabled.
       *
       * Enables monitoring and attestation of the boot integrity of the instance.
       * The attestation is performed against the integrity policy baseline. This
       * baseline is initially derived from the implicitly trusted boot image when
       * the instance is created. Enabled by default.
       * 
* * bool enable_integrity_monitoring = 3; * * @return The enableIntegrityMonitoring. */ @java.lang.Override public boolean getEnableIntegrityMonitoring() { return enableIntegrityMonitoring_; } /** * * *
       * Defines whether the instance has integrity monitoring enabled.
       *
       * Enables monitoring and attestation of the boot integrity of the instance.
       * The attestation is performed against the integrity policy baseline. This
       * baseline is initially derived from the implicitly trusted boot image when
       * the instance is created. Enabled by default.
       * 
* * bool enable_integrity_monitoring = 3; * * @param value The enableIntegrityMonitoring to set. * @return This builder for chaining. */ public Builder setEnableIntegrityMonitoring(boolean value) { enableIntegrityMonitoring_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } /** * * *
       * Defines whether the instance has integrity monitoring enabled.
       *
       * Enables monitoring and attestation of the boot integrity of the instance.
       * The attestation is performed against the integrity policy baseline. This
       * baseline is initially derived from the implicitly trusted boot image when
       * the instance is created. Enabled by default.
       * 
* * bool enable_integrity_monitoring = 3; * * @return This builder for chaining. */ public Builder clearEnableIntegrityMonitoring() { bitField0_ = (bitField0_ & ~0x00000004); enableIntegrityMonitoring_ = false; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig) } // @@protoc_insertion_point(class_scope:google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig) private static final com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig(); } public static com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public ShieldedInstanceConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface UpgradeHistoryEntryOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry) com.google.protobuf.MessageOrBuilder { /** * * *
     * The snapshot of the boot disk of this notebook instance before upgrade.
     * 
* * string snapshot = 1; * * @return The snapshot. */ java.lang.String getSnapshot(); /** * * *
     * The snapshot of the boot disk of this notebook instance before upgrade.
     * 
* * string snapshot = 1; * * @return The bytes for snapshot. */ com.google.protobuf.ByteString getSnapshotBytes(); /** * * *
     * The VM image before this instance upgrade.
     * 
* * string vm_image = 2; * * @return The vmImage. */ java.lang.String getVmImage(); /** * * *
     * The VM image before this instance upgrade.
     * 
* * string vm_image = 2; * * @return The bytes for vmImage. */ com.google.protobuf.ByteString getVmImageBytes(); /** * * *
     * The container image before this instance upgrade.
     * 
* * string container_image = 3; * * @return The containerImage. */ java.lang.String getContainerImage(); /** * * *
     * The container image before this instance upgrade.
     * 
* * string container_image = 3; * * @return The bytes for containerImage. */ com.google.protobuf.ByteString getContainerImageBytes(); /** * * *
     * The framework of this notebook instance.
     * 
* * string framework = 4; * * @return The framework. */ java.lang.String getFramework(); /** * * *
     * The framework of this notebook instance.
     * 
* * string framework = 4; * * @return The bytes for framework. */ com.google.protobuf.ByteString getFrameworkBytes(); /** * * *
     * The version of the notebook instance before this upgrade.
     * 
* * string version = 5; * * @return The version. */ java.lang.String getVersion(); /** * * *
     * The version of the notebook instance before this upgrade.
     * 
* * string version = 5; * * @return The bytes for version. */ com.google.protobuf.ByteString getVersionBytes(); /** * * *
     * The state of this instance upgrade history entry.
     * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @return The enum numeric value on the wire for state. */ int getStateValue(); /** * * *
     * The state of this instance upgrade history entry.
     * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @return The state. */ com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State getState(); /** * * *
     * The time that this instance upgrade history entry is created.
     * 
* * .google.protobuf.Timestamp create_time = 7; * * @return Whether the createTime field is set. */ boolean hasCreateTime(); /** * * *
     * The time that this instance upgrade history entry is created.
     * 
* * .google.protobuf.Timestamp create_time = 7; * * @return The createTime. */ com.google.protobuf.Timestamp getCreateTime(); /** * * *
     * The time that this instance upgrade history entry is created.
     * 
* * .google.protobuf.Timestamp create_time = 7; */ com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); /** * * *
     * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
     * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @return The targetImage. */ @java.lang.Deprecated java.lang.String getTargetImage(); /** * * *
     * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
     * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @return The bytes for targetImage. */ @java.lang.Deprecated com.google.protobuf.ByteString getTargetImageBytes(); /** * * *
     * Action. Rolloback or Upgrade.
     * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @return The enum numeric value on the wire for action. */ int getActionValue(); /** * * *
     * Action. Rolloback or Upgrade.
     * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @return The action. */ com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action getAction(); /** * * *
     * Target VM Version, like m63.
     * 
* * string target_version = 10; * * @return The targetVersion. */ java.lang.String getTargetVersion(); /** * * *
     * Target VM Version, like m63.
     * 
* * string target_version = 10; * * @return The bytes for targetVersion. */ com.google.protobuf.ByteString getTargetVersionBytes(); } /** * * *
   * The entry of VM image upgrade history.
   * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry} */ public static final class UpgradeHistoryEntry extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry) UpgradeHistoryEntryOrBuilder { private static final long serialVersionUID = 0L; // Use UpgradeHistoryEntry.newBuilder() to construct. private UpgradeHistoryEntry(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private UpgradeHistoryEntry() { snapshot_ = ""; vmImage_ = ""; containerImage_ = ""; framework_ = ""; version_ = ""; state_ = 0; targetImage_ = ""; action_ = 0; targetVersion_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new UpgradeHistoryEntry(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_UpgradeHistoryEntry_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_UpgradeHistoryEntry_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.class, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder.class); } /** * * *
     * The definition of the states of this upgrade history entry.
     * 
* * Protobuf enum {@code google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State} */ public enum State implements com.google.protobuf.ProtocolMessageEnum { /** * * *
       * State is not specified.
       * 
* * STATE_UNSPECIFIED = 0; */ STATE_UNSPECIFIED(0), /** * * *
       * The instance upgrade is started.
       * 
* * STARTED = 1; */ STARTED(1), /** * * *
       * The instance upgrade is succeeded.
       * 
* * SUCCEEDED = 2; */ SUCCEEDED(2), /** * * *
       * The instance upgrade is failed.
       * 
* * FAILED = 3; */ FAILED(3), UNRECOGNIZED(-1), ; /** * * *
       * State is not specified.
       * 
* * STATE_UNSPECIFIED = 0; */ public static final int STATE_UNSPECIFIED_VALUE = 0; /** * * *
       * The instance upgrade is started.
       * 
* * STARTED = 1; */ public static final int STARTED_VALUE = 1; /** * * *
       * The instance upgrade is succeeded.
       * 
* * SUCCEEDED = 2; */ public static final int SUCCEEDED_VALUE = 2; /** * * *
       * The instance upgrade is failed.
       * 
* * FAILED = 3; */ public static final int FAILED_VALUE = 3; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static State valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static State forNumber(int value) { switch (value) { case 0: return STATE_UNSPECIFIED; case 1: return STARTED; case 2: return SUCCEEDED; case 3: return FAILED; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public State findValueByNumber(int number) { return State.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.getDescriptor() .getEnumTypes() .get(0); } private static final State[] VALUES = values(); public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private State(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State) } /** * * *
     * The definition of operations of this upgrade history entry.
     * 
* * Protobuf enum {@code google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action} */ public enum Action implements com.google.protobuf.ProtocolMessageEnum { /** * * *
       * Operation is not specified.
       * 
* * ACTION_UNSPECIFIED = 0; */ ACTION_UNSPECIFIED(0), /** * * *
       * Upgrade.
       * 
* * UPGRADE = 1; */ UPGRADE(1), /** * * *
       * Rollback.
       * 
* * ROLLBACK = 2; */ ROLLBACK(2), UNRECOGNIZED(-1), ; /** * * *
       * Operation is not specified.
       * 
* * ACTION_UNSPECIFIED = 0; */ public static final int ACTION_UNSPECIFIED_VALUE = 0; /** * * *
       * Upgrade.
       * 
* * UPGRADE = 1; */ public static final int UPGRADE_VALUE = 1; /** * * *
       * Rollback.
       * 
* * ROLLBACK = 2; */ public static final int ROLLBACK_VALUE = 2; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static Action valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static Action forNumber(int value) { switch (value) { case 0: return ACTION_UNSPECIFIED; case 1: return UPGRADE; case 2: return ROLLBACK; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public Action findValueByNumber(int number) { return Action.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.getDescriptor() .getEnumTypes() .get(1); } private static final Action[] VALUES = values(); public static Action valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private Action(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action) } private int bitField0_; public static final int SNAPSHOT_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object snapshot_ = ""; /** * * *
     * The snapshot of the boot disk of this notebook instance before upgrade.
     * 
* * string snapshot = 1; * * @return The snapshot. */ @java.lang.Override public java.lang.String getSnapshot() { java.lang.Object ref = snapshot_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); snapshot_ = s; return s; } } /** * * *
     * The snapshot of the boot disk of this notebook instance before upgrade.
     * 
* * string snapshot = 1; * * @return The bytes for snapshot. */ @java.lang.Override public com.google.protobuf.ByteString getSnapshotBytes() { java.lang.Object ref = snapshot_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); snapshot_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int VM_IMAGE_FIELD_NUMBER = 2; @SuppressWarnings("serial") private volatile java.lang.Object vmImage_ = ""; /** * * *
     * The VM image before this instance upgrade.
     * 
* * string vm_image = 2; * * @return The vmImage. */ @java.lang.Override public java.lang.String getVmImage() { java.lang.Object ref = vmImage_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); vmImage_ = s; return s; } } /** * * *
     * The VM image before this instance upgrade.
     * 
* * string vm_image = 2; * * @return The bytes for vmImage. */ @java.lang.Override public com.google.protobuf.ByteString getVmImageBytes() { java.lang.Object ref = vmImage_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); vmImage_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int CONTAINER_IMAGE_FIELD_NUMBER = 3; @SuppressWarnings("serial") private volatile java.lang.Object containerImage_ = ""; /** * * *
     * The container image before this instance upgrade.
     * 
* * string container_image = 3; * * @return The containerImage. */ @java.lang.Override public java.lang.String getContainerImage() { java.lang.Object ref = containerImage_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); containerImage_ = s; return s; } } /** * * *
     * The container image before this instance upgrade.
     * 
* * string container_image = 3; * * @return The bytes for containerImage. */ @java.lang.Override public com.google.protobuf.ByteString getContainerImageBytes() { java.lang.Object ref = containerImage_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); containerImage_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int FRAMEWORK_FIELD_NUMBER = 4; @SuppressWarnings("serial") private volatile java.lang.Object framework_ = ""; /** * * *
     * The framework of this notebook instance.
     * 
* * string framework = 4; * * @return The framework. */ @java.lang.Override public java.lang.String getFramework() { java.lang.Object ref = framework_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); framework_ = s; return s; } } /** * * *
     * The framework of this notebook instance.
     * 
* * string framework = 4; * * @return The bytes for framework. */ @java.lang.Override public com.google.protobuf.ByteString getFrameworkBytes() { java.lang.Object ref = framework_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); framework_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int VERSION_FIELD_NUMBER = 5; @SuppressWarnings("serial") private volatile java.lang.Object version_ = ""; /** * * *
     * The version of the notebook instance before this upgrade.
     * 
* * string version = 5; * * @return The version. */ @java.lang.Override public java.lang.String getVersion() { java.lang.Object ref = version_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); version_ = s; return s; } } /** * * *
     * The version of the notebook instance before this upgrade.
     * 
* * string version = 5; * * @return The bytes for version. */ @java.lang.Override public com.google.protobuf.ByteString getVersionBytes() { java.lang.Object ref = version_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); version_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int STATE_FIELD_NUMBER = 6; private int state_ = 0; /** * * *
     * The state of this instance upgrade history entry.
     * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @return The enum numeric value on the wire for state. */ @java.lang.Override public int getStateValue() { return state_; } /** * * *
     * The state of this instance upgrade history entry.
     * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @return The state. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State getState() { com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State result = com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State.forNumber(state_); return result == null ? com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State.UNRECOGNIZED : result; } public static final int CREATE_TIME_FIELD_NUMBER = 7; private com.google.protobuf.Timestamp createTime_; /** * * *
     * The time that this instance upgrade history entry is created.
     * 
* * .google.protobuf.Timestamp create_time = 7; * * @return Whether the createTime field is set. */ @java.lang.Override public boolean hasCreateTime() { return ((bitField0_ & 0x00000001) != 0); } /** * * *
     * The time that this instance upgrade history entry is created.
     * 
* * .google.protobuf.Timestamp create_time = 7; * * @return The createTime. */ @java.lang.Override public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } /** * * *
     * The time that this instance upgrade history entry is created.
     * 
* * .google.protobuf.Timestamp create_time = 7; */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } public static final int TARGET_IMAGE_FIELD_NUMBER = 8; @SuppressWarnings("serial") private volatile java.lang.Object targetImage_ = ""; /** * * *
     * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
     * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @return The targetImage. */ @java.lang.Override @java.lang.Deprecated public java.lang.String getTargetImage() { java.lang.Object ref = targetImage_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); targetImage_ = s; return s; } } /** * * *
     * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
     * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @return The bytes for targetImage. */ @java.lang.Override @java.lang.Deprecated public com.google.protobuf.ByteString getTargetImageBytes() { java.lang.Object ref = targetImage_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); targetImage_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int ACTION_FIELD_NUMBER = 9; private int action_ = 0; /** * * *
     * Action. Rolloback or Upgrade.
     * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @return The enum numeric value on the wire for action. */ @java.lang.Override public int getActionValue() { return action_; } /** * * *
     * Action. Rolloback or Upgrade.
     * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @return The action. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action getAction() { com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action result = com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action.forNumber(action_); return result == null ? com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action.UNRECOGNIZED : result; } public static final int TARGET_VERSION_FIELD_NUMBER = 10; @SuppressWarnings("serial") private volatile java.lang.Object targetVersion_ = ""; /** * * *
     * Target VM Version, like m63.
     * 
* * string target_version = 10; * * @return The targetVersion. */ @java.lang.Override public java.lang.String getTargetVersion() { java.lang.Object ref = targetVersion_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); targetVersion_ = s; return s; } } /** * * *
     * Target VM Version, like m63.
     * 
* * string target_version = 10; * * @return The bytes for targetVersion. */ @java.lang.Override public com.google.protobuf.ByteString getTargetVersionBytes() { java.lang.Object ref = targetVersion_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); targetVersion_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(snapshot_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, snapshot_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(vmImage_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, vmImage_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(containerImage_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, containerImage_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(framework_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, framework_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(version_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 5, version_); } if (state_ != com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State.STATE_UNSPECIFIED .getNumber()) { output.writeEnum(6, state_); } if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(7, getCreateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(targetImage_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 8, targetImage_); } if (action_ != com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action.ACTION_UNSPECIFIED .getNumber()) { output.writeEnum(9, action_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(targetVersion_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 10, targetVersion_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(snapshot_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, snapshot_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(vmImage_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, vmImage_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(containerImage_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, containerImage_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(framework_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, framework_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(version_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, version_); } if (state_ != com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State.STATE_UNSPECIFIED .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(6, state_); } if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getCreateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(targetImage_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, targetImage_); } if (action_ != com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action.ACTION_UNSPECIFIED .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(9, action_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(targetVersion_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, targetVersion_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry)) { return super.equals(obj); } com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry other = (com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry) obj; if (!getSnapshot().equals(other.getSnapshot())) return false; if (!getVmImage().equals(other.getVmImage())) return false; if (!getContainerImage().equals(other.getContainerImage())) return false; if (!getFramework().equals(other.getFramework())) return false; if (!getVersion().equals(other.getVersion())) return false; if (state_ != other.state_) return false; if (hasCreateTime() != other.hasCreateTime()) return false; if (hasCreateTime()) { if (!getCreateTime().equals(other.getCreateTime())) return false; } if (!getTargetImage().equals(other.getTargetImage())) return false; if (action_ != other.action_) return false; if (!getTargetVersion().equals(other.getTargetVersion())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + SNAPSHOT_FIELD_NUMBER; hash = (53 * hash) + getSnapshot().hashCode(); hash = (37 * hash) + VM_IMAGE_FIELD_NUMBER; hash = (53 * hash) + getVmImage().hashCode(); hash = (37 * hash) + CONTAINER_IMAGE_FIELD_NUMBER; hash = (53 * hash) + getContainerImage().hashCode(); hash = (37 * hash) + FRAMEWORK_FIELD_NUMBER; hash = (53 * hash) + getFramework().hashCode(); hash = (37 * hash) + VERSION_FIELD_NUMBER; hash = (53 * hash) + getVersion().hashCode(); hash = (37 * hash) + STATE_FIELD_NUMBER; hash = (53 * hash) + state_; if (hasCreateTime()) { hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; hash = (53 * hash) + getCreateTime().hashCode(); } hash = (37 * hash) + TARGET_IMAGE_FIELD_NUMBER; hash = (53 * hash) + getTargetImage().hashCode(); hash = (37 * hash) + ACTION_FIELD_NUMBER; hash = (53 * hash) + action_; hash = (37 * hash) + TARGET_VERSION_FIELD_NUMBER; hash = (53 * hash) + getTargetVersion().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * The entry of VM image upgrade history.
     * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry) com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntryOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_UpgradeHistoryEntry_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_UpgradeHistoryEntry_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.class, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder.class); } // Construct using com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getCreateTimeFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; snapshot_ = ""; vmImage_ = ""; containerImage_ = ""; framework_ = ""; version_ = ""; state_ = 0; createTime_ = null; if (createTimeBuilder_ != null) { createTimeBuilder_.dispose(); createTimeBuilder_ = null; } targetImage_ = ""; action_ = 0; targetVersion_ = ""; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_UpgradeHistoryEntry_descriptor; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry getDefaultInstanceForType() { return com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.getDefaultInstance(); } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry build() { com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry buildPartial() { com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry result = new com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.snapshot_ = snapshot_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.vmImage_ = vmImage_; } if (((from_bitField0_ & 0x00000004) != 0)) { result.containerImage_ = containerImage_; } if (((from_bitField0_ & 0x00000008) != 0)) { result.framework_ = framework_; } if (((from_bitField0_ & 0x00000010) != 0)) { result.version_ = version_; } if (((from_bitField0_ & 0x00000020) != 0)) { result.state_ = state_; } int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000040) != 0)) { result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); to_bitField0_ |= 0x00000001; } if (((from_bitField0_ & 0x00000080) != 0)) { result.targetImage_ = targetImage_; } if (((from_bitField0_ & 0x00000100) != 0)) { result.action_ = action_; } if (((from_bitField0_ & 0x00000200) != 0)) { result.targetVersion_ = targetVersion_; } result.bitField0_ |= to_bitField0_; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry) { return mergeFrom((com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry other) { if (other == com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.getDefaultInstance()) return this; if (!other.getSnapshot().isEmpty()) { snapshot_ = other.snapshot_; bitField0_ |= 0x00000001; onChanged(); } if (!other.getVmImage().isEmpty()) { vmImage_ = other.vmImage_; bitField0_ |= 0x00000002; onChanged(); } if (!other.getContainerImage().isEmpty()) { containerImage_ = other.containerImage_; bitField0_ |= 0x00000004; onChanged(); } if (!other.getFramework().isEmpty()) { framework_ = other.framework_; bitField0_ |= 0x00000008; onChanged(); } if (!other.getVersion().isEmpty()) { version_ = other.version_; bitField0_ |= 0x00000010; onChanged(); } if (other.state_ != 0) { setStateValue(other.getStateValue()); } if (other.hasCreateTime()) { mergeCreateTime(other.getCreateTime()); } if (!other.getTargetImage().isEmpty()) { targetImage_ = other.targetImage_; bitField0_ |= 0x00000080; onChanged(); } if (other.action_ != 0) { setActionValue(other.getActionValue()); } if (!other.getTargetVersion().isEmpty()) { targetVersion_ = other.targetVersion_; bitField0_ |= 0x00000200; onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { snapshot_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 18: { vmImage_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000002; break; } // case 18 case 26: { containerImage_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000004; break; } // case 26 case 34: { framework_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000008; break; } // case 34 case 42: { version_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000010; break; } // case 42 case 48: { state_ = input.readEnum(); bitField0_ |= 0x00000020; break; } // case 48 case 58: { input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000040; break; } // case 58 case 66: { targetImage_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000080; break; } // case 66 case 72: { action_ = input.readEnum(); bitField0_ |= 0x00000100; break; } // case 72 case 82: { targetVersion_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000200; break; } // case 82 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.lang.Object snapshot_ = ""; /** * * *
       * The snapshot of the boot disk of this notebook instance before upgrade.
       * 
* * string snapshot = 1; * * @return The snapshot. */ public java.lang.String getSnapshot() { java.lang.Object ref = snapshot_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); snapshot_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * The snapshot of the boot disk of this notebook instance before upgrade.
       * 
* * string snapshot = 1; * * @return The bytes for snapshot. */ public com.google.protobuf.ByteString getSnapshotBytes() { java.lang.Object ref = snapshot_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); snapshot_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * The snapshot of the boot disk of this notebook instance before upgrade.
       * 
* * string snapshot = 1; * * @param value The snapshot to set. * @return This builder for chaining. */ public Builder setSnapshot(java.lang.String value) { if (value == null) { throw new NullPointerException(); } snapshot_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * The snapshot of the boot disk of this notebook instance before upgrade.
       * 
* * string snapshot = 1; * * @return This builder for chaining. */ public Builder clearSnapshot() { snapshot_ = getDefaultInstance().getSnapshot(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * * *
       * The snapshot of the boot disk of this notebook instance before upgrade.
       * 
* * string snapshot = 1; * * @param value The bytes for snapshot to set. * @return This builder for chaining. */ public Builder setSnapshotBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); snapshot_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private java.lang.Object vmImage_ = ""; /** * * *
       * The VM image before this instance upgrade.
       * 
* * string vm_image = 2; * * @return The vmImage. */ public java.lang.String getVmImage() { java.lang.Object ref = vmImage_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); vmImage_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * The VM image before this instance upgrade.
       * 
* * string vm_image = 2; * * @return The bytes for vmImage. */ public com.google.protobuf.ByteString getVmImageBytes() { java.lang.Object ref = vmImage_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); vmImage_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * The VM image before this instance upgrade.
       * 
* * string vm_image = 2; * * @param value The vmImage to set. * @return This builder for chaining. */ public Builder setVmImage(java.lang.String value) { if (value == null) { throw new NullPointerException(); } vmImage_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * The VM image before this instance upgrade.
       * 
* * string vm_image = 2; * * @return This builder for chaining. */ public Builder clearVmImage() { vmImage_ = getDefaultInstance().getVmImage(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); return this; } /** * * *
       * The VM image before this instance upgrade.
       * 
* * string vm_image = 2; * * @param value The bytes for vmImage to set. * @return This builder for chaining. */ public Builder setVmImageBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); vmImage_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } private java.lang.Object containerImage_ = ""; /** * * *
       * The container image before this instance upgrade.
       * 
* * string container_image = 3; * * @return The containerImage. */ public java.lang.String getContainerImage() { java.lang.Object ref = containerImage_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); containerImage_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * The container image before this instance upgrade.
       * 
* * string container_image = 3; * * @return The bytes for containerImage. */ public com.google.protobuf.ByteString getContainerImageBytes() { java.lang.Object ref = containerImage_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); containerImage_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * The container image before this instance upgrade.
       * 
* * string container_image = 3; * * @param value The containerImage to set. * @return This builder for chaining. */ public Builder setContainerImage(java.lang.String value) { if (value == null) { throw new NullPointerException(); } containerImage_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } /** * * *
       * The container image before this instance upgrade.
       * 
* * string container_image = 3; * * @return This builder for chaining. */ public Builder clearContainerImage() { containerImage_ = getDefaultInstance().getContainerImage(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } /** * * *
       * The container image before this instance upgrade.
       * 
* * string container_image = 3; * * @param value The bytes for containerImage to set. * @return This builder for chaining. */ public Builder setContainerImageBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); containerImage_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } private java.lang.Object framework_ = ""; /** * * *
       * The framework of this notebook instance.
       * 
* * string framework = 4; * * @return The framework. */ public java.lang.String getFramework() { java.lang.Object ref = framework_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); framework_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * The framework of this notebook instance.
       * 
* * string framework = 4; * * @return The bytes for framework. */ public com.google.protobuf.ByteString getFrameworkBytes() { java.lang.Object ref = framework_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); framework_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * The framework of this notebook instance.
       * 
* * string framework = 4; * * @param value The framework to set. * @return This builder for chaining. */ public Builder setFramework(java.lang.String value) { if (value == null) { throw new NullPointerException(); } framework_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } /** * * *
       * The framework of this notebook instance.
       * 
* * string framework = 4; * * @return This builder for chaining. */ public Builder clearFramework() { framework_ = getDefaultInstance().getFramework(); bitField0_ = (bitField0_ & ~0x00000008); onChanged(); return this; } /** * * *
       * The framework of this notebook instance.
       * 
* * string framework = 4; * * @param value The bytes for framework to set. * @return This builder for chaining. */ public Builder setFrameworkBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); framework_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } private java.lang.Object version_ = ""; /** * * *
       * The version of the notebook instance before this upgrade.
       * 
* * string version = 5; * * @return The version. */ public java.lang.String getVersion() { java.lang.Object ref = version_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); version_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * The version of the notebook instance before this upgrade.
       * 
* * string version = 5; * * @return The bytes for version. */ public com.google.protobuf.ByteString getVersionBytes() { java.lang.Object ref = version_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); version_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * The version of the notebook instance before this upgrade.
       * 
* * string version = 5; * * @param value The version to set. * @return This builder for chaining. */ public Builder setVersion(java.lang.String value) { if (value == null) { throw new NullPointerException(); } version_ = value; bitField0_ |= 0x00000010; onChanged(); return this; } /** * * *
       * The version of the notebook instance before this upgrade.
       * 
* * string version = 5; * * @return This builder for chaining. */ public Builder clearVersion() { version_ = getDefaultInstance().getVersion(); bitField0_ = (bitField0_ & ~0x00000010); onChanged(); return this; } /** * * *
       * The version of the notebook instance before this upgrade.
       * 
* * string version = 5; * * @param value The bytes for version to set. * @return This builder for chaining. */ public Builder setVersionBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); version_ = value; bitField0_ |= 0x00000010; onChanged(); return this; } private int state_ = 0; /** * * *
       * The state of this instance upgrade history entry.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @return The enum numeric value on the wire for state. */ @java.lang.Override public int getStateValue() { return state_; } /** * * *
       * The state of this instance upgrade history entry.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @param value The enum numeric value on the wire for state to set. * @return This builder for chaining. */ public Builder setStateValue(int value) { state_ = value; bitField0_ |= 0x00000020; onChanged(); return this; } /** * * *
       * The state of this instance upgrade history entry.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @return The state. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State getState() { com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State result = com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State.forNumber(state_); return result == null ? com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State.UNRECOGNIZED : result; } /** * * *
       * The state of this instance upgrade history entry.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @param value The state to set. * @return This builder for chaining. */ public Builder setState( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000020; state_ = value.getNumber(); onChanged(); return this; } /** * * *
       * The state of this instance upgrade history entry.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.State state = 6; * * @return This builder for chaining. */ public Builder clearState() { bitField0_ = (bitField0_ & ~0x00000020); state_ = 0; onChanged(); return this; } private com.google.protobuf.Timestamp createTime_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; * * @return Whether the createTime field is set. */ public boolean hasCreateTime() { return ((bitField0_ & 0x00000040) != 0); } /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; * * @return The createTime. */ public com.google.protobuf.Timestamp getCreateTime() { if (createTimeBuilder_ == null) { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } else { return createTimeBuilder_.getMessage(); } } /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; */ public Builder setCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (value == null) { throw new NullPointerException(); } createTime_ = value; } else { createTimeBuilder_.setMessage(value); } bitField0_ |= 0x00000040; onChanged(); return this; } /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; */ public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (createTimeBuilder_ == null) { createTime_ = builderForValue.build(); } else { createTimeBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000040; onChanged(); return this; } /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; */ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (((bitField0_ & 0x00000040) != 0) && createTime_ != null && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getCreateTimeBuilder().mergeFrom(value); } else { createTime_ = value; } } else { createTimeBuilder_.mergeFrom(value); } if (createTime_ != null) { bitField0_ |= 0x00000040; onChanged(); } return this; } /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; */ public Builder clearCreateTime() { bitField0_ = (bitField0_ & ~0x00000040); createTime_ = null; if (createTimeBuilder_ != null) { createTimeBuilder_.dispose(); createTimeBuilder_ = null; } onChanged(); return this; } /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; */ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { bitField0_ |= 0x00000040; onChanged(); return getCreateTimeFieldBuilder().getBuilder(); } /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; */ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { if (createTimeBuilder_ != null) { return createTimeBuilder_.getMessageOrBuilder(); } else { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } } /** * * *
       * The time that this instance upgrade history entry is created.
       * 
* * .google.protobuf.Timestamp create_time = 7; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> getCreateTimeFieldBuilder() { if (createTimeBuilder_ == null) { createTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( getCreateTime(), getParentForChildren(), isClean()); createTime_ = null; } return createTimeBuilder_; } private java.lang.Object targetImage_ = ""; /** * * *
       * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
       * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @return The targetImage. */ @java.lang.Deprecated public java.lang.String getTargetImage() { java.lang.Object ref = targetImage_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); targetImage_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
       * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @return The bytes for targetImage. */ @java.lang.Deprecated public com.google.protobuf.ByteString getTargetImageBytes() { java.lang.Object ref = targetImage_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); targetImage_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
       * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @param value The targetImage to set. * @return This builder for chaining. */ @java.lang.Deprecated public Builder setTargetImage(java.lang.String value) { if (value == null) { throw new NullPointerException(); } targetImage_ = value; bitField0_ |= 0x00000080; onChanged(); return this; } /** * * *
       * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
       * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @return This builder for chaining. */ @java.lang.Deprecated public Builder clearTargetImage() { targetImage_ = getDefaultInstance().getTargetImage(); bitField0_ = (bitField0_ & ~0x00000080); onChanged(); return this; } /** * * *
       * Target VM Image. Format: `ainotebooks-vm/project/image-name/name`.
       * 
* * string target_image = 8 [deprecated = true]; * * @deprecated google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.target_image is * deprecated. See google/cloud/notebooks/v1/instance.proto;l=352 * @param value The bytes for targetImage to set. * @return This builder for chaining. */ @java.lang.Deprecated public Builder setTargetImageBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); targetImage_ = value; bitField0_ |= 0x00000080; onChanged(); return this; } private int action_ = 0; /** * * *
       * Action. Rolloback or Upgrade.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @return The enum numeric value on the wire for action. */ @java.lang.Override public int getActionValue() { return action_; } /** * * *
       * Action. Rolloback or Upgrade.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @param value The enum numeric value on the wire for action to set. * @return This builder for chaining. */ public Builder setActionValue(int value) { action_ = value; bitField0_ |= 0x00000100; onChanged(); return this; } /** * * *
       * Action. Rolloback or Upgrade.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @return The action. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action getAction() { com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action result = com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action.forNumber(action_); return result == null ? com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action.UNRECOGNIZED : result; } /** * * *
       * Action. Rolloback or Upgrade.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @param value The action to set. * @return This builder for chaining. */ public Builder setAction( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000100; action_ = value.getNumber(); onChanged(); return this; } /** * * *
       * Action. Rolloback or Upgrade.
       * 
* * .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Action action = 9; * * @return This builder for chaining. */ public Builder clearAction() { bitField0_ = (bitField0_ & ~0x00000100); action_ = 0; onChanged(); return this; } private java.lang.Object targetVersion_ = ""; /** * * *
       * Target VM Version, like m63.
       * 
* * string target_version = 10; * * @return The targetVersion. */ public java.lang.String getTargetVersion() { java.lang.Object ref = targetVersion_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); targetVersion_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Target VM Version, like m63.
       * 
* * string target_version = 10; * * @return The bytes for targetVersion. */ public com.google.protobuf.ByteString getTargetVersionBytes() { java.lang.Object ref = targetVersion_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); targetVersion_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Target VM Version, like m63.
       * 
* * string target_version = 10; * * @param value The targetVersion to set. * @return This builder for chaining. */ public Builder setTargetVersion(java.lang.String value) { if (value == null) { throw new NullPointerException(); } targetVersion_ = value; bitField0_ |= 0x00000200; onChanged(); return this; } /** * * *
       * Target VM Version, like m63.
       * 
* * string target_version = 10; * * @return This builder for chaining. */ public Builder clearTargetVersion() { targetVersion_ = getDefaultInstance().getTargetVersion(); bitField0_ = (bitField0_ & ~0x00000200); onChanged(); return this; } /** * * *
       * Target VM Version, like m63.
       * 
* * string target_version = 10; * * @param value The bytes for targetVersion to set. * @return This builder for chaining. */ public Builder setTargetVersionBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); targetVersion_ = value; bitField0_ |= 0x00000200; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry) } // @@protoc_insertion_point(class_scope:google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry) private static final com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry(); } public static com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public UpgradeHistoryEntry parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } private int bitField0_; private int environmentCase_ = 0; @SuppressWarnings("serial") private java.lang.Object environment_; public enum EnvironmentCase implements com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { VM_IMAGE(2), CONTAINER_IMAGE(3), ENVIRONMENT_NOT_SET(0); private final int value; private EnvironmentCase(int value) { this.value = value; } /** * @param value The number of the enum to look for. * @return The enum associated with the given number. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static EnvironmentCase valueOf(int value) { return forNumber(value); } public static EnvironmentCase forNumber(int value) { switch (value) { case 2: return VM_IMAGE; case 3: return CONTAINER_IMAGE; case 0: return ENVIRONMENT_NOT_SET; default: return null; } } public int getNumber() { return this.value; } }; public EnvironmentCase getEnvironmentCase() { return EnvironmentCase.forNumber(environmentCase_); } public static final int NAME_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object name_ = ""; /** * * *
   * Output only. The name of this notebook instance. Format:
   * `projects/{project_id}/locations/{location}/instances/{instance_id}`
   * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The name. */ @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** * * *
   * Output only. The name of this notebook instance. Format:
   * `projects/{project_id}/locations/{location}/instances/{instance_id}`
   * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for name. */ @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int VM_IMAGE_FIELD_NUMBER = 2; /** * * *
   * Use a Compute Engine VM image to start the notebook instance.
   * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; * * @return Whether the vmImage field is set. */ @java.lang.Override public boolean hasVmImage() { return environmentCase_ == 2; } /** * * *
   * Use a Compute Engine VM image to start the notebook instance.
   * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; * * @return The vmImage. */ @java.lang.Override public com.google.cloud.notebooks.v1.VmImage getVmImage() { if (environmentCase_ == 2) { return (com.google.cloud.notebooks.v1.VmImage) environment_; } return com.google.cloud.notebooks.v1.VmImage.getDefaultInstance(); } /** * * *
   * Use a Compute Engine VM image to start the notebook instance.
   * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; */ @java.lang.Override public com.google.cloud.notebooks.v1.VmImageOrBuilder getVmImageOrBuilder() { if (environmentCase_ == 2) { return (com.google.cloud.notebooks.v1.VmImage) environment_; } return com.google.cloud.notebooks.v1.VmImage.getDefaultInstance(); } public static final int CONTAINER_IMAGE_FIELD_NUMBER = 3; /** * * *
   * Use a container image to start the notebook instance.
   * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; * * @return Whether the containerImage field is set. */ @java.lang.Override public boolean hasContainerImage() { return environmentCase_ == 3; } /** * * *
   * Use a container image to start the notebook instance.
   * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; * * @return The containerImage. */ @java.lang.Override public com.google.cloud.notebooks.v1.ContainerImage getContainerImage() { if (environmentCase_ == 3) { return (com.google.cloud.notebooks.v1.ContainerImage) environment_; } return com.google.cloud.notebooks.v1.ContainerImage.getDefaultInstance(); } /** * * *
   * Use a container image to start the notebook instance.
   * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; */ @java.lang.Override public com.google.cloud.notebooks.v1.ContainerImageOrBuilder getContainerImageOrBuilder() { if (environmentCase_ == 3) { return (com.google.cloud.notebooks.v1.ContainerImage) environment_; } return com.google.cloud.notebooks.v1.ContainerImage.getDefaultInstance(); } public static final int POST_STARTUP_SCRIPT_FIELD_NUMBER = 4; @SuppressWarnings("serial") private volatile java.lang.Object postStartupScript_ = ""; /** * * *
   * Path to a Bash script that automatically runs after a notebook instance
   * fully boots up. The path must be a URL or
   * Cloud Storage path (`gs://path-to-file/file-name`).
   * 
* * string post_startup_script = 4; * * @return The postStartupScript. */ @java.lang.Override public java.lang.String getPostStartupScript() { java.lang.Object ref = postStartupScript_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); postStartupScript_ = s; return s; } } /** * * *
   * Path to a Bash script that automatically runs after a notebook instance
   * fully boots up. The path must be a URL or
   * Cloud Storage path (`gs://path-to-file/file-name`).
   * 
* * string post_startup_script = 4; * * @return The bytes for postStartupScript. */ @java.lang.Override public com.google.protobuf.ByteString getPostStartupScriptBytes() { java.lang.Object ref = postStartupScript_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); postStartupScript_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int PROXY_URI_FIELD_NUMBER = 5; @SuppressWarnings("serial") private volatile java.lang.Object proxyUri_ = ""; /** * * *
   * Output only. The proxy endpoint that is used to access the Jupyter notebook.
   * 
* * string proxy_uri = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The proxyUri. */ @java.lang.Override public java.lang.String getProxyUri() { java.lang.Object ref = proxyUri_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); proxyUri_ = s; return s; } } /** * * *
   * Output only. The proxy endpoint that is used to access the Jupyter notebook.
   * 
* * string proxy_uri = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for proxyUri. */ @java.lang.Override public com.google.protobuf.ByteString getProxyUriBytes() { java.lang.Object ref = proxyUri_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); proxyUri_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int INSTANCE_OWNERS_FIELD_NUMBER = 6; @SuppressWarnings("serial") private com.google.protobuf.LazyStringArrayList instanceOwners_ = com.google.protobuf.LazyStringArrayList.emptyList(); /** * * *
   * Input only. The owner of this instance after creation. Format: `alias@example.com`
   *
   * Currently supports one owner only. If not specified, all of the service
   * account users of your VM instance's service account can use
   * the instance.
   * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return A list containing the instanceOwners. */ public com.google.protobuf.ProtocolStringList getInstanceOwnersList() { return instanceOwners_; } /** * * *
   * Input only. The owner of this instance after creation. Format: `alias@example.com`
   *
   * Currently supports one owner only. If not specified, all of the service
   * account users of your VM instance's service account can use
   * the instance.
   * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The count of instanceOwners. */ public int getInstanceOwnersCount() { return instanceOwners_.size(); } /** * * *
   * Input only. The owner of this instance after creation. Format: `alias@example.com`
   *
   * Currently supports one owner only. If not specified, all of the service
   * account users of your VM instance's service account can use
   * the instance.
   * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param index The index of the element to return. * @return The instanceOwners at the given index. */ public java.lang.String getInstanceOwners(int index) { return instanceOwners_.get(index); } /** * * *
   * Input only. The owner of this instance after creation. Format: `alias@example.com`
   *
   * Currently supports one owner only. If not specified, all of the service
   * account users of your VM instance's service account can use
   * the instance.
   * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param index The index of the value to return. * @return The bytes of the instanceOwners at the given index. */ public com.google.protobuf.ByteString getInstanceOwnersBytes(int index) { return instanceOwners_.getByteString(index); } public static final int SERVICE_ACCOUNT_FIELD_NUMBER = 7; @SuppressWarnings("serial") private volatile java.lang.Object serviceAccount_ = ""; /** * * *
   * The service account on this instance, giving access to other Google
   * Cloud services.
   * You can use any service account within the same project, but you
   * must have the service account user permission to use the instance.
   *
   * If not specified, the [Compute Engine default service
   * account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account)
   * is used.
   * 
* * string service_account = 7; * * @return The serviceAccount. */ @java.lang.Override public java.lang.String getServiceAccount() { java.lang.Object ref = serviceAccount_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); serviceAccount_ = s; return s; } } /** * * *
   * The service account on this instance, giving access to other Google
   * Cloud services.
   * You can use any service account within the same project, but you
   * must have the service account user permission to use the instance.
   *
   * If not specified, the [Compute Engine default service
   * account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account)
   * is used.
   * 
* * string service_account = 7; * * @return The bytes for serviceAccount. */ @java.lang.Override public com.google.protobuf.ByteString getServiceAccountBytes() { java.lang.Object ref = serviceAccount_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); serviceAccount_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int SERVICE_ACCOUNT_SCOPES_FIELD_NUMBER = 31; @SuppressWarnings("serial") private com.google.protobuf.LazyStringArrayList serviceAccountScopes_ = com.google.protobuf.LazyStringArrayList.emptyList(); /** * * *
   * Optional. The URIs of service account scopes to be included in
   * Compute Engine instances.
   *
   * If not specified, the following
   * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
   * are defined:
   *  - https://www.googleapis.com/auth/cloud-platform
   *  - https://www.googleapis.com/auth/userinfo.email
   * If not using default scopes, you need at least:
   *    https://www.googleapis.com/auth/compute
   * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @return A list containing the serviceAccountScopes. */ public com.google.protobuf.ProtocolStringList getServiceAccountScopesList() { return serviceAccountScopes_; } /** * * *
   * Optional. The URIs of service account scopes to be included in
   * Compute Engine instances.
   *
   * If not specified, the following
   * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
   * are defined:
   *  - https://www.googleapis.com/auth/cloud-platform
   *  - https://www.googleapis.com/auth/userinfo.email
   * If not using default scopes, you need at least:
   *    https://www.googleapis.com/auth/compute
   * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The count of serviceAccountScopes. */ public int getServiceAccountScopesCount() { return serviceAccountScopes_.size(); } /** * * *
   * Optional. The URIs of service account scopes to be included in
   * Compute Engine instances.
   *
   * If not specified, the following
   * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
   * are defined:
   *  - https://www.googleapis.com/auth/cloud-platform
   *  - https://www.googleapis.com/auth/userinfo.email
   * If not using default scopes, you need at least:
   *    https://www.googleapis.com/auth/compute
   * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @param index The index of the element to return. * @return The serviceAccountScopes at the given index. */ public java.lang.String getServiceAccountScopes(int index) { return serviceAccountScopes_.get(index); } /** * * *
   * Optional. The URIs of service account scopes to be included in
   * Compute Engine instances.
   *
   * If not specified, the following
   * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
   * are defined:
   *  - https://www.googleapis.com/auth/cloud-platform
   *  - https://www.googleapis.com/auth/userinfo.email
   * If not using default scopes, you need at least:
   *    https://www.googleapis.com/auth/compute
   * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @param index The index of the value to return. * @return The bytes of the serviceAccountScopes at the given index. */ public com.google.protobuf.ByteString getServiceAccountScopesBytes(int index) { return serviceAccountScopes_.getByteString(index); } public static final int MACHINE_TYPE_FIELD_NUMBER = 8; @SuppressWarnings("serial") private volatile java.lang.Object machineType_ = ""; /** * * *
   * Required. The [Compute Engine machine
   * type](https://cloud.google.com/compute/docs/machine-types) of this
   * instance.
   * 
* * string machine_type = 8 [(.google.api.field_behavior) = REQUIRED]; * * @return The machineType. */ @java.lang.Override public java.lang.String getMachineType() { java.lang.Object ref = machineType_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); machineType_ = s; return s; } } /** * * *
   * Required. The [Compute Engine machine
   * type](https://cloud.google.com/compute/docs/machine-types) of this
   * instance.
   * 
* * string machine_type = 8 [(.google.api.field_behavior) = REQUIRED]; * * @return The bytes for machineType. */ @java.lang.Override public com.google.protobuf.ByteString getMachineTypeBytes() { java.lang.Object ref = machineType_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); machineType_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int ACCELERATOR_CONFIG_FIELD_NUMBER = 9; private com.google.cloud.notebooks.v1.Instance.AcceleratorConfig acceleratorConfig_; /** * * *
   * The hardware accelerator used on this instance. If you use
   * accelerators, make sure that your configuration has
   * [enough vCPUs and memory to support the `machine_type` you have
   * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
   * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; * * @return Whether the acceleratorConfig field is set. */ @java.lang.Override public boolean hasAcceleratorConfig() { return ((bitField0_ & 0x00000001) != 0); } /** * * *
   * The hardware accelerator used on this instance. If you use
   * accelerators, make sure that your configuration has
   * [enough vCPUs and memory to support the `machine_type` you have
   * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
   * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; * * @return The acceleratorConfig. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.AcceleratorConfig getAcceleratorConfig() { return acceleratorConfig_ == null ? com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.getDefaultInstance() : acceleratorConfig_; } /** * * *
   * The hardware accelerator used on this instance. If you use
   * accelerators, make sure that your configuration has
   * [enough vCPUs and memory to support the `machine_type` you have
   * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
   * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.AcceleratorConfigOrBuilder getAcceleratorConfigOrBuilder() { return acceleratorConfig_ == null ? com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.getDefaultInstance() : acceleratorConfig_; } public static final int STATE_FIELD_NUMBER = 10; private int state_ = 0; /** * * *
   * Output only. The state of this instance.
   * 
* * * .google.cloud.notebooks.v1.Instance.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The enum numeric value on the wire for state. */ @java.lang.Override public int getStateValue() { return state_; } /** * * *
   * Output only. The state of this instance.
   * 
* * * .google.cloud.notebooks.v1.Instance.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The state. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.State getState() { com.google.cloud.notebooks.v1.Instance.State result = com.google.cloud.notebooks.v1.Instance.State.forNumber(state_); return result == null ? com.google.cloud.notebooks.v1.Instance.State.UNRECOGNIZED : result; } public static final int INSTALL_GPU_DRIVER_FIELD_NUMBER = 11; private boolean installGpuDriver_ = false; /** * * *
   * Whether the end user authorizes Google Cloud to install GPU driver
   * on this instance.
   * If this field is empty or set to false, the GPU driver won't be installed.
   * Only applicable to instances with GPUs.
   * 
* * bool install_gpu_driver = 11; * * @return The installGpuDriver. */ @java.lang.Override public boolean getInstallGpuDriver() { return installGpuDriver_; } public static final int CUSTOM_GPU_DRIVER_PATH_FIELD_NUMBER = 12; @SuppressWarnings("serial") private volatile java.lang.Object customGpuDriverPath_ = ""; /** * * *
   * Specify a custom Cloud Storage path where the GPU driver is stored.
   * If not specified, we'll automatically choose from official GPU drivers.
   * 
* * string custom_gpu_driver_path = 12; * * @return The customGpuDriverPath. */ @java.lang.Override public java.lang.String getCustomGpuDriverPath() { java.lang.Object ref = customGpuDriverPath_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); customGpuDriverPath_ = s; return s; } } /** * * *
   * Specify a custom Cloud Storage path where the GPU driver is stored.
   * If not specified, we'll automatically choose from official GPU drivers.
   * 
* * string custom_gpu_driver_path = 12; * * @return The bytes for customGpuDriverPath. */ @java.lang.Override public com.google.protobuf.ByteString getCustomGpuDriverPathBytes() { java.lang.Object ref = customGpuDriverPath_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); customGpuDriverPath_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int BOOT_DISK_TYPE_FIELD_NUMBER = 13; private int bootDiskType_ = 0; /** * * *
   * Input only. The type of the boot disk attached to this instance, defaults to
   * standard persistent disk (`PD_STANDARD`).
   * 
* * * .google.cloud.notebooks.v1.Instance.DiskType boot_disk_type = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The enum numeric value on the wire for bootDiskType. */ @java.lang.Override public int getBootDiskTypeValue() { return bootDiskType_; } /** * * *
   * Input only. The type of the boot disk attached to this instance, defaults to
   * standard persistent disk (`PD_STANDARD`).
   * 
* * * .google.cloud.notebooks.v1.Instance.DiskType boot_disk_type = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The bootDiskType. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.DiskType getBootDiskType() { com.google.cloud.notebooks.v1.Instance.DiskType result = com.google.cloud.notebooks.v1.Instance.DiskType.forNumber(bootDiskType_); return result == null ? com.google.cloud.notebooks.v1.Instance.DiskType.UNRECOGNIZED : result; } public static final int BOOT_DISK_SIZE_GB_FIELD_NUMBER = 14; private long bootDiskSizeGb_ = 0L; /** * * *
   * Input only. The size of the boot disk in GB attached to this instance, up to a maximum
   * of 64000 GB (64 TB). The minimum recommended value is 100 GB. If not
   * specified, this defaults to 100.
   * 
* * int64 boot_disk_size_gb = 14 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The bootDiskSizeGb. */ @java.lang.Override public long getBootDiskSizeGb() { return bootDiskSizeGb_; } public static final int DATA_DISK_TYPE_FIELD_NUMBER = 25; private int dataDiskType_ = 0; /** * * *
   * Input only. The type of the data disk attached to this instance, defaults to
   * standard persistent disk (`PD_STANDARD`).
   * 
* * * .google.cloud.notebooks.v1.Instance.DiskType data_disk_type = 25 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The enum numeric value on the wire for dataDiskType. */ @java.lang.Override public int getDataDiskTypeValue() { return dataDiskType_; } /** * * *
   * Input only. The type of the data disk attached to this instance, defaults to
   * standard persistent disk (`PD_STANDARD`).
   * 
* * * .google.cloud.notebooks.v1.Instance.DiskType data_disk_type = 25 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The dataDiskType. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.DiskType getDataDiskType() { com.google.cloud.notebooks.v1.Instance.DiskType result = com.google.cloud.notebooks.v1.Instance.DiskType.forNumber(dataDiskType_); return result == null ? com.google.cloud.notebooks.v1.Instance.DiskType.UNRECOGNIZED : result; } public static final int DATA_DISK_SIZE_GB_FIELD_NUMBER = 26; private long dataDiskSizeGb_ = 0L; /** * * *
   * Input only. The size of the data disk in GB attached to this instance, up to a maximum
   * of 64000 GB (64 TB). You can choose the size of the data disk based on how
   * big your notebooks and data are. If not specified, this defaults to 100.
   * 
* * int64 data_disk_size_gb = 26 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The dataDiskSizeGb. */ @java.lang.Override public long getDataDiskSizeGb() { return dataDiskSizeGb_; } public static final int NO_REMOVE_DATA_DISK_FIELD_NUMBER = 27; private boolean noRemoveDataDisk_ = false; /** * * *
   * Input only. If true, the data disk will not be auto deleted when deleting the instance.
   * 
* * bool no_remove_data_disk = 27 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The noRemoveDataDisk. */ @java.lang.Override public boolean getNoRemoveDataDisk() { return noRemoveDataDisk_; } public static final int DISK_ENCRYPTION_FIELD_NUMBER = 15; private int diskEncryption_ = 0; /** * * *
   * Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
   * 
* * * .google.cloud.notebooks.v1.Instance.DiskEncryption disk_encryption = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The enum numeric value on the wire for diskEncryption. */ @java.lang.Override public int getDiskEncryptionValue() { return diskEncryption_; } /** * * *
   * Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
   * 
* * * .google.cloud.notebooks.v1.Instance.DiskEncryption disk_encryption = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The diskEncryption. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.DiskEncryption getDiskEncryption() { com.google.cloud.notebooks.v1.Instance.DiskEncryption result = com.google.cloud.notebooks.v1.Instance.DiskEncryption.forNumber(diskEncryption_); return result == null ? com.google.cloud.notebooks.v1.Instance.DiskEncryption.UNRECOGNIZED : result; } public static final int KMS_KEY_FIELD_NUMBER = 16; @SuppressWarnings("serial") private volatile java.lang.Object kmsKey_ = ""; /** * * *
   * Input only. The KMS key used to encrypt the disks, only applicable if disk_encryption
   * is CMEK.
   * Format:
   * `projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}`
   *
   * Learn more about [using your own encryption keys](/kms/docs/quickstart).
   * 
* * string kms_key = 16 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The kmsKey. */ @java.lang.Override public java.lang.String getKmsKey() { java.lang.Object ref = kmsKey_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); kmsKey_ = s; return s; } } /** * * *
   * Input only. The KMS key used to encrypt the disks, only applicable if disk_encryption
   * is CMEK.
   * Format:
   * `projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}`
   *
   * Learn more about [using your own encryption keys](/kms/docs/quickstart).
   * 
* * string kms_key = 16 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The bytes for kmsKey. */ @java.lang.Override public com.google.protobuf.ByteString getKmsKeyBytes() { java.lang.Object ref = kmsKey_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); kmsKey_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int DISKS_FIELD_NUMBER = 28; @SuppressWarnings("serial") private java.util.List disks_; /** * * *
   * Output only. Attached disks to notebook instance.
   * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public java.util.List getDisksList() { return disks_; } /** * * *
   * Output only. Attached disks to notebook instance.
   * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public java.util.List getDisksOrBuilderList() { return disks_; } /** * * *
   * Output only. Attached disks to notebook instance.
   * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public int getDisksCount() { return disks_.size(); } /** * * *
   * Output only. Attached disks to notebook instance.
   * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.Disk getDisks(int index) { return disks_.get(index); } /** * * *
   * Output only. Attached disks to notebook instance.
   * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.DiskOrBuilder getDisksOrBuilder(int index) { return disks_.get(index); } public static final int SHIELDED_INSTANCE_CONFIG_FIELD_NUMBER = 30; private com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shieldedInstanceConfig_; /** * * *
   * Optional. Shielded VM configuration.
   * [Images using supported Shielded VM
   * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
   * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * * * @return Whether the shieldedInstanceConfig field is set. */ @java.lang.Override public boolean hasShieldedInstanceConfig() { return ((bitField0_ & 0x00000002) != 0); } /** * * *
   * Optional. Shielded VM configuration.
   * [Images using supported Shielded VM
   * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
   * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The shieldedInstanceConfig. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig getShieldedInstanceConfig() { return shieldedInstanceConfig_ == null ? com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.getDefaultInstance() : shieldedInstanceConfig_; } /** * * *
   * Optional. Shielded VM configuration.
   * [Images using supported Shielded VM
   * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
   * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfigOrBuilder getShieldedInstanceConfigOrBuilder() { return shieldedInstanceConfig_ == null ? com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.getDefaultInstance() : shieldedInstanceConfig_; } public static final int NO_PUBLIC_IP_FIELD_NUMBER = 17; private boolean noPublicIp_ = false; /** * * *
   * If true, no public IP will be assigned to this instance.
   * 
* * bool no_public_ip = 17; * * @return The noPublicIp. */ @java.lang.Override public boolean getNoPublicIp() { return noPublicIp_; } public static final int NO_PROXY_ACCESS_FIELD_NUMBER = 18; private boolean noProxyAccess_ = false; /** * * *
   * If true, the notebook instance will not register with the proxy.
   * 
* * bool no_proxy_access = 18; * * @return The noProxyAccess. */ @java.lang.Override public boolean getNoProxyAccess() { return noProxyAccess_; } public static final int NETWORK_FIELD_NUMBER = 19; @SuppressWarnings("serial") private volatile java.lang.Object network_ = ""; /** * * *
   * The name of the VPC that this instance is in.
   * Format:
   * `projects/{project_id}/global/networks/{network_id}`
   * 
* * string network = 19; * * @return The network. */ @java.lang.Override public java.lang.String getNetwork() { java.lang.Object ref = network_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); network_ = s; return s; } } /** * * *
   * The name of the VPC that this instance is in.
   * Format:
   * `projects/{project_id}/global/networks/{network_id}`
   * 
* * string network = 19; * * @return The bytes for network. */ @java.lang.Override public com.google.protobuf.ByteString getNetworkBytes() { java.lang.Object ref = network_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); network_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int SUBNET_FIELD_NUMBER = 20; @SuppressWarnings("serial") private volatile java.lang.Object subnet_ = ""; /** * * *
   * The name of the subnet that this instance is in.
   * Format:
   * `projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}`
   * 
* * string subnet = 20; * * @return The subnet. */ @java.lang.Override public java.lang.String getSubnet() { java.lang.Object ref = subnet_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); subnet_ = s; return s; } } /** * * *
   * The name of the subnet that this instance is in.
   * Format:
   * `projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}`
   * 
* * string subnet = 20; * * @return The bytes for subnet. */ @java.lang.Override public com.google.protobuf.ByteString getSubnetBytes() { java.lang.Object ref = subnet_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); subnet_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int LABELS_FIELD_NUMBER = 21; private static final class LabelsDefaultEntryHolder { static final com.google.protobuf.MapEntry defaultEntry = com.google.protobuf.MapEntry.newDefaultInstance( com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_LabelsEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.STRING, ""); } @SuppressWarnings("serial") private com.google.protobuf.MapField labels_; private com.google.protobuf.MapField internalGetLabels() { if (labels_ == null) { return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); } return labels_; } public int getLabelsCount() { return internalGetLabels().getMap().size(); } /** * * *
   * Labels to apply to this instance.
   * These can be later modified by the setLabels method.
   * 
* * map<string, string> labels = 21; */ @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); } /** * * *
   * Labels to apply to this instance.
   * These can be later modified by the setLabels method.
   * 
* * map<string, string> labels = 21; */ @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } /** * * *
   * Labels to apply to this instance.
   * These can be later modified by the setLabels method.
   * 
* * map<string, string> labels = 21; */ @java.lang.Override public /* nullable */ java.lang.String getLabelsOrDefault( java.lang.String key, /* nullable */ java.lang.String defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetLabels().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** * * *
   * Labels to apply to this instance.
   * These can be later modified by the setLabels method.
   * 
* * map<string, string> labels = 21; */ @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetLabels().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public static final int METADATA_FIELD_NUMBER = 22; private static final class MetadataDefaultEntryHolder { static final com.google.protobuf.MapEntry defaultEntry = com.google.protobuf.MapEntry.newDefaultInstance( com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_MetadataEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.STRING, ""); } @SuppressWarnings("serial") private com.google.protobuf.MapField metadata_; private com.google.protobuf.MapField internalGetMetadata() { if (metadata_ == null) { return com.google.protobuf.MapField.emptyMapField(MetadataDefaultEntryHolder.defaultEntry); } return metadata_; } public int getMetadataCount() { return internalGetMetadata().getMap().size(); } /** * * *
   * Custom metadata to apply to this instance.
   * 
* * map<string, string> metadata = 22; */ @java.lang.Override public boolean containsMetadata(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetMetadata().getMap().containsKey(key); } /** Use {@link #getMetadataMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getMetadata() { return getMetadataMap(); } /** * * *
   * Custom metadata to apply to this instance.
   * 
* * map<string, string> metadata = 22; */ @java.lang.Override public java.util.Map getMetadataMap() { return internalGetMetadata().getMap(); } /** * * *
   * Custom metadata to apply to this instance.
   * 
* * map<string, string> metadata = 22; */ @java.lang.Override public /* nullable */ java.lang.String getMetadataOrDefault( java.lang.String key, /* nullable */ java.lang.String defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetMetadata().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** * * *
   * Custom metadata to apply to this instance.
   * 
* * map<string, string> metadata = 22; */ @java.lang.Override public java.lang.String getMetadataOrThrow(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetMetadata().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public static final int TAGS_FIELD_NUMBER = 32; @SuppressWarnings("serial") private com.google.protobuf.LazyStringArrayList tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); /** * * *
   * Optional. The Compute Engine tags to add to runtime (see [Tagging
   * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
   * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @return A list containing the tags. */ public com.google.protobuf.ProtocolStringList getTagsList() { return tags_; } /** * * *
   * Optional. The Compute Engine tags to add to runtime (see [Tagging
   * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
   * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @return The count of tags. */ public int getTagsCount() { return tags_.size(); } /** * * *
   * Optional. The Compute Engine tags to add to runtime (see [Tagging
   * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
   * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @param index The index of the element to return. * @return The tags at the given index. */ public java.lang.String getTags(int index) { return tags_.get(index); } /** * * *
   * Optional. The Compute Engine tags to add to runtime (see [Tagging
   * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
   * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @param index The index of the value to return. * @return The bytes of the tags at the given index. */ public com.google.protobuf.ByteString getTagsBytes(int index) { return tags_.getByteString(index); } public static final int UPGRADE_HISTORY_FIELD_NUMBER = 29; @SuppressWarnings("serial") private java.util.List upgradeHistory_; /** * * *
   * The upgrade history of this instance.
   * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ @java.lang.Override public java.util.List getUpgradeHistoryList() { return upgradeHistory_; } /** * * *
   * The upgrade history of this instance.
   * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ @java.lang.Override public java.util.List< ? extends com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntryOrBuilder> getUpgradeHistoryOrBuilderList() { return upgradeHistory_; } /** * * *
   * The upgrade history of this instance.
   * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ @java.lang.Override public int getUpgradeHistoryCount() { return upgradeHistory_.size(); } /** * * *
   * The upgrade history of this instance.
   * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry getUpgradeHistory(int index) { return upgradeHistory_.get(index); } /** * * *
   * The upgrade history of this instance.
   * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntryOrBuilder getUpgradeHistoryOrBuilder(int index) { return upgradeHistory_.get(index); } public static final int NIC_TYPE_FIELD_NUMBER = 33; private int nicType_ = 0; /** * * *
   * Optional. The type of vNIC to be used on this interface. This may be gVNIC or
   * VirtioNet.
   * 
* * * .google.cloud.notebooks.v1.Instance.NicType nic_type = 33 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The enum numeric value on the wire for nicType. */ @java.lang.Override public int getNicTypeValue() { return nicType_; } /** * * *
   * Optional. The type of vNIC to be used on this interface. This may be gVNIC or
   * VirtioNet.
   * 
* * * .google.cloud.notebooks.v1.Instance.NicType nic_type = 33 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The nicType. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.NicType getNicType() { com.google.cloud.notebooks.v1.Instance.NicType result = com.google.cloud.notebooks.v1.Instance.NicType.forNumber(nicType_); return result == null ? com.google.cloud.notebooks.v1.Instance.NicType.UNRECOGNIZED : result; } public static final int RESERVATION_AFFINITY_FIELD_NUMBER = 34; private com.google.cloud.notebooks.v1.ReservationAffinity reservationAffinity_; /** * * *
   * Optional. The optional reservation affinity. Setting this field will apply
   * the specified [Zonal Compute
   * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
   * to this notebook instance.
   * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * * * @return Whether the reservationAffinity field is set. */ @java.lang.Override public boolean hasReservationAffinity() { return ((bitField0_ & 0x00000004) != 0); } /** * * *
   * Optional. The optional reservation affinity. Setting this field will apply
   * the specified [Zonal Compute
   * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
   * to this notebook instance.
   * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The reservationAffinity. */ @java.lang.Override public com.google.cloud.notebooks.v1.ReservationAffinity getReservationAffinity() { return reservationAffinity_ == null ? com.google.cloud.notebooks.v1.ReservationAffinity.getDefaultInstance() : reservationAffinity_; } /** * * *
   * Optional. The optional reservation affinity. Setting this field will apply
   * the specified [Zonal Compute
   * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
   * to this notebook instance.
   * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * */ @java.lang.Override public com.google.cloud.notebooks.v1.ReservationAffinityOrBuilder getReservationAffinityOrBuilder() { return reservationAffinity_ == null ? com.google.cloud.notebooks.v1.ReservationAffinity.getDefaultInstance() : reservationAffinity_; } public static final int CREATOR_FIELD_NUMBER = 36; @SuppressWarnings("serial") private volatile java.lang.Object creator_ = ""; /** * * *
   * Output only. Email address of entity that sent original CreateInstance request.
   * 
* * string creator = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The creator. */ @java.lang.Override public java.lang.String getCreator() { java.lang.Object ref = creator_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); creator_ = s; return s; } } /** * * *
   * Output only. Email address of entity that sent original CreateInstance request.
   * 
* * string creator = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for creator. */ @java.lang.Override public com.google.protobuf.ByteString getCreatorBytes() { java.lang.Object ref = creator_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); creator_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int CAN_IP_FORWARD_FIELD_NUMBER = 39; private boolean canIpForward_ = false; /** * * *
   * Optional. Flag to enable ip forwarding or not, default false/off.
   * https://cloud.google.com/vpc/docs/using-routes#canipforward
   * 
* * bool can_ip_forward = 39 [(.google.api.field_behavior) = OPTIONAL]; * * @return The canIpForward. */ @java.lang.Override public boolean getCanIpForward() { return canIpForward_; } public static final int CREATE_TIME_FIELD_NUMBER = 23; private com.google.protobuf.Timestamp createTime_; /** * * *
   * Output only. Instance creation time.
   * 
* * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the createTime field is set. */ @java.lang.Override public boolean hasCreateTime() { return ((bitField0_ & 0x00000008) != 0); } /** * * *
   * Output only. Instance creation time.
   * 
* * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The createTime. */ @java.lang.Override public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } /** * * *
   * Output only. Instance creation time.
   * 
* * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } public static final int UPDATE_TIME_FIELD_NUMBER = 24; private com.google.protobuf.Timestamp updateTime_; /** * * *
   * Output only. Instance update time.
   * 
* * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the updateTime field is set. */ @java.lang.Override public boolean hasUpdateTime() { return ((bitField0_ & 0x00000010) != 0); } /** * * *
   * Output only. Instance update time.
   * 
* * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The updateTime. */ @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } /** * * *
   * Output only. Instance update time.
   * 
* * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } if (environmentCase_ == 2) { output.writeMessage(2, (com.google.cloud.notebooks.v1.VmImage) environment_); } if (environmentCase_ == 3) { output.writeMessage(3, (com.google.cloud.notebooks.v1.ContainerImage) environment_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(postStartupScript_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, postStartupScript_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(proxyUri_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 5, proxyUri_); } for (int i = 0; i < instanceOwners_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 6, instanceOwners_.getRaw(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 7, serviceAccount_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(machineType_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 8, machineType_); } if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(9, getAcceleratorConfig()); } if (state_ != com.google.cloud.notebooks.v1.Instance.State.STATE_UNSPECIFIED.getNumber()) { output.writeEnum(10, state_); } if (installGpuDriver_ != false) { output.writeBool(11, installGpuDriver_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(customGpuDriverPath_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 12, customGpuDriverPath_); } if (bootDiskType_ != com.google.cloud.notebooks.v1.Instance.DiskType.DISK_TYPE_UNSPECIFIED.getNumber()) { output.writeEnum(13, bootDiskType_); } if (bootDiskSizeGb_ != 0L) { output.writeInt64(14, bootDiskSizeGb_); } if (diskEncryption_ != com.google.cloud.notebooks.v1.Instance.DiskEncryption.DISK_ENCRYPTION_UNSPECIFIED .getNumber()) { output.writeEnum(15, diskEncryption_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKey_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 16, kmsKey_); } if (noPublicIp_ != false) { output.writeBool(17, noPublicIp_); } if (noProxyAccess_ != false) { output.writeBool(18, noProxyAccess_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(network_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 19, network_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subnet_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 20, subnet_); } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 21); com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetMetadata(), MetadataDefaultEntryHolder.defaultEntry, 22); if (((bitField0_ & 0x00000008) != 0)) { output.writeMessage(23, getCreateTime()); } if (((bitField0_ & 0x00000010) != 0)) { output.writeMessage(24, getUpdateTime()); } if (dataDiskType_ != com.google.cloud.notebooks.v1.Instance.DiskType.DISK_TYPE_UNSPECIFIED.getNumber()) { output.writeEnum(25, dataDiskType_); } if (dataDiskSizeGb_ != 0L) { output.writeInt64(26, dataDiskSizeGb_); } if (noRemoveDataDisk_ != false) { output.writeBool(27, noRemoveDataDisk_); } for (int i = 0; i < disks_.size(); i++) { output.writeMessage(28, disks_.get(i)); } for (int i = 0; i < upgradeHistory_.size(); i++) { output.writeMessage(29, upgradeHistory_.get(i)); } if (((bitField0_ & 0x00000002) != 0)) { output.writeMessage(30, getShieldedInstanceConfig()); } for (int i = 0; i < serviceAccountScopes_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString( output, 31, serviceAccountScopes_.getRaw(i)); } for (int i = 0; i < tags_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 32, tags_.getRaw(i)); } if (nicType_ != com.google.cloud.notebooks.v1.Instance.NicType.UNSPECIFIED_NIC_TYPE.getNumber()) { output.writeEnum(33, nicType_); } if (((bitField0_ & 0x00000004) != 0)) { output.writeMessage(34, getReservationAffinity()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(creator_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 36, creator_); } if (canIpForward_ != false) { output.writeBool(39, canIpForward_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } if (environmentCase_ == 2) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( 2, (com.google.cloud.notebooks.v1.VmImage) environment_); } if (environmentCase_ == 3) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( 3, (com.google.cloud.notebooks.v1.ContainerImage) environment_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(postStartupScript_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, postStartupScript_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(proxyUri_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, proxyUri_); } { int dataSize = 0; for (int i = 0; i < instanceOwners_.size(); i++) { dataSize += computeStringSizeNoTag(instanceOwners_.getRaw(i)); } size += dataSize; size += 1 * getInstanceOwnersList().size(); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, serviceAccount_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(machineType_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, machineType_); } if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getAcceleratorConfig()); } if (state_ != com.google.cloud.notebooks.v1.Instance.State.STATE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(10, state_); } if (installGpuDriver_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(11, installGpuDriver_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(customGpuDriverPath_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(12, customGpuDriverPath_); } if (bootDiskType_ != com.google.cloud.notebooks.v1.Instance.DiskType.DISK_TYPE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(13, bootDiskType_); } if (bootDiskSizeGb_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(14, bootDiskSizeGb_); } if (diskEncryption_ != com.google.cloud.notebooks.v1.Instance.DiskEncryption.DISK_ENCRYPTION_UNSPECIFIED .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(15, diskEncryption_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKey_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(16, kmsKey_); } if (noPublicIp_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(17, noPublicIp_); } if (noProxyAccess_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(18, noProxyAccess_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(network_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(19, network_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subnet_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(20, subnet_); } for (java.util.Map.Entry entry : internalGetLabels().getMap().entrySet()) { com.google.protobuf.MapEntry labels__ = LabelsDefaultEntryHolder.defaultEntry .newBuilderForType() .setKey(entry.getKey()) .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(21, labels__); } for (java.util.Map.Entry entry : internalGetMetadata().getMap().entrySet()) { com.google.protobuf.MapEntry metadata__ = MetadataDefaultEntryHolder.defaultEntry .newBuilderForType() .setKey(entry.getKey()) .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(22, metadata__); } if (((bitField0_ & 0x00000008) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(23, getCreateTime()); } if (((bitField0_ & 0x00000010) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(24, getUpdateTime()); } if (dataDiskType_ != com.google.cloud.notebooks.v1.Instance.DiskType.DISK_TYPE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(25, dataDiskType_); } if (dataDiskSizeGb_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(26, dataDiskSizeGb_); } if (noRemoveDataDisk_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(27, noRemoveDataDisk_); } for (int i = 0; i < disks_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(28, disks_.get(i)); } for (int i = 0; i < upgradeHistory_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(29, upgradeHistory_.get(i)); } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(30, getShieldedInstanceConfig()); } { int dataSize = 0; for (int i = 0; i < serviceAccountScopes_.size(); i++) { dataSize += computeStringSizeNoTag(serviceAccountScopes_.getRaw(i)); } size += dataSize; size += 2 * getServiceAccountScopesList().size(); } { int dataSize = 0; for (int i = 0; i < tags_.size(); i++) { dataSize += computeStringSizeNoTag(tags_.getRaw(i)); } size += dataSize; size += 2 * getTagsList().size(); } if (nicType_ != com.google.cloud.notebooks.v1.Instance.NicType.UNSPECIFIED_NIC_TYPE.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(33, nicType_); } if (((bitField0_ & 0x00000004) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(34, getReservationAffinity()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(creator_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(36, creator_); } if (canIpForward_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(39, canIpForward_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.notebooks.v1.Instance)) { return super.equals(obj); } com.google.cloud.notebooks.v1.Instance other = (com.google.cloud.notebooks.v1.Instance) obj; if (!getName().equals(other.getName())) return false; if (!getPostStartupScript().equals(other.getPostStartupScript())) return false; if (!getProxyUri().equals(other.getProxyUri())) return false; if (!getInstanceOwnersList().equals(other.getInstanceOwnersList())) return false; if (!getServiceAccount().equals(other.getServiceAccount())) return false; if (!getServiceAccountScopesList().equals(other.getServiceAccountScopesList())) return false; if (!getMachineType().equals(other.getMachineType())) return false; if (hasAcceleratorConfig() != other.hasAcceleratorConfig()) return false; if (hasAcceleratorConfig()) { if (!getAcceleratorConfig().equals(other.getAcceleratorConfig())) return false; } if (state_ != other.state_) return false; if (getInstallGpuDriver() != other.getInstallGpuDriver()) return false; if (!getCustomGpuDriverPath().equals(other.getCustomGpuDriverPath())) return false; if (bootDiskType_ != other.bootDiskType_) return false; if (getBootDiskSizeGb() != other.getBootDiskSizeGb()) return false; if (dataDiskType_ != other.dataDiskType_) return false; if (getDataDiskSizeGb() != other.getDataDiskSizeGb()) return false; if (getNoRemoveDataDisk() != other.getNoRemoveDataDisk()) return false; if (diskEncryption_ != other.diskEncryption_) return false; if (!getKmsKey().equals(other.getKmsKey())) return false; if (!getDisksList().equals(other.getDisksList())) return false; if (hasShieldedInstanceConfig() != other.hasShieldedInstanceConfig()) return false; if (hasShieldedInstanceConfig()) { if (!getShieldedInstanceConfig().equals(other.getShieldedInstanceConfig())) return false; } if (getNoPublicIp() != other.getNoPublicIp()) return false; if (getNoProxyAccess() != other.getNoProxyAccess()) return false; if (!getNetwork().equals(other.getNetwork())) return false; if (!getSubnet().equals(other.getSubnet())) return false; if (!internalGetLabels().equals(other.internalGetLabels())) return false; if (!internalGetMetadata().equals(other.internalGetMetadata())) return false; if (!getTagsList().equals(other.getTagsList())) return false; if (!getUpgradeHistoryList().equals(other.getUpgradeHistoryList())) return false; if (nicType_ != other.nicType_) return false; if (hasReservationAffinity() != other.hasReservationAffinity()) return false; if (hasReservationAffinity()) { if (!getReservationAffinity().equals(other.getReservationAffinity())) return false; } if (!getCreator().equals(other.getCreator())) return false; if (getCanIpForward() != other.getCanIpForward()) return false; if (hasCreateTime() != other.hasCreateTime()) return false; if (hasCreateTime()) { if (!getCreateTime().equals(other.getCreateTime())) return false; } if (hasUpdateTime() != other.hasUpdateTime()) return false; if (hasUpdateTime()) { if (!getUpdateTime().equals(other.getUpdateTime())) return false; } if (!getEnvironmentCase().equals(other.getEnvironmentCase())) return false; switch (environmentCase_) { case 2: if (!getVmImage().equals(other.getVmImage())) return false; break; case 3: if (!getContainerImage().equals(other.getContainerImage())) return false; break; case 0: default: } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + POST_STARTUP_SCRIPT_FIELD_NUMBER; hash = (53 * hash) + getPostStartupScript().hashCode(); hash = (37 * hash) + PROXY_URI_FIELD_NUMBER; hash = (53 * hash) + getProxyUri().hashCode(); if (getInstanceOwnersCount() > 0) { hash = (37 * hash) + INSTANCE_OWNERS_FIELD_NUMBER; hash = (53 * hash) + getInstanceOwnersList().hashCode(); } hash = (37 * hash) + SERVICE_ACCOUNT_FIELD_NUMBER; hash = (53 * hash) + getServiceAccount().hashCode(); if (getServiceAccountScopesCount() > 0) { hash = (37 * hash) + SERVICE_ACCOUNT_SCOPES_FIELD_NUMBER; hash = (53 * hash) + getServiceAccountScopesList().hashCode(); } hash = (37 * hash) + MACHINE_TYPE_FIELD_NUMBER; hash = (53 * hash) + getMachineType().hashCode(); if (hasAcceleratorConfig()) { hash = (37 * hash) + ACCELERATOR_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getAcceleratorConfig().hashCode(); } hash = (37 * hash) + STATE_FIELD_NUMBER; hash = (53 * hash) + state_; hash = (37 * hash) + INSTALL_GPU_DRIVER_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getInstallGpuDriver()); hash = (37 * hash) + CUSTOM_GPU_DRIVER_PATH_FIELD_NUMBER; hash = (53 * hash) + getCustomGpuDriverPath().hashCode(); hash = (37 * hash) + BOOT_DISK_TYPE_FIELD_NUMBER; hash = (53 * hash) + bootDiskType_; hash = (37 * hash) + BOOT_DISK_SIZE_GB_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getBootDiskSizeGb()); hash = (37 * hash) + DATA_DISK_TYPE_FIELD_NUMBER; hash = (53 * hash) + dataDiskType_; hash = (37 * hash) + DATA_DISK_SIZE_GB_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getDataDiskSizeGb()); hash = (37 * hash) + NO_REMOVE_DATA_DISK_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getNoRemoveDataDisk()); hash = (37 * hash) + DISK_ENCRYPTION_FIELD_NUMBER; hash = (53 * hash) + diskEncryption_; hash = (37 * hash) + KMS_KEY_FIELD_NUMBER; hash = (53 * hash) + getKmsKey().hashCode(); if (getDisksCount() > 0) { hash = (37 * hash) + DISKS_FIELD_NUMBER; hash = (53 * hash) + getDisksList().hashCode(); } if (hasShieldedInstanceConfig()) { hash = (37 * hash) + SHIELDED_INSTANCE_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getShieldedInstanceConfig().hashCode(); } hash = (37 * hash) + NO_PUBLIC_IP_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getNoPublicIp()); hash = (37 * hash) + NO_PROXY_ACCESS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getNoProxyAccess()); hash = (37 * hash) + NETWORK_FIELD_NUMBER; hash = (53 * hash) + getNetwork().hashCode(); hash = (37 * hash) + SUBNET_FIELD_NUMBER; hash = (53 * hash) + getSubnet().hashCode(); if (!internalGetLabels().getMap().isEmpty()) { hash = (37 * hash) + LABELS_FIELD_NUMBER; hash = (53 * hash) + internalGetLabels().hashCode(); } if (!internalGetMetadata().getMap().isEmpty()) { hash = (37 * hash) + METADATA_FIELD_NUMBER; hash = (53 * hash) + internalGetMetadata().hashCode(); } if (getTagsCount() > 0) { hash = (37 * hash) + TAGS_FIELD_NUMBER; hash = (53 * hash) + getTagsList().hashCode(); } if (getUpgradeHistoryCount() > 0) { hash = (37 * hash) + UPGRADE_HISTORY_FIELD_NUMBER; hash = (53 * hash) + getUpgradeHistoryList().hashCode(); } hash = (37 * hash) + NIC_TYPE_FIELD_NUMBER; hash = (53 * hash) + nicType_; if (hasReservationAffinity()) { hash = (37 * hash) + RESERVATION_AFFINITY_FIELD_NUMBER; hash = (53 * hash) + getReservationAffinity().hashCode(); } hash = (37 * hash) + CREATOR_FIELD_NUMBER; hash = (53 * hash) + getCreator().hashCode(); hash = (37 * hash) + CAN_IP_FORWARD_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getCanIpForward()); if (hasCreateTime()) { hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; hash = (53 * hash) + getCreateTime().hashCode(); } if (hasUpdateTime()) { hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; hash = (53 * hash) + getUpdateTime().hashCode(); } switch (environmentCase_) { case 2: hash = (37 * hash) + VM_IMAGE_FIELD_NUMBER; hash = (53 * hash) + getVmImage().hashCode(); break; case 3: hash = (37 * hash) + CONTAINER_IMAGE_FIELD_NUMBER; hash = (53 * hash) + getContainerImage().hashCode(); break; case 0: default: } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.notebooks.v1.Instance parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.notebooks.v1.Instance parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.notebooks.v1.Instance parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.notebooks.v1.Instance parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(com.google.cloud.notebooks.v1.Instance prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
   * The definition of a notebook instance.
   * 
* * Protobuf type {@code google.cloud.notebooks.v1.Instance} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.notebooks.v1.Instance) com.google.cloud.notebooks.v1.InstanceOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_descriptor; } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( int number) { switch (number) { case 21: return internalGetLabels(); case 22: return internalGetMetadata(); default: throw new RuntimeException("Invalid map field number: " + number); } } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( int number) { switch (number) { case 21: return internalGetMutableLabels(); case 22: return internalGetMutableMetadata(); default: throw new RuntimeException("Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.notebooks.v1.Instance.class, com.google.cloud.notebooks.v1.Instance.Builder.class); } // Construct using com.google.cloud.notebooks.v1.Instance.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getAcceleratorConfigFieldBuilder(); getDisksFieldBuilder(); getShieldedInstanceConfigFieldBuilder(); getUpgradeHistoryFieldBuilder(); getReservationAffinityFieldBuilder(); getCreateTimeFieldBuilder(); getUpdateTimeFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; bitField1_ = 0; name_ = ""; if (vmImageBuilder_ != null) { vmImageBuilder_.clear(); } if (containerImageBuilder_ != null) { containerImageBuilder_.clear(); } postStartupScript_ = ""; proxyUri_ = ""; instanceOwners_ = com.google.protobuf.LazyStringArrayList.emptyList(); serviceAccount_ = ""; serviceAccountScopes_ = com.google.protobuf.LazyStringArrayList.emptyList(); machineType_ = ""; acceleratorConfig_ = null; if (acceleratorConfigBuilder_ != null) { acceleratorConfigBuilder_.dispose(); acceleratorConfigBuilder_ = null; } state_ = 0; installGpuDriver_ = false; customGpuDriverPath_ = ""; bootDiskType_ = 0; bootDiskSizeGb_ = 0L; dataDiskType_ = 0; dataDiskSizeGb_ = 0L; noRemoveDataDisk_ = false; diskEncryption_ = 0; kmsKey_ = ""; if (disksBuilder_ == null) { disks_ = java.util.Collections.emptyList(); } else { disks_ = null; disksBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00100000); shieldedInstanceConfig_ = null; if (shieldedInstanceConfigBuilder_ != null) { shieldedInstanceConfigBuilder_.dispose(); shieldedInstanceConfigBuilder_ = null; } noPublicIp_ = false; noProxyAccess_ = false; network_ = ""; subnet_ = ""; internalGetMutableLabels().clear(); internalGetMutableMetadata().clear(); tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); if (upgradeHistoryBuilder_ == null) { upgradeHistory_ = java.util.Collections.emptyList(); } else { upgradeHistory_ = null; upgradeHistoryBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x20000000); nicType_ = 0; reservationAffinity_ = null; if (reservationAffinityBuilder_ != null) { reservationAffinityBuilder_.dispose(); reservationAffinityBuilder_ = null; } creator_ = ""; canIpForward_ = false; createTime_ = null; if (createTimeBuilder_ != null) { createTimeBuilder_.dispose(); createTimeBuilder_ = null; } updateTime_ = null; if (updateTimeBuilder_ != null) { updateTimeBuilder_.dispose(); updateTimeBuilder_ = null; } environmentCase_ = 0; environment_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.notebooks.v1.InstanceProto .internal_static_google_cloud_notebooks_v1_Instance_descriptor; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance getDefaultInstanceForType() { return com.google.cloud.notebooks.v1.Instance.getDefaultInstance(); } @java.lang.Override public com.google.cloud.notebooks.v1.Instance build() { com.google.cloud.notebooks.v1.Instance result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance buildPartial() { com.google.cloud.notebooks.v1.Instance result = new com.google.cloud.notebooks.v1.Instance(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } if (bitField1_ != 0) { buildPartial1(result); } buildPartialOneofs(result); onBuilt(); return result; } private void buildPartialRepeatedFields(com.google.cloud.notebooks.v1.Instance result) { if (disksBuilder_ == null) { if (((bitField0_ & 0x00100000) != 0)) { disks_ = java.util.Collections.unmodifiableList(disks_); bitField0_ = (bitField0_ & ~0x00100000); } result.disks_ = disks_; } else { result.disks_ = disksBuilder_.build(); } if (upgradeHistoryBuilder_ == null) { if (((bitField0_ & 0x20000000) != 0)) { upgradeHistory_ = java.util.Collections.unmodifiableList(upgradeHistory_); bitField0_ = (bitField0_ & ~0x20000000); } result.upgradeHistory_ = upgradeHistory_; } else { result.upgradeHistory_ = upgradeHistoryBuilder_.build(); } } private void buildPartial0(com.google.cloud.notebooks.v1.Instance result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.name_ = name_; } if (((from_bitField0_ & 0x00000008) != 0)) { result.postStartupScript_ = postStartupScript_; } if (((from_bitField0_ & 0x00000010) != 0)) { result.proxyUri_ = proxyUri_; } if (((from_bitField0_ & 0x00000020) != 0)) { instanceOwners_.makeImmutable(); result.instanceOwners_ = instanceOwners_; } if (((from_bitField0_ & 0x00000040) != 0)) { result.serviceAccount_ = serviceAccount_; } if (((from_bitField0_ & 0x00000080) != 0)) { serviceAccountScopes_.makeImmutable(); result.serviceAccountScopes_ = serviceAccountScopes_; } if (((from_bitField0_ & 0x00000100) != 0)) { result.machineType_ = machineType_; } int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000200) != 0)) { result.acceleratorConfig_ = acceleratorConfigBuilder_ == null ? acceleratorConfig_ : acceleratorConfigBuilder_.build(); to_bitField0_ |= 0x00000001; } if (((from_bitField0_ & 0x00000400) != 0)) { result.state_ = state_; } if (((from_bitField0_ & 0x00000800) != 0)) { result.installGpuDriver_ = installGpuDriver_; } if (((from_bitField0_ & 0x00001000) != 0)) { result.customGpuDriverPath_ = customGpuDriverPath_; } if (((from_bitField0_ & 0x00002000) != 0)) { result.bootDiskType_ = bootDiskType_; } if (((from_bitField0_ & 0x00004000) != 0)) { result.bootDiskSizeGb_ = bootDiskSizeGb_; } if (((from_bitField0_ & 0x00008000) != 0)) { result.dataDiskType_ = dataDiskType_; } if (((from_bitField0_ & 0x00010000) != 0)) { result.dataDiskSizeGb_ = dataDiskSizeGb_; } if (((from_bitField0_ & 0x00020000) != 0)) { result.noRemoveDataDisk_ = noRemoveDataDisk_; } if (((from_bitField0_ & 0x00040000) != 0)) { result.diskEncryption_ = diskEncryption_; } if (((from_bitField0_ & 0x00080000) != 0)) { result.kmsKey_ = kmsKey_; } if (((from_bitField0_ & 0x00200000) != 0)) { result.shieldedInstanceConfig_ = shieldedInstanceConfigBuilder_ == null ? shieldedInstanceConfig_ : shieldedInstanceConfigBuilder_.build(); to_bitField0_ |= 0x00000002; } if (((from_bitField0_ & 0x00400000) != 0)) { result.noPublicIp_ = noPublicIp_; } if (((from_bitField0_ & 0x00800000) != 0)) { result.noProxyAccess_ = noProxyAccess_; } if (((from_bitField0_ & 0x01000000) != 0)) { result.network_ = network_; } if (((from_bitField0_ & 0x02000000) != 0)) { result.subnet_ = subnet_; } if (((from_bitField0_ & 0x04000000) != 0)) { result.labels_ = internalGetLabels(); result.labels_.makeImmutable(); } if (((from_bitField0_ & 0x08000000) != 0)) { result.metadata_ = internalGetMetadata(); result.metadata_.makeImmutable(); } if (((from_bitField0_ & 0x10000000) != 0)) { tags_.makeImmutable(); result.tags_ = tags_; } if (((from_bitField0_ & 0x40000000) != 0)) { result.nicType_ = nicType_; } if (((from_bitField0_ & 0x80000000) != 0)) { result.reservationAffinity_ = reservationAffinityBuilder_ == null ? reservationAffinity_ : reservationAffinityBuilder_.build(); to_bitField0_ |= 0x00000004; } result.bitField0_ |= to_bitField0_; } private void buildPartial1(com.google.cloud.notebooks.v1.Instance result) { int from_bitField1_ = bitField1_; if (((from_bitField1_ & 0x00000001) != 0)) { result.creator_ = creator_; } if (((from_bitField1_ & 0x00000002) != 0)) { result.canIpForward_ = canIpForward_; } int to_bitField0_ = 0; if (((from_bitField1_ & 0x00000004) != 0)) { result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); to_bitField0_ |= 0x00000008; } if (((from_bitField1_ & 0x00000008) != 0)) { result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); to_bitField0_ |= 0x00000010; } result.bitField0_ |= to_bitField0_; } private void buildPartialOneofs(com.google.cloud.notebooks.v1.Instance result) { result.environmentCase_ = environmentCase_; result.environment_ = this.environment_; if (environmentCase_ == 2 && vmImageBuilder_ != null) { result.environment_ = vmImageBuilder_.build(); } if (environmentCase_ == 3 && containerImageBuilder_ != null) { result.environment_ = containerImageBuilder_.build(); } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.notebooks.v1.Instance) { return mergeFrom((com.google.cloud.notebooks.v1.Instance) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.notebooks.v1.Instance other) { if (other == com.google.cloud.notebooks.v1.Instance.getDefaultInstance()) return this; if (!other.getName().isEmpty()) { name_ = other.name_; bitField0_ |= 0x00000001; onChanged(); } if (!other.getPostStartupScript().isEmpty()) { postStartupScript_ = other.postStartupScript_; bitField0_ |= 0x00000008; onChanged(); } if (!other.getProxyUri().isEmpty()) { proxyUri_ = other.proxyUri_; bitField0_ |= 0x00000010; onChanged(); } if (!other.instanceOwners_.isEmpty()) { if (instanceOwners_.isEmpty()) { instanceOwners_ = other.instanceOwners_; bitField0_ |= 0x00000020; } else { ensureInstanceOwnersIsMutable(); instanceOwners_.addAll(other.instanceOwners_); } onChanged(); } if (!other.getServiceAccount().isEmpty()) { serviceAccount_ = other.serviceAccount_; bitField0_ |= 0x00000040; onChanged(); } if (!other.serviceAccountScopes_.isEmpty()) { if (serviceAccountScopes_.isEmpty()) { serviceAccountScopes_ = other.serviceAccountScopes_; bitField0_ |= 0x00000080; } else { ensureServiceAccountScopesIsMutable(); serviceAccountScopes_.addAll(other.serviceAccountScopes_); } onChanged(); } if (!other.getMachineType().isEmpty()) { machineType_ = other.machineType_; bitField0_ |= 0x00000100; onChanged(); } if (other.hasAcceleratorConfig()) { mergeAcceleratorConfig(other.getAcceleratorConfig()); } if (other.state_ != 0) { setStateValue(other.getStateValue()); } if (other.getInstallGpuDriver() != false) { setInstallGpuDriver(other.getInstallGpuDriver()); } if (!other.getCustomGpuDriverPath().isEmpty()) { customGpuDriverPath_ = other.customGpuDriverPath_; bitField0_ |= 0x00001000; onChanged(); } if (other.bootDiskType_ != 0) { setBootDiskTypeValue(other.getBootDiskTypeValue()); } if (other.getBootDiskSizeGb() != 0L) { setBootDiskSizeGb(other.getBootDiskSizeGb()); } if (other.dataDiskType_ != 0) { setDataDiskTypeValue(other.getDataDiskTypeValue()); } if (other.getDataDiskSizeGb() != 0L) { setDataDiskSizeGb(other.getDataDiskSizeGb()); } if (other.getNoRemoveDataDisk() != false) { setNoRemoveDataDisk(other.getNoRemoveDataDisk()); } if (other.diskEncryption_ != 0) { setDiskEncryptionValue(other.getDiskEncryptionValue()); } if (!other.getKmsKey().isEmpty()) { kmsKey_ = other.kmsKey_; bitField0_ |= 0x00080000; onChanged(); } if (disksBuilder_ == null) { if (!other.disks_.isEmpty()) { if (disks_.isEmpty()) { disks_ = other.disks_; bitField0_ = (bitField0_ & ~0x00100000); } else { ensureDisksIsMutable(); disks_.addAll(other.disks_); } onChanged(); } } else { if (!other.disks_.isEmpty()) { if (disksBuilder_.isEmpty()) { disksBuilder_.dispose(); disksBuilder_ = null; disks_ = other.disks_; bitField0_ = (bitField0_ & ~0x00100000); disksBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getDisksFieldBuilder() : null; } else { disksBuilder_.addAllMessages(other.disks_); } } } if (other.hasShieldedInstanceConfig()) { mergeShieldedInstanceConfig(other.getShieldedInstanceConfig()); } if (other.getNoPublicIp() != false) { setNoPublicIp(other.getNoPublicIp()); } if (other.getNoProxyAccess() != false) { setNoProxyAccess(other.getNoProxyAccess()); } if (!other.getNetwork().isEmpty()) { network_ = other.network_; bitField0_ |= 0x01000000; onChanged(); } if (!other.getSubnet().isEmpty()) { subnet_ = other.subnet_; bitField0_ |= 0x02000000; onChanged(); } internalGetMutableLabels().mergeFrom(other.internalGetLabels()); bitField0_ |= 0x04000000; internalGetMutableMetadata().mergeFrom(other.internalGetMetadata()); bitField0_ |= 0x08000000; if (!other.tags_.isEmpty()) { if (tags_.isEmpty()) { tags_ = other.tags_; bitField0_ |= 0x10000000; } else { ensureTagsIsMutable(); tags_.addAll(other.tags_); } onChanged(); } if (upgradeHistoryBuilder_ == null) { if (!other.upgradeHistory_.isEmpty()) { if (upgradeHistory_.isEmpty()) { upgradeHistory_ = other.upgradeHistory_; bitField0_ = (bitField0_ & ~0x20000000); } else { ensureUpgradeHistoryIsMutable(); upgradeHistory_.addAll(other.upgradeHistory_); } onChanged(); } } else { if (!other.upgradeHistory_.isEmpty()) { if (upgradeHistoryBuilder_.isEmpty()) { upgradeHistoryBuilder_.dispose(); upgradeHistoryBuilder_ = null; upgradeHistory_ = other.upgradeHistory_; bitField0_ = (bitField0_ & ~0x20000000); upgradeHistoryBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getUpgradeHistoryFieldBuilder() : null; } else { upgradeHistoryBuilder_.addAllMessages(other.upgradeHistory_); } } } if (other.nicType_ != 0) { setNicTypeValue(other.getNicTypeValue()); } if (other.hasReservationAffinity()) { mergeReservationAffinity(other.getReservationAffinity()); } if (!other.getCreator().isEmpty()) { creator_ = other.creator_; bitField1_ |= 0x00000001; onChanged(); } if (other.getCanIpForward() != false) { setCanIpForward(other.getCanIpForward()); } if (other.hasCreateTime()) { mergeCreateTime(other.getCreateTime()); } if (other.hasUpdateTime()) { mergeUpdateTime(other.getUpdateTime()); } switch (other.getEnvironmentCase()) { case VM_IMAGE: { mergeVmImage(other.getVmImage()); break; } case CONTAINER_IMAGE: { mergeContainerImage(other.getContainerImage()); break; } case ENVIRONMENT_NOT_SET: { break; } } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { name_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 18: { input.readMessage(getVmImageFieldBuilder().getBuilder(), extensionRegistry); environmentCase_ = 2; break; } // case 18 case 26: { input.readMessage(getContainerImageFieldBuilder().getBuilder(), extensionRegistry); environmentCase_ = 3; break; } // case 26 case 34: { postStartupScript_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000008; break; } // case 34 case 42: { proxyUri_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000010; break; } // case 42 case 50: { java.lang.String s = input.readStringRequireUtf8(); ensureInstanceOwnersIsMutable(); instanceOwners_.add(s); break; } // case 50 case 58: { serviceAccount_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000040; break; } // case 58 case 66: { machineType_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000100; break; } // case 66 case 74: { input.readMessage( getAcceleratorConfigFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000200; break; } // case 74 case 80: { state_ = input.readEnum(); bitField0_ |= 0x00000400; break; } // case 80 case 88: { installGpuDriver_ = input.readBool(); bitField0_ |= 0x00000800; break; } // case 88 case 98: { customGpuDriverPath_ = input.readStringRequireUtf8(); bitField0_ |= 0x00001000; break; } // case 98 case 104: { bootDiskType_ = input.readEnum(); bitField0_ |= 0x00002000; break; } // case 104 case 112: { bootDiskSizeGb_ = input.readInt64(); bitField0_ |= 0x00004000; break; } // case 112 case 120: { diskEncryption_ = input.readEnum(); bitField0_ |= 0x00040000; break; } // case 120 case 130: { kmsKey_ = input.readStringRequireUtf8(); bitField0_ |= 0x00080000; break; } // case 130 case 136: { noPublicIp_ = input.readBool(); bitField0_ |= 0x00400000; break; } // case 136 case 144: { noProxyAccess_ = input.readBool(); bitField0_ |= 0x00800000; break; } // case 144 case 154: { network_ = input.readStringRequireUtf8(); bitField0_ |= 0x01000000; break; } // case 154 case 162: { subnet_ = input.readStringRequireUtf8(); bitField0_ |= 0x02000000; break; } // case 162 case 170: { com.google.protobuf.MapEntry labels__ = input.readMessage( LabelsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); internalGetMutableLabels() .getMutableMap() .put(labels__.getKey(), labels__.getValue()); bitField0_ |= 0x04000000; break; } // case 170 case 178: { com.google.protobuf.MapEntry metadata__ = input.readMessage( MetadataDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); internalGetMutableMetadata() .getMutableMap() .put(metadata__.getKey(), metadata__.getValue()); bitField0_ |= 0x08000000; break; } // case 178 case 186: { input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); bitField1_ |= 0x00000004; break; } // case 186 case 194: { input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); bitField1_ |= 0x00000008; break; } // case 194 case 200: { dataDiskType_ = input.readEnum(); bitField0_ |= 0x00008000; break; } // case 200 case 208: { dataDiskSizeGb_ = input.readInt64(); bitField0_ |= 0x00010000; break; } // case 208 case 216: { noRemoveDataDisk_ = input.readBool(); bitField0_ |= 0x00020000; break; } // case 216 case 226: { com.google.cloud.notebooks.v1.Instance.Disk m = input.readMessage( com.google.cloud.notebooks.v1.Instance.Disk.parser(), extensionRegistry); if (disksBuilder_ == null) { ensureDisksIsMutable(); disks_.add(m); } else { disksBuilder_.addMessage(m); } break; } // case 226 case 234: { com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry m = input.readMessage( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.parser(), extensionRegistry); if (upgradeHistoryBuilder_ == null) { ensureUpgradeHistoryIsMutable(); upgradeHistory_.add(m); } else { upgradeHistoryBuilder_.addMessage(m); } break; } // case 234 case 242: { input.readMessage( getShieldedInstanceConfigFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00200000; break; } // case 242 case 250: { java.lang.String s = input.readStringRequireUtf8(); ensureServiceAccountScopesIsMutable(); serviceAccountScopes_.add(s); break; } // case 250 case 258: { java.lang.String s = input.readStringRequireUtf8(); ensureTagsIsMutable(); tags_.add(s); break; } // case 258 case 264: { nicType_ = input.readEnum(); bitField0_ |= 0x40000000; break; } // case 264 case 274: { input.readMessage( getReservationAffinityFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x80000000; break; } // case 274 case 290: { creator_ = input.readStringRequireUtf8(); bitField1_ |= 0x00000001; break; } // case 290 case 312: { canIpForward_ = input.readBool(); bitField1_ |= 0x00000002; break; } // case 312 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int environmentCase_ = 0; private java.lang.Object environment_; public EnvironmentCase getEnvironmentCase() { return EnvironmentCase.forNumber(environmentCase_); } public Builder clearEnvironment() { environmentCase_ = 0; environment_ = null; onChanged(); return this; } private int bitField0_; private int bitField1_; private java.lang.Object name_ = ""; /** * * *
     * Output only. The name of this notebook instance. Format:
     * `projects/{project_id}/locations/{location}/instances/{instance_id}`
     * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Output only. The name of this notebook instance. Format:
     * `projects/{project_id}/locations/{location}/instances/{instance_id}`
     * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for name. */ public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Output only. The name of this notebook instance. Format:
     * `projects/{project_id}/locations/{location}/instances/{instance_id}`
     * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The name to set. * @return This builder for chaining. */ public Builder setName(java.lang.String value) { if (value == null) { throw new NullPointerException(); } name_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
     * Output only. The name of this notebook instance. Format:
     * `projects/{project_id}/locations/{location}/instances/{instance_id}`
     * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearName() { name_ = getDefaultInstance().getName(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * * *
     * Output only. The name of this notebook instance. Format:
     * `projects/{project_id}/locations/{location}/instances/{instance_id}`
     * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for name to set. * @return This builder for chaining. */ public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); name_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.VmImage, com.google.cloud.notebooks.v1.VmImage.Builder, com.google.cloud.notebooks.v1.VmImageOrBuilder> vmImageBuilder_; /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; * * @return Whether the vmImage field is set. */ @java.lang.Override public boolean hasVmImage() { return environmentCase_ == 2; } /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; * * @return The vmImage. */ @java.lang.Override public com.google.cloud.notebooks.v1.VmImage getVmImage() { if (vmImageBuilder_ == null) { if (environmentCase_ == 2) { return (com.google.cloud.notebooks.v1.VmImage) environment_; } return com.google.cloud.notebooks.v1.VmImage.getDefaultInstance(); } else { if (environmentCase_ == 2) { return vmImageBuilder_.getMessage(); } return com.google.cloud.notebooks.v1.VmImage.getDefaultInstance(); } } /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; */ public Builder setVmImage(com.google.cloud.notebooks.v1.VmImage value) { if (vmImageBuilder_ == null) { if (value == null) { throw new NullPointerException(); } environment_ = value; onChanged(); } else { vmImageBuilder_.setMessage(value); } environmentCase_ = 2; return this; } /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; */ public Builder setVmImage(com.google.cloud.notebooks.v1.VmImage.Builder builderForValue) { if (vmImageBuilder_ == null) { environment_ = builderForValue.build(); onChanged(); } else { vmImageBuilder_.setMessage(builderForValue.build()); } environmentCase_ = 2; return this; } /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; */ public Builder mergeVmImage(com.google.cloud.notebooks.v1.VmImage value) { if (vmImageBuilder_ == null) { if (environmentCase_ == 2 && environment_ != com.google.cloud.notebooks.v1.VmImage.getDefaultInstance()) { environment_ = com.google.cloud.notebooks.v1.VmImage.newBuilder( (com.google.cloud.notebooks.v1.VmImage) environment_) .mergeFrom(value) .buildPartial(); } else { environment_ = value; } onChanged(); } else { if (environmentCase_ == 2) { vmImageBuilder_.mergeFrom(value); } else { vmImageBuilder_.setMessage(value); } } environmentCase_ = 2; return this; } /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; */ public Builder clearVmImage() { if (vmImageBuilder_ == null) { if (environmentCase_ == 2) { environmentCase_ = 0; environment_ = null; onChanged(); } } else { if (environmentCase_ == 2) { environmentCase_ = 0; environment_ = null; } vmImageBuilder_.clear(); } return this; } /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; */ public com.google.cloud.notebooks.v1.VmImage.Builder getVmImageBuilder() { return getVmImageFieldBuilder().getBuilder(); } /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; */ @java.lang.Override public com.google.cloud.notebooks.v1.VmImageOrBuilder getVmImageOrBuilder() { if ((environmentCase_ == 2) && (vmImageBuilder_ != null)) { return vmImageBuilder_.getMessageOrBuilder(); } else { if (environmentCase_ == 2) { return (com.google.cloud.notebooks.v1.VmImage) environment_; } return com.google.cloud.notebooks.v1.VmImage.getDefaultInstance(); } } /** * * *
     * Use a Compute Engine VM image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.VmImage vm_image = 2; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.VmImage, com.google.cloud.notebooks.v1.VmImage.Builder, com.google.cloud.notebooks.v1.VmImageOrBuilder> getVmImageFieldBuilder() { if (vmImageBuilder_ == null) { if (!(environmentCase_ == 2)) { environment_ = com.google.cloud.notebooks.v1.VmImage.getDefaultInstance(); } vmImageBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.VmImage, com.google.cloud.notebooks.v1.VmImage.Builder, com.google.cloud.notebooks.v1.VmImageOrBuilder>( (com.google.cloud.notebooks.v1.VmImage) environment_, getParentForChildren(), isClean()); environment_ = null; } environmentCase_ = 2; onChanged(); return vmImageBuilder_; } private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.ContainerImage, com.google.cloud.notebooks.v1.ContainerImage.Builder, com.google.cloud.notebooks.v1.ContainerImageOrBuilder> containerImageBuilder_; /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; * * @return Whether the containerImage field is set. */ @java.lang.Override public boolean hasContainerImage() { return environmentCase_ == 3; } /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; * * @return The containerImage. */ @java.lang.Override public com.google.cloud.notebooks.v1.ContainerImage getContainerImage() { if (containerImageBuilder_ == null) { if (environmentCase_ == 3) { return (com.google.cloud.notebooks.v1.ContainerImage) environment_; } return com.google.cloud.notebooks.v1.ContainerImage.getDefaultInstance(); } else { if (environmentCase_ == 3) { return containerImageBuilder_.getMessage(); } return com.google.cloud.notebooks.v1.ContainerImage.getDefaultInstance(); } } /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; */ public Builder setContainerImage(com.google.cloud.notebooks.v1.ContainerImage value) { if (containerImageBuilder_ == null) { if (value == null) { throw new NullPointerException(); } environment_ = value; onChanged(); } else { containerImageBuilder_.setMessage(value); } environmentCase_ = 3; return this; } /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; */ public Builder setContainerImage( com.google.cloud.notebooks.v1.ContainerImage.Builder builderForValue) { if (containerImageBuilder_ == null) { environment_ = builderForValue.build(); onChanged(); } else { containerImageBuilder_.setMessage(builderForValue.build()); } environmentCase_ = 3; return this; } /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; */ public Builder mergeContainerImage(com.google.cloud.notebooks.v1.ContainerImage value) { if (containerImageBuilder_ == null) { if (environmentCase_ == 3 && environment_ != com.google.cloud.notebooks.v1.ContainerImage.getDefaultInstance()) { environment_ = com.google.cloud.notebooks.v1.ContainerImage.newBuilder( (com.google.cloud.notebooks.v1.ContainerImage) environment_) .mergeFrom(value) .buildPartial(); } else { environment_ = value; } onChanged(); } else { if (environmentCase_ == 3) { containerImageBuilder_.mergeFrom(value); } else { containerImageBuilder_.setMessage(value); } } environmentCase_ = 3; return this; } /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; */ public Builder clearContainerImage() { if (containerImageBuilder_ == null) { if (environmentCase_ == 3) { environmentCase_ = 0; environment_ = null; onChanged(); } } else { if (environmentCase_ == 3) { environmentCase_ = 0; environment_ = null; } containerImageBuilder_.clear(); } return this; } /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; */ public com.google.cloud.notebooks.v1.ContainerImage.Builder getContainerImageBuilder() { return getContainerImageFieldBuilder().getBuilder(); } /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; */ @java.lang.Override public com.google.cloud.notebooks.v1.ContainerImageOrBuilder getContainerImageOrBuilder() { if ((environmentCase_ == 3) && (containerImageBuilder_ != null)) { return containerImageBuilder_.getMessageOrBuilder(); } else { if (environmentCase_ == 3) { return (com.google.cloud.notebooks.v1.ContainerImage) environment_; } return com.google.cloud.notebooks.v1.ContainerImage.getDefaultInstance(); } } /** * * *
     * Use a container image to start the notebook instance.
     * 
* * .google.cloud.notebooks.v1.ContainerImage container_image = 3; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.ContainerImage, com.google.cloud.notebooks.v1.ContainerImage.Builder, com.google.cloud.notebooks.v1.ContainerImageOrBuilder> getContainerImageFieldBuilder() { if (containerImageBuilder_ == null) { if (!(environmentCase_ == 3)) { environment_ = com.google.cloud.notebooks.v1.ContainerImage.getDefaultInstance(); } containerImageBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.ContainerImage, com.google.cloud.notebooks.v1.ContainerImage.Builder, com.google.cloud.notebooks.v1.ContainerImageOrBuilder>( (com.google.cloud.notebooks.v1.ContainerImage) environment_, getParentForChildren(), isClean()); environment_ = null; } environmentCase_ = 3; onChanged(); return containerImageBuilder_; } private java.lang.Object postStartupScript_ = ""; /** * * *
     * Path to a Bash script that automatically runs after a notebook instance
     * fully boots up. The path must be a URL or
     * Cloud Storage path (`gs://path-to-file/file-name`).
     * 
* * string post_startup_script = 4; * * @return The postStartupScript. */ public java.lang.String getPostStartupScript() { java.lang.Object ref = postStartupScript_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); postStartupScript_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Path to a Bash script that automatically runs after a notebook instance
     * fully boots up. The path must be a URL or
     * Cloud Storage path (`gs://path-to-file/file-name`).
     * 
* * string post_startup_script = 4; * * @return The bytes for postStartupScript. */ public com.google.protobuf.ByteString getPostStartupScriptBytes() { java.lang.Object ref = postStartupScript_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); postStartupScript_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Path to a Bash script that automatically runs after a notebook instance
     * fully boots up. The path must be a URL or
     * Cloud Storage path (`gs://path-to-file/file-name`).
     * 
* * string post_startup_script = 4; * * @param value The postStartupScript to set. * @return This builder for chaining. */ public Builder setPostStartupScript(java.lang.String value) { if (value == null) { throw new NullPointerException(); } postStartupScript_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } /** * * *
     * Path to a Bash script that automatically runs after a notebook instance
     * fully boots up. The path must be a URL or
     * Cloud Storage path (`gs://path-to-file/file-name`).
     * 
* * string post_startup_script = 4; * * @return This builder for chaining. */ public Builder clearPostStartupScript() { postStartupScript_ = getDefaultInstance().getPostStartupScript(); bitField0_ = (bitField0_ & ~0x00000008); onChanged(); return this; } /** * * *
     * Path to a Bash script that automatically runs after a notebook instance
     * fully boots up. The path must be a URL or
     * Cloud Storage path (`gs://path-to-file/file-name`).
     * 
* * string post_startup_script = 4; * * @param value The bytes for postStartupScript to set. * @return This builder for chaining. */ public Builder setPostStartupScriptBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); postStartupScript_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } private java.lang.Object proxyUri_ = ""; /** * * *
     * Output only. The proxy endpoint that is used to access the Jupyter notebook.
     * 
* * string proxy_uri = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The proxyUri. */ public java.lang.String getProxyUri() { java.lang.Object ref = proxyUri_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); proxyUri_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Output only. The proxy endpoint that is used to access the Jupyter notebook.
     * 
* * string proxy_uri = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for proxyUri. */ public com.google.protobuf.ByteString getProxyUriBytes() { java.lang.Object ref = proxyUri_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); proxyUri_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Output only. The proxy endpoint that is used to access the Jupyter notebook.
     * 
* * string proxy_uri = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The proxyUri to set. * @return This builder for chaining. */ public Builder setProxyUri(java.lang.String value) { if (value == null) { throw new NullPointerException(); } proxyUri_ = value; bitField0_ |= 0x00000010; onChanged(); return this; } /** * * *
     * Output only. The proxy endpoint that is used to access the Jupyter notebook.
     * 
* * string proxy_uri = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearProxyUri() { proxyUri_ = getDefaultInstance().getProxyUri(); bitField0_ = (bitField0_ & ~0x00000010); onChanged(); return this; } /** * * *
     * Output only. The proxy endpoint that is used to access the Jupyter notebook.
     * 
* * string proxy_uri = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for proxyUri to set. * @return This builder for chaining. */ public Builder setProxyUriBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); proxyUri_ = value; bitField0_ |= 0x00000010; onChanged(); return this; } private com.google.protobuf.LazyStringArrayList instanceOwners_ = com.google.protobuf.LazyStringArrayList.emptyList(); private void ensureInstanceOwnersIsMutable() { if (!instanceOwners_.isModifiable()) { instanceOwners_ = new com.google.protobuf.LazyStringArrayList(instanceOwners_); } bitField0_ |= 0x00000020; } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return A list containing the instanceOwners. */ public com.google.protobuf.ProtocolStringList getInstanceOwnersList() { instanceOwners_.makeImmutable(); return instanceOwners_; } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The count of instanceOwners. */ public int getInstanceOwnersCount() { return instanceOwners_.size(); } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param index The index of the element to return. * @return The instanceOwners at the given index. */ public java.lang.String getInstanceOwners(int index) { return instanceOwners_.get(index); } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param index The index of the value to return. * @return The bytes of the instanceOwners at the given index. */ public com.google.protobuf.ByteString getInstanceOwnersBytes(int index) { return instanceOwners_.getByteString(index); } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param index The index to set the value at. * @param value The instanceOwners to set. * @return This builder for chaining. */ public Builder setInstanceOwners(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureInstanceOwnersIsMutable(); instanceOwners_.set(index, value); bitField0_ |= 0x00000020; onChanged(); return this; } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The instanceOwners to add. * @return This builder for chaining. */ public Builder addInstanceOwners(java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureInstanceOwnersIsMutable(); instanceOwners_.add(value); bitField0_ |= 0x00000020; onChanged(); return this; } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param values The instanceOwners to add. * @return This builder for chaining. */ public Builder addAllInstanceOwners(java.lang.Iterable values) { ensureInstanceOwnersIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, instanceOwners_); bitField0_ |= 0x00000020; onChanged(); return this; } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearInstanceOwners() { instanceOwners_ = com.google.protobuf.LazyStringArrayList.emptyList(); bitField0_ = (bitField0_ & ~0x00000020); ; onChanged(); return this; } /** * * *
     * Input only. The owner of this instance after creation. Format: `alias@example.com`
     *
     * Currently supports one owner only. If not specified, all of the service
     * account users of your VM instance's service account can use
     * the instance.
     * 
* * repeated string instance_owners = 6 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The bytes of the instanceOwners to add. * @return This builder for chaining. */ public Builder addInstanceOwnersBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); ensureInstanceOwnersIsMutable(); instanceOwners_.add(value); bitField0_ |= 0x00000020; onChanged(); return this; } private java.lang.Object serviceAccount_ = ""; /** * * *
     * The service account on this instance, giving access to other Google
     * Cloud services.
     * You can use any service account within the same project, but you
     * must have the service account user permission to use the instance.
     *
     * If not specified, the [Compute Engine default service
     * account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account)
     * is used.
     * 
* * string service_account = 7; * * @return The serviceAccount. */ public java.lang.String getServiceAccount() { java.lang.Object ref = serviceAccount_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); serviceAccount_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * The service account on this instance, giving access to other Google
     * Cloud services.
     * You can use any service account within the same project, but you
     * must have the service account user permission to use the instance.
     *
     * If not specified, the [Compute Engine default service
     * account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account)
     * is used.
     * 
* * string service_account = 7; * * @return The bytes for serviceAccount. */ public com.google.protobuf.ByteString getServiceAccountBytes() { java.lang.Object ref = serviceAccount_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); serviceAccount_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * The service account on this instance, giving access to other Google
     * Cloud services.
     * You can use any service account within the same project, but you
     * must have the service account user permission to use the instance.
     *
     * If not specified, the [Compute Engine default service
     * account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account)
     * is used.
     * 
* * string service_account = 7; * * @param value The serviceAccount to set. * @return This builder for chaining. */ public Builder setServiceAccount(java.lang.String value) { if (value == null) { throw new NullPointerException(); } serviceAccount_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } /** * * *
     * The service account on this instance, giving access to other Google
     * Cloud services.
     * You can use any service account within the same project, but you
     * must have the service account user permission to use the instance.
     *
     * If not specified, the [Compute Engine default service
     * account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account)
     * is used.
     * 
* * string service_account = 7; * * @return This builder for chaining. */ public Builder clearServiceAccount() { serviceAccount_ = getDefaultInstance().getServiceAccount(); bitField0_ = (bitField0_ & ~0x00000040); onChanged(); return this; } /** * * *
     * The service account on this instance, giving access to other Google
     * Cloud services.
     * You can use any service account within the same project, but you
     * must have the service account user permission to use the instance.
     *
     * If not specified, the [Compute Engine default service
     * account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account)
     * is used.
     * 
* * string service_account = 7; * * @param value The bytes for serviceAccount to set. * @return This builder for chaining. */ public Builder setServiceAccountBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); serviceAccount_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } private com.google.protobuf.LazyStringArrayList serviceAccountScopes_ = com.google.protobuf.LazyStringArrayList.emptyList(); private void ensureServiceAccountScopesIsMutable() { if (!serviceAccountScopes_.isModifiable()) { serviceAccountScopes_ = new com.google.protobuf.LazyStringArrayList(serviceAccountScopes_); } bitField0_ |= 0x00000080; } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @return A list containing the serviceAccountScopes. */ public com.google.protobuf.ProtocolStringList getServiceAccountScopesList() { serviceAccountScopes_.makeImmutable(); return serviceAccountScopes_; } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The count of serviceAccountScopes. */ public int getServiceAccountScopesCount() { return serviceAccountScopes_.size(); } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @param index The index of the element to return. * @return The serviceAccountScopes at the given index. */ public java.lang.String getServiceAccountScopes(int index) { return serviceAccountScopes_.get(index); } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @param index The index of the value to return. * @return The bytes of the serviceAccountScopes at the given index. */ public com.google.protobuf.ByteString getServiceAccountScopesBytes(int index) { return serviceAccountScopes_.getByteString(index); } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @param index The index to set the value at. * @param value The serviceAccountScopes to set. * @return This builder for chaining. */ public Builder setServiceAccountScopes(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureServiceAccountScopesIsMutable(); serviceAccountScopes_.set(index, value); bitField0_ |= 0x00000080; onChanged(); return this; } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @param value The serviceAccountScopes to add. * @return This builder for chaining. */ public Builder addServiceAccountScopes(java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureServiceAccountScopesIsMutable(); serviceAccountScopes_.add(value); bitField0_ |= 0x00000080; onChanged(); return this; } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @param values The serviceAccountScopes to add. * @return This builder for chaining. */ public Builder addAllServiceAccountScopes(java.lang.Iterable values) { ensureServiceAccountScopesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, serviceAccountScopes_); bitField0_ |= 0x00000080; onChanged(); return this; } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @return This builder for chaining. */ public Builder clearServiceAccountScopes() { serviceAccountScopes_ = com.google.protobuf.LazyStringArrayList.emptyList(); bitField0_ = (bitField0_ & ~0x00000080); ; onChanged(); return this; } /** * * *
     * Optional. The URIs of service account scopes to be included in
     * Compute Engine instances.
     *
     * If not specified, the following
     * [scopes](https://cloud.google.com/compute/docs/access/service-accounts#accesscopesiam)
     * are defined:
     *  - https://www.googleapis.com/auth/cloud-platform
     *  - https://www.googleapis.com/auth/userinfo.email
     * If not using default scopes, you need at least:
     *    https://www.googleapis.com/auth/compute
     * 
* * repeated string service_account_scopes = 31 [(.google.api.field_behavior) = OPTIONAL]; * * * @param value The bytes of the serviceAccountScopes to add. * @return This builder for chaining. */ public Builder addServiceAccountScopesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); ensureServiceAccountScopesIsMutable(); serviceAccountScopes_.add(value); bitField0_ |= 0x00000080; onChanged(); return this; } private java.lang.Object machineType_ = ""; /** * * *
     * Required. The [Compute Engine machine
     * type](https://cloud.google.com/compute/docs/machine-types) of this
     * instance.
     * 
* * string machine_type = 8 [(.google.api.field_behavior) = REQUIRED]; * * @return The machineType. */ public java.lang.String getMachineType() { java.lang.Object ref = machineType_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); machineType_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Required. The [Compute Engine machine
     * type](https://cloud.google.com/compute/docs/machine-types) of this
     * instance.
     * 
* * string machine_type = 8 [(.google.api.field_behavior) = REQUIRED]; * * @return The bytes for machineType. */ public com.google.protobuf.ByteString getMachineTypeBytes() { java.lang.Object ref = machineType_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); machineType_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Required. The [Compute Engine machine
     * type](https://cloud.google.com/compute/docs/machine-types) of this
     * instance.
     * 
* * string machine_type = 8 [(.google.api.field_behavior) = REQUIRED]; * * @param value The machineType to set. * @return This builder for chaining. */ public Builder setMachineType(java.lang.String value) { if (value == null) { throw new NullPointerException(); } machineType_ = value; bitField0_ |= 0x00000100; onChanged(); return this; } /** * * *
     * Required. The [Compute Engine machine
     * type](https://cloud.google.com/compute/docs/machine-types) of this
     * instance.
     * 
* * string machine_type = 8 [(.google.api.field_behavior) = REQUIRED]; * * @return This builder for chaining. */ public Builder clearMachineType() { machineType_ = getDefaultInstance().getMachineType(); bitField0_ = (bitField0_ & ~0x00000100); onChanged(); return this; } /** * * *
     * Required. The [Compute Engine machine
     * type](https://cloud.google.com/compute/docs/machine-types) of this
     * instance.
     * 
* * string machine_type = 8 [(.google.api.field_behavior) = REQUIRED]; * * @param value The bytes for machineType to set. * @return This builder for chaining. */ public Builder setMachineTypeBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); machineType_ = value; bitField0_ |= 0x00000100; onChanged(); return this; } private com.google.cloud.notebooks.v1.Instance.AcceleratorConfig acceleratorConfig_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.AcceleratorConfig, com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.Builder, com.google.cloud.notebooks.v1.Instance.AcceleratorConfigOrBuilder> acceleratorConfigBuilder_; /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; * * @return Whether the acceleratorConfig field is set. */ public boolean hasAcceleratorConfig() { return ((bitField0_ & 0x00000200) != 0); } /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; * * @return The acceleratorConfig. */ public com.google.cloud.notebooks.v1.Instance.AcceleratorConfig getAcceleratorConfig() { if (acceleratorConfigBuilder_ == null) { return acceleratorConfig_ == null ? com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.getDefaultInstance() : acceleratorConfig_; } else { return acceleratorConfigBuilder_.getMessage(); } } /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; */ public Builder setAcceleratorConfig( com.google.cloud.notebooks.v1.Instance.AcceleratorConfig value) { if (acceleratorConfigBuilder_ == null) { if (value == null) { throw new NullPointerException(); } acceleratorConfig_ = value; } else { acceleratorConfigBuilder_.setMessage(value); } bitField0_ |= 0x00000200; onChanged(); return this; } /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; */ public Builder setAcceleratorConfig( com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.Builder builderForValue) { if (acceleratorConfigBuilder_ == null) { acceleratorConfig_ = builderForValue.build(); } else { acceleratorConfigBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000200; onChanged(); return this; } /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; */ public Builder mergeAcceleratorConfig( com.google.cloud.notebooks.v1.Instance.AcceleratorConfig value) { if (acceleratorConfigBuilder_ == null) { if (((bitField0_ & 0x00000200) != 0) && acceleratorConfig_ != null && acceleratorConfig_ != com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.getDefaultInstance()) { getAcceleratorConfigBuilder().mergeFrom(value); } else { acceleratorConfig_ = value; } } else { acceleratorConfigBuilder_.mergeFrom(value); } if (acceleratorConfig_ != null) { bitField0_ |= 0x00000200; onChanged(); } return this; } /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; */ public Builder clearAcceleratorConfig() { bitField0_ = (bitField0_ & ~0x00000200); acceleratorConfig_ = null; if (acceleratorConfigBuilder_ != null) { acceleratorConfigBuilder_.dispose(); acceleratorConfigBuilder_ = null; } onChanged(); return this; } /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; */ public com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.Builder getAcceleratorConfigBuilder() { bitField0_ |= 0x00000200; onChanged(); return getAcceleratorConfigFieldBuilder().getBuilder(); } /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; */ public com.google.cloud.notebooks.v1.Instance.AcceleratorConfigOrBuilder getAcceleratorConfigOrBuilder() { if (acceleratorConfigBuilder_ != null) { return acceleratorConfigBuilder_.getMessageOrBuilder(); } else { return acceleratorConfig_ == null ? com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.getDefaultInstance() : acceleratorConfig_; } } /** * * *
     * The hardware accelerator used on this instance. If you use
     * accelerators, make sure that your configuration has
     * [enough vCPUs and memory to support the `machine_type` you have
     * selected](https://cloud.google.com/compute/docs/gpus/#gpus-list).
     * 
* * .google.cloud.notebooks.v1.Instance.AcceleratorConfig accelerator_config = 9; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.AcceleratorConfig, com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.Builder, com.google.cloud.notebooks.v1.Instance.AcceleratorConfigOrBuilder> getAcceleratorConfigFieldBuilder() { if (acceleratorConfigBuilder_ == null) { acceleratorConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.AcceleratorConfig, com.google.cloud.notebooks.v1.Instance.AcceleratorConfig.Builder, com.google.cloud.notebooks.v1.Instance.AcceleratorConfigOrBuilder>( getAcceleratorConfig(), getParentForChildren(), isClean()); acceleratorConfig_ = null; } return acceleratorConfigBuilder_; } private int state_ = 0; /** * * *
     * Output only. The state of this instance.
     * 
* * * .google.cloud.notebooks.v1.Instance.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The enum numeric value on the wire for state. */ @java.lang.Override public int getStateValue() { return state_; } /** * * *
     * Output only. The state of this instance.
     * 
* * * .google.cloud.notebooks.v1.Instance.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The enum numeric value on the wire for state to set. * @return This builder for chaining. */ public Builder setStateValue(int value) { state_ = value; bitField0_ |= 0x00000400; onChanged(); return this; } /** * * *
     * Output only. The state of this instance.
     * 
* * * .google.cloud.notebooks.v1.Instance.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The state. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.State getState() { com.google.cloud.notebooks.v1.Instance.State result = com.google.cloud.notebooks.v1.Instance.State.forNumber(state_); return result == null ? com.google.cloud.notebooks.v1.Instance.State.UNRECOGNIZED : result; } /** * * *
     * Output only. The state of this instance.
     * 
* * * .google.cloud.notebooks.v1.Instance.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The state to set. * @return This builder for chaining. */ public Builder setState(com.google.cloud.notebooks.v1.Instance.State value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000400; state_ = value.getNumber(); onChanged(); return this; } /** * * *
     * Output only. The state of this instance.
     * 
* * * .google.cloud.notebooks.v1.Instance.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. */ public Builder clearState() { bitField0_ = (bitField0_ & ~0x00000400); state_ = 0; onChanged(); return this; } private boolean installGpuDriver_; /** * * *
     * Whether the end user authorizes Google Cloud to install GPU driver
     * on this instance.
     * If this field is empty or set to false, the GPU driver won't be installed.
     * Only applicable to instances with GPUs.
     * 
* * bool install_gpu_driver = 11; * * @return The installGpuDriver. */ @java.lang.Override public boolean getInstallGpuDriver() { return installGpuDriver_; } /** * * *
     * Whether the end user authorizes Google Cloud to install GPU driver
     * on this instance.
     * If this field is empty or set to false, the GPU driver won't be installed.
     * Only applicable to instances with GPUs.
     * 
* * bool install_gpu_driver = 11; * * @param value The installGpuDriver to set. * @return This builder for chaining. */ public Builder setInstallGpuDriver(boolean value) { installGpuDriver_ = value; bitField0_ |= 0x00000800; onChanged(); return this; } /** * * *
     * Whether the end user authorizes Google Cloud to install GPU driver
     * on this instance.
     * If this field is empty or set to false, the GPU driver won't be installed.
     * Only applicable to instances with GPUs.
     * 
* * bool install_gpu_driver = 11; * * @return This builder for chaining. */ public Builder clearInstallGpuDriver() { bitField0_ = (bitField0_ & ~0x00000800); installGpuDriver_ = false; onChanged(); return this; } private java.lang.Object customGpuDriverPath_ = ""; /** * * *
     * Specify a custom Cloud Storage path where the GPU driver is stored.
     * If not specified, we'll automatically choose from official GPU drivers.
     * 
* * string custom_gpu_driver_path = 12; * * @return The customGpuDriverPath. */ public java.lang.String getCustomGpuDriverPath() { java.lang.Object ref = customGpuDriverPath_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); customGpuDriverPath_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Specify a custom Cloud Storage path where the GPU driver is stored.
     * If not specified, we'll automatically choose from official GPU drivers.
     * 
* * string custom_gpu_driver_path = 12; * * @return The bytes for customGpuDriverPath. */ public com.google.protobuf.ByteString getCustomGpuDriverPathBytes() { java.lang.Object ref = customGpuDriverPath_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); customGpuDriverPath_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Specify a custom Cloud Storage path where the GPU driver is stored.
     * If not specified, we'll automatically choose from official GPU drivers.
     * 
* * string custom_gpu_driver_path = 12; * * @param value The customGpuDriverPath to set. * @return This builder for chaining. */ public Builder setCustomGpuDriverPath(java.lang.String value) { if (value == null) { throw new NullPointerException(); } customGpuDriverPath_ = value; bitField0_ |= 0x00001000; onChanged(); return this; } /** * * *
     * Specify a custom Cloud Storage path where the GPU driver is stored.
     * If not specified, we'll automatically choose from official GPU drivers.
     * 
* * string custom_gpu_driver_path = 12; * * @return This builder for chaining. */ public Builder clearCustomGpuDriverPath() { customGpuDriverPath_ = getDefaultInstance().getCustomGpuDriverPath(); bitField0_ = (bitField0_ & ~0x00001000); onChanged(); return this; } /** * * *
     * Specify a custom Cloud Storage path where the GPU driver is stored.
     * If not specified, we'll automatically choose from official GPU drivers.
     * 
* * string custom_gpu_driver_path = 12; * * @param value The bytes for customGpuDriverPath to set. * @return This builder for chaining. */ public Builder setCustomGpuDriverPathBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); customGpuDriverPath_ = value; bitField0_ |= 0x00001000; onChanged(); return this; } private int bootDiskType_ = 0; /** * * *
     * Input only. The type of the boot disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType boot_disk_type = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The enum numeric value on the wire for bootDiskType. */ @java.lang.Override public int getBootDiskTypeValue() { return bootDiskType_; } /** * * *
     * Input only. The type of the boot disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType boot_disk_type = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @param value The enum numeric value on the wire for bootDiskType to set. * @return This builder for chaining. */ public Builder setBootDiskTypeValue(int value) { bootDiskType_ = value; bitField0_ |= 0x00002000; onChanged(); return this; } /** * * *
     * Input only. The type of the boot disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType boot_disk_type = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The bootDiskType. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.DiskType getBootDiskType() { com.google.cloud.notebooks.v1.Instance.DiskType result = com.google.cloud.notebooks.v1.Instance.DiskType.forNumber(bootDiskType_); return result == null ? com.google.cloud.notebooks.v1.Instance.DiskType.UNRECOGNIZED : result; } /** * * *
     * Input only. The type of the boot disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType boot_disk_type = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @param value The bootDiskType to set. * @return This builder for chaining. */ public Builder setBootDiskType(com.google.cloud.notebooks.v1.Instance.DiskType value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00002000; bootDiskType_ = value.getNumber(); onChanged(); return this; } /** * * *
     * Input only. The type of the boot disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType boot_disk_type = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return This builder for chaining. */ public Builder clearBootDiskType() { bitField0_ = (bitField0_ & ~0x00002000); bootDiskType_ = 0; onChanged(); return this; } private long bootDiskSizeGb_; /** * * *
     * Input only. The size of the boot disk in GB attached to this instance, up to a maximum
     * of 64000 GB (64 TB). The minimum recommended value is 100 GB. If not
     * specified, this defaults to 100.
     * 
* * int64 boot_disk_size_gb = 14 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The bootDiskSizeGb. */ @java.lang.Override public long getBootDiskSizeGb() { return bootDiskSizeGb_; } /** * * *
     * Input only. The size of the boot disk in GB attached to this instance, up to a maximum
     * of 64000 GB (64 TB). The minimum recommended value is 100 GB. If not
     * specified, this defaults to 100.
     * 
* * int64 boot_disk_size_gb = 14 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The bootDiskSizeGb to set. * @return This builder for chaining. */ public Builder setBootDiskSizeGb(long value) { bootDiskSizeGb_ = value; bitField0_ |= 0x00004000; onChanged(); return this; } /** * * *
     * Input only. The size of the boot disk in GB attached to this instance, up to a maximum
     * of 64000 GB (64 TB). The minimum recommended value is 100 GB. If not
     * specified, this defaults to 100.
     * 
* * int64 boot_disk_size_gb = 14 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearBootDiskSizeGb() { bitField0_ = (bitField0_ & ~0x00004000); bootDiskSizeGb_ = 0L; onChanged(); return this; } private int dataDiskType_ = 0; /** * * *
     * Input only. The type of the data disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType data_disk_type = 25 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The enum numeric value on the wire for dataDiskType. */ @java.lang.Override public int getDataDiskTypeValue() { return dataDiskType_; } /** * * *
     * Input only. The type of the data disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType data_disk_type = 25 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @param value The enum numeric value on the wire for dataDiskType to set. * @return This builder for chaining. */ public Builder setDataDiskTypeValue(int value) { dataDiskType_ = value; bitField0_ |= 0x00008000; onChanged(); return this; } /** * * *
     * Input only. The type of the data disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType data_disk_type = 25 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The dataDiskType. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.DiskType getDataDiskType() { com.google.cloud.notebooks.v1.Instance.DiskType result = com.google.cloud.notebooks.v1.Instance.DiskType.forNumber(dataDiskType_); return result == null ? com.google.cloud.notebooks.v1.Instance.DiskType.UNRECOGNIZED : result; } /** * * *
     * Input only. The type of the data disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType data_disk_type = 25 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @param value The dataDiskType to set. * @return This builder for chaining. */ public Builder setDataDiskType(com.google.cloud.notebooks.v1.Instance.DiskType value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00008000; dataDiskType_ = value.getNumber(); onChanged(); return this; } /** * * *
     * Input only. The type of the data disk attached to this instance, defaults to
     * standard persistent disk (`PD_STANDARD`).
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskType data_disk_type = 25 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return This builder for chaining. */ public Builder clearDataDiskType() { bitField0_ = (bitField0_ & ~0x00008000); dataDiskType_ = 0; onChanged(); return this; } private long dataDiskSizeGb_; /** * * *
     * Input only. The size of the data disk in GB attached to this instance, up to a maximum
     * of 64000 GB (64 TB). You can choose the size of the data disk based on how
     * big your notebooks and data are. If not specified, this defaults to 100.
     * 
* * int64 data_disk_size_gb = 26 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The dataDiskSizeGb. */ @java.lang.Override public long getDataDiskSizeGb() { return dataDiskSizeGb_; } /** * * *
     * Input only. The size of the data disk in GB attached to this instance, up to a maximum
     * of 64000 GB (64 TB). You can choose the size of the data disk based on how
     * big your notebooks and data are. If not specified, this defaults to 100.
     * 
* * int64 data_disk_size_gb = 26 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The dataDiskSizeGb to set. * @return This builder for chaining. */ public Builder setDataDiskSizeGb(long value) { dataDiskSizeGb_ = value; bitField0_ |= 0x00010000; onChanged(); return this; } /** * * *
     * Input only. The size of the data disk in GB attached to this instance, up to a maximum
     * of 64000 GB (64 TB). You can choose the size of the data disk based on how
     * big your notebooks and data are. If not specified, this defaults to 100.
     * 
* * int64 data_disk_size_gb = 26 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearDataDiskSizeGb() { bitField0_ = (bitField0_ & ~0x00010000); dataDiskSizeGb_ = 0L; onChanged(); return this; } private boolean noRemoveDataDisk_; /** * * *
     * Input only. If true, the data disk will not be auto deleted when deleting the instance.
     * 
* * bool no_remove_data_disk = 27 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The noRemoveDataDisk. */ @java.lang.Override public boolean getNoRemoveDataDisk() { return noRemoveDataDisk_; } /** * * *
     * Input only. If true, the data disk will not be auto deleted when deleting the instance.
     * 
* * bool no_remove_data_disk = 27 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The noRemoveDataDisk to set. * @return This builder for chaining. */ public Builder setNoRemoveDataDisk(boolean value) { noRemoveDataDisk_ = value; bitField0_ |= 0x00020000; onChanged(); return this; } /** * * *
     * Input only. If true, the data disk will not be auto deleted when deleting the instance.
     * 
* * bool no_remove_data_disk = 27 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearNoRemoveDataDisk() { bitField0_ = (bitField0_ & ~0x00020000); noRemoveDataDisk_ = false; onChanged(); return this; } private int diskEncryption_ = 0; /** * * *
     * Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskEncryption disk_encryption = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The enum numeric value on the wire for diskEncryption. */ @java.lang.Override public int getDiskEncryptionValue() { return diskEncryption_; } /** * * *
     * Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskEncryption disk_encryption = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @param value The enum numeric value on the wire for diskEncryption to set. * @return This builder for chaining. */ public Builder setDiskEncryptionValue(int value) { diskEncryption_ = value; bitField0_ |= 0x00040000; onChanged(); return this; } /** * * *
     * Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskEncryption disk_encryption = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The diskEncryption. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.DiskEncryption getDiskEncryption() { com.google.cloud.notebooks.v1.Instance.DiskEncryption result = com.google.cloud.notebooks.v1.Instance.DiskEncryption.forNumber(diskEncryption_); return result == null ? com.google.cloud.notebooks.v1.Instance.DiskEncryption.UNRECOGNIZED : result; } /** * * *
     * Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskEncryption disk_encryption = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @param value The diskEncryption to set. * @return This builder for chaining. */ public Builder setDiskEncryption(com.google.cloud.notebooks.v1.Instance.DiskEncryption value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00040000; diskEncryption_ = value.getNumber(); onChanged(); return this; } /** * * *
     * Input only. Disk encryption method used on the boot and data disks, defaults to GMEK.
     * 
* * * .google.cloud.notebooks.v1.Instance.DiskEncryption disk_encryption = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return This builder for chaining. */ public Builder clearDiskEncryption() { bitField0_ = (bitField0_ & ~0x00040000); diskEncryption_ = 0; onChanged(); return this; } private java.lang.Object kmsKey_ = ""; /** * * *
     * Input only. The KMS key used to encrypt the disks, only applicable if disk_encryption
     * is CMEK.
     * Format:
     * `projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}`
     *
     * Learn more about [using your own encryption keys](/kms/docs/quickstart).
     * 
* * string kms_key = 16 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The kmsKey. */ public java.lang.String getKmsKey() { java.lang.Object ref = kmsKey_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); kmsKey_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Input only. The KMS key used to encrypt the disks, only applicable if disk_encryption
     * is CMEK.
     * Format:
     * `projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}`
     *
     * Learn more about [using your own encryption keys](/kms/docs/quickstart).
     * 
* * string kms_key = 16 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The bytes for kmsKey. */ public com.google.protobuf.ByteString getKmsKeyBytes() { java.lang.Object ref = kmsKey_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); kmsKey_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Input only. The KMS key used to encrypt the disks, only applicable if disk_encryption
     * is CMEK.
     * Format:
     * `projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}`
     *
     * Learn more about [using your own encryption keys](/kms/docs/quickstart).
     * 
* * string kms_key = 16 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The kmsKey to set. * @return This builder for chaining. */ public Builder setKmsKey(java.lang.String value) { if (value == null) { throw new NullPointerException(); } kmsKey_ = value; bitField0_ |= 0x00080000; onChanged(); return this; } /** * * *
     * Input only. The KMS key used to encrypt the disks, only applicable if disk_encryption
     * is CMEK.
     * Format:
     * `projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}`
     *
     * Learn more about [using your own encryption keys](/kms/docs/quickstart).
     * 
* * string kms_key = 16 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearKmsKey() { kmsKey_ = getDefaultInstance().getKmsKey(); bitField0_ = (bitField0_ & ~0x00080000); onChanged(); return this; } /** * * *
     * Input only. The KMS key used to encrypt the disks, only applicable if disk_encryption
     * is CMEK.
     * Format:
     * `projects/{project_id}/locations/{location}/keyRings/{key_ring_id}/cryptoKeys/{key_id}`
     *
     * Learn more about [using your own encryption keys](/kms/docs/quickstart).
     * 
* * string kms_key = 16 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The bytes for kmsKey to set. * @return This builder for chaining. */ public Builder setKmsKeyBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); kmsKey_ = value; bitField0_ |= 0x00080000; onChanged(); return this; } private java.util.List disks_ = java.util.Collections.emptyList(); private void ensureDisksIsMutable() { if (!((bitField0_ & 0x00100000) != 0)) { disks_ = new java.util.ArrayList(disks_); bitField0_ |= 0x00100000; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.Disk, com.google.cloud.notebooks.v1.Instance.Disk.Builder, com.google.cloud.notebooks.v1.Instance.DiskOrBuilder> disksBuilder_; /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List getDisksList() { if (disksBuilder_ == null) { return java.util.Collections.unmodifiableList(disks_); } else { return disksBuilder_.getMessageList(); } } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public int getDisksCount() { if (disksBuilder_ == null) { return disks_.size(); } else { return disksBuilder_.getCount(); } } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.notebooks.v1.Instance.Disk getDisks(int index) { if (disksBuilder_ == null) { return disks_.get(index); } else { return disksBuilder_.getMessage(index); } } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setDisks(int index, com.google.cloud.notebooks.v1.Instance.Disk value) { if (disksBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureDisksIsMutable(); disks_.set(index, value); onChanged(); } else { disksBuilder_.setMessage(index, value); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setDisks( int index, com.google.cloud.notebooks.v1.Instance.Disk.Builder builderForValue) { if (disksBuilder_ == null) { ensureDisksIsMutable(); disks_.set(index, builderForValue.build()); onChanged(); } else { disksBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addDisks(com.google.cloud.notebooks.v1.Instance.Disk value) { if (disksBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureDisksIsMutable(); disks_.add(value); onChanged(); } else { disksBuilder_.addMessage(value); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addDisks(int index, com.google.cloud.notebooks.v1.Instance.Disk value) { if (disksBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureDisksIsMutable(); disks_.add(index, value); onChanged(); } else { disksBuilder_.addMessage(index, value); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addDisks(com.google.cloud.notebooks.v1.Instance.Disk.Builder builderForValue) { if (disksBuilder_ == null) { ensureDisksIsMutable(); disks_.add(builderForValue.build()); onChanged(); } else { disksBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addDisks( int index, com.google.cloud.notebooks.v1.Instance.Disk.Builder builderForValue) { if (disksBuilder_ == null) { ensureDisksIsMutable(); disks_.add(index, builderForValue.build()); onChanged(); } else { disksBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addAllDisks( java.lang.Iterable values) { if (disksBuilder_ == null) { ensureDisksIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, disks_); onChanged(); } else { disksBuilder_.addAllMessages(values); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder clearDisks() { if (disksBuilder_ == null) { disks_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00100000); onChanged(); } else { disksBuilder_.clear(); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder removeDisks(int index) { if (disksBuilder_ == null) { ensureDisksIsMutable(); disks_.remove(index); onChanged(); } else { disksBuilder_.remove(index); } return this; } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.notebooks.v1.Instance.Disk.Builder getDisksBuilder(int index) { return getDisksFieldBuilder().getBuilder(index); } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.notebooks.v1.Instance.DiskOrBuilder getDisksOrBuilder(int index) { if (disksBuilder_ == null) { return disks_.get(index); } else { return disksBuilder_.getMessageOrBuilder(index); } } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List getDisksOrBuilderList() { if (disksBuilder_ != null) { return disksBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(disks_); } } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.notebooks.v1.Instance.Disk.Builder addDisksBuilder() { return getDisksFieldBuilder() .addBuilder(com.google.cloud.notebooks.v1.Instance.Disk.getDefaultInstance()); } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.notebooks.v1.Instance.Disk.Builder addDisksBuilder(int index) { return getDisksFieldBuilder() .addBuilder(index, com.google.cloud.notebooks.v1.Instance.Disk.getDefaultInstance()); } /** * * *
     * Output only. Attached disks to notebook instance.
     * 
* * * repeated .google.cloud.notebooks.v1.Instance.Disk disks = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List getDisksBuilderList() { return getDisksFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.Disk, com.google.cloud.notebooks.v1.Instance.Disk.Builder, com.google.cloud.notebooks.v1.Instance.DiskOrBuilder> getDisksFieldBuilder() { if (disksBuilder_ == null) { disksBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.Disk, com.google.cloud.notebooks.v1.Instance.Disk.Builder, com.google.cloud.notebooks.v1.Instance.DiskOrBuilder>( disks_, ((bitField0_ & 0x00100000) != 0), getParentForChildren(), isClean()); disks_ = null; } return disksBuilder_; } private com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shieldedInstanceConfig_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig, com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.Builder, com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfigOrBuilder> shieldedInstanceConfigBuilder_; /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * * * @return Whether the shieldedInstanceConfig field is set. */ public boolean hasShieldedInstanceConfig() { return ((bitField0_ & 0x00200000) != 0); } /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The shieldedInstanceConfig. */ public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig getShieldedInstanceConfig() { if (shieldedInstanceConfigBuilder_ == null) { return shieldedInstanceConfig_ == null ? com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.getDefaultInstance() : shieldedInstanceConfig_; } else { return shieldedInstanceConfigBuilder_.getMessage(); } } /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * */ public Builder setShieldedInstanceConfig( com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig value) { if (shieldedInstanceConfigBuilder_ == null) { if (value == null) { throw new NullPointerException(); } shieldedInstanceConfig_ = value; } else { shieldedInstanceConfigBuilder_.setMessage(value); } bitField0_ |= 0x00200000; onChanged(); return this; } /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * */ public Builder setShieldedInstanceConfig( com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.Builder builderForValue) { if (shieldedInstanceConfigBuilder_ == null) { shieldedInstanceConfig_ = builderForValue.build(); } else { shieldedInstanceConfigBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00200000; onChanged(); return this; } /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * */ public Builder mergeShieldedInstanceConfig( com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig value) { if (shieldedInstanceConfigBuilder_ == null) { if (((bitField0_ & 0x00200000) != 0) && shieldedInstanceConfig_ != null && shieldedInstanceConfig_ != com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig .getDefaultInstance()) { getShieldedInstanceConfigBuilder().mergeFrom(value); } else { shieldedInstanceConfig_ = value; } } else { shieldedInstanceConfigBuilder_.mergeFrom(value); } if (shieldedInstanceConfig_ != null) { bitField0_ |= 0x00200000; onChanged(); } return this; } /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * */ public Builder clearShieldedInstanceConfig() { bitField0_ = (bitField0_ & ~0x00200000); shieldedInstanceConfig_ = null; if (shieldedInstanceConfigBuilder_ != null) { shieldedInstanceConfigBuilder_.dispose(); shieldedInstanceConfigBuilder_ = null; } onChanged(); return this; } /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * */ public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.Builder getShieldedInstanceConfigBuilder() { bitField0_ |= 0x00200000; onChanged(); return getShieldedInstanceConfigFieldBuilder().getBuilder(); } /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * */ public com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfigOrBuilder getShieldedInstanceConfigOrBuilder() { if (shieldedInstanceConfigBuilder_ != null) { return shieldedInstanceConfigBuilder_.getMessageOrBuilder(); } else { return shieldedInstanceConfig_ == null ? com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.getDefaultInstance() : shieldedInstanceConfig_; } } /** * * *
     * Optional. Shielded VM configuration.
     * [Images using supported Shielded VM
     * features](https://cloud.google.com/compute/docs/instances/modifying-shielded-vm).
     * 
* * * .google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig shielded_instance_config = 30 [(.google.api.field_behavior) = OPTIONAL]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig, com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.Builder, com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfigOrBuilder> getShieldedInstanceConfigFieldBuilder() { if (shieldedInstanceConfigBuilder_ == null) { shieldedInstanceConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig, com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfig.Builder, com.google.cloud.notebooks.v1.Instance.ShieldedInstanceConfigOrBuilder>( getShieldedInstanceConfig(), getParentForChildren(), isClean()); shieldedInstanceConfig_ = null; } return shieldedInstanceConfigBuilder_; } private boolean noPublicIp_; /** * * *
     * If true, no public IP will be assigned to this instance.
     * 
* * bool no_public_ip = 17; * * @return The noPublicIp. */ @java.lang.Override public boolean getNoPublicIp() { return noPublicIp_; } /** * * *
     * If true, no public IP will be assigned to this instance.
     * 
* * bool no_public_ip = 17; * * @param value The noPublicIp to set. * @return This builder for chaining. */ public Builder setNoPublicIp(boolean value) { noPublicIp_ = value; bitField0_ |= 0x00400000; onChanged(); return this; } /** * * *
     * If true, no public IP will be assigned to this instance.
     * 
* * bool no_public_ip = 17; * * @return This builder for chaining. */ public Builder clearNoPublicIp() { bitField0_ = (bitField0_ & ~0x00400000); noPublicIp_ = false; onChanged(); return this; } private boolean noProxyAccess_; /** * * *
     * If true, the notebook instance will not register with the proxy.
     * 
* * bool no_proxy_access = 18; * * @return The noProxyAccess. */ @java.lang.Override public boolean getNoProxyAccess() { return noProxyAccess_; } /** * * *
     * If true, the notebook instance will not register with the proxy.
     * 
* * bool no_proxy_access = 18; * * @param value The noProxyAccess to set. * @return This builder for chaining. */ public Builder setNoProxyAccess(boolean value) { noProxyAccess_ = value; bitField0_ |= 0x00800000; onChanged(); return this; } /** * * *
     * If true, the notebook instance will not register with the proxy.
     * 
* * bool no_proxy_access = 18; * * @return This builder for chaining. */ public Builder clearNoProxyAccess() { bitField0_ = (bitField0_ & ~0x00800000); noProxyAccess_ = false; onChanged(); return this; } private java.lang.Object network_ = ""; /** * * *
     * The name of the VPC that this instance is in.
     * Format:
     * `projects/{project_id}/global/networks/{network_id}`
     * 
* * string network = 19; * * @return The network. */ public java.lang.String getNetwork() { java.lang.Object ref = network_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); network_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * The name of the VPC that this instance is in.
     * Format:
     * `projects/{project_id}/global/networks/{network_id}`
     * 
* * string network = 19; * * @return The bytes for network. */ public com.google.protobuf.ByteString getNetworkBytes() { java.lang.Object ref = network_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); network_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * The name of the VPC that this instance is in.
     * Format:
     * `projects/{project_id}/global/networks/{network_id}`
     * 
* * string network = 19; * * @param value The network to set. * @return This builder for chaining. */ public Builder setNetwork(java.lang.String value) { if (value == null) { throw new NullPointerException(); } network_ = value; bitField0_ |= 0x01000000; onChanged(); return this; } /** * * *
     * The name of the VPC that this instance is in.
     * Format:
     * `projects/{project_id}/global/networks/{network_id}`
     * 
* * string network = 19; * * @return This builder for chaining. */ public Builder clearNetwork() { network_ = getDefaultInstance().getNetwork(); bitField0_ = (bitField0_ & ~0x01000000); onChanged(); return this; } /** * * *
     * The name of the VPC that this instance is in.
     * Format:
     * `projects/{project_id}/global/networks/{network_id}`
     * 
* * string network = 19; * * @param value The bytes for network to set. * @return This builder for chaining. */ public Builder setNetworkBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); network_ = value; bitField0_ |= 0x01000000; onChanged(); return this; } private java.lang.Object subnet_ = ""; /** * * *
     * The name of the subnet that this instance is in.
     * Format:
     * `projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}`
     * 
* * string subnet = 20; * * @return The subnet. */ public java.lang.String getSubnet() { java.lang.Object ref = subnet_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); subnet_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * The name of the subnet that this instance is in.
     * Format:
     * `projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}`
     * 
* * string subnet = 20; * * @return The bytes for subnet. */ public com.google.protobuf.ByteString getSubnetBytes() { java.lang.Object ref = subnet_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); subnet_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * The name of the subnet that this instance is in.
     * Format:
     * `projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}`
     * 
* * string subnet = 20; * * @param value The subnet to set. * @return This builder for chaining. */ public Builder setSubnet(java.lang.String value) { if (value == null) { throw new NullPointerException(); } subnet_ = value; bitField0_ |= 0x02000000; onChanged(); return this; } /** * * *
     * The name of the subnet that this instance is in.
     * Format:
     * `projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}`
     * 
* * string subnet = 20; * * @return This builder for chaining. */ public Builder clearSubnet() { subnet_ = getDefaultInstance().getSubnet(); bitField0_ = (bitField0_ & ~0x02000000); onChanged(); return this; } /** * * *
     * The name of the subnet that this instance is in.
     * Format:
     * `projects/{project_id}/regions/{region}/subnetworks/{subnetwork_id}`
     * 
* * string subnet = 20; * * @param value The bytes for subnet to set. * @return This builder for chaining. */ public Builder setSubnetBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); subnet_ = value; bitField0_ |= 0x02000000; onChanged(); return this; } private com.google.protobuf.MapField labels_; private com.google.protobuf.MapField internalGetLabels() { if (labels_ == null) { return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); } return labels_; } private com.google.protobuf.MapField internalGetMutableLabels() { if (labels_ == null) { labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); } if (!labels_.isMutable()) { labels_ = labels_.copy(); } bitField0_ |= 0x04000000; onChanged(); return labels_; } public int getLabelsCount() { return internalGetLabels().getMap().size(); } /** * * *
     * Labels to apply to this instance.
     * These can be later modified by the setLabels method.
     * 
* * map<string, string> labels = 21; */ @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); } /** * * *
     * Labels to apply to this instance.
     * These can be later modified by the setLabels method.
     * 
* * map<string, string> labels = 21; */ @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } /** * * *
     * Labels to apply to this instance.
     * These can be later modified by the setLabels method.
     * 
* * map<string, string> labels = 21; */ @java.lang.Override public /* nullable */ java.lang.String getLabelsOrDefault( java.lang.String key, /* nullable */ java.lang.String defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetLabels().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** * * *
     * Labels to apply to this instance.
     * These can be later modified by the setLabels method.
     * 
* * map<string, string> labels = 21; */ @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetLabels().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public Builder clearLabels() { bitField0_ = (bitField0_ & ~0x04000000); internalGetMutableLabels().getMutableMap().clear(); return this; } /** * * *
     * Labels to apply to this instance.
     * These can be later modified by the setLabels method.
     * 
* * map<string, string> labels = 21; */ public Builder removeLabels(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableLabels().getMutableMap().remove(key); return this; } /** Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableLabels() { bitField0_ |= 0x04000000; return internalGetMutableLabels().getMutableMap(); } /** * * *
     * Labels to apply to this instance.
     * These can be later modified by the setLabels method.
     * 
* * map<string, string> labels = 21; */ public Builder putLabels(java.lang.String key, java.lang.String value) { if (key == null) { throw new NullPointerException("map key"); } if (value == null) { throw new NullPointerException("map value"); } internalGetMutableLabels().getMutableMap().put(key, value); bitField0_ |= 0x04000000; return this; } /** * * *
     * Labels to apply to this instance.
     * These can be later modified by the setLabels method.
     * 
* * map<string, string> labels = 21; */ public Builder putAllLabels(java.util.Map values) { internalGetMutableLabels().getMutableMap().putAll(values); bitField0_ |= 0x04000000; return this; } private com.google.protobuf.MapField metadata_; private com.google.protobuf.MapField internalGetMetadata() { if (metadata_ == null) { return com.google.protobuf.MapField.emptyMapField(MetadataDefaultEntryHolder.defaultEntry); } return metadata_; } private com.google.protobuf.MapField internalGetMutableMetadata() { if (metadata_ == null) { metadata_ = com.google.protobuf.MapField.newMapField(MetadataDefaultEntryHolder.defaultEntry); } if (!metadata_.isMutable()) { metadata_ = metadata_.copy(); } bitField0_ |= 0x08000000; onChanged(); return metadata_; } public int getMetadataCount() { return internalGetMetadata().getMap().size(); } /** * * *
     * Custom metadata to apply to this instance.
     * 
* * map<string, string> metadata = 22; */ @java.lang.Override public boolean containsMetadata(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetMetadata().getMap().containsKey(key); } /** Use {@link #getMetadataMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getMetadata() { return getMetadataMap(); } /** * * *
     * Custom metadata to apply to this instance.
     * 
* * map<string, string> metadata = 22; */ @java.lang.Override public java.util.Map getMetadataMap() { return internalGetMetadata().getMap(); } /** * * *
     * Custom metadata to apply to this instance.
     * 
* * map<string, string> metadata = 22; */ @java.lang.Override public /* nullable */ java.lang.String getMetadataOrDefault( java.lang.String key, /* nullable */ java.lang.String defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetMetadata().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** * * *
     * Custom metadata to apply to this instance.
     * 
* * map<string, string> metadata = 22; */ @java.lang.Override public java.lang.String getMetadataOrThrow(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetMetadata().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public Builder clearMetadata() { bitField0_ = (bitField0_ & ~0x08000000); internalGetMutableMetadata().getMutableMap().clear(); return this; } /** * * *
     * Custom metadata to apply to this instance.
     * 
* * map<string, string> metadata = 22; */ public Builder removeMetadata(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableMetadata().getMutableMap().remove(key); return this; } /** Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableMetadata() { bitField0_ |= 0x08000000; return internalGetMutableMetadata().getMutableMap(); } /** * * *
     * Custom metadata to apply to this instance.
     * 
* * map<string, string> metadata = 22; */ public Builder putMetadata(java.lang.String key, java.lang.String value) { if (key == null) { throw new NullPointerException("map key"); } if (value == null) { throw new NullPointerException("map value"); } internalGetMutableMetadata().getMutableMap().put(key, value); bitField0_ |= 0x08000000; return this; } /** * * *
     * Custom metadata to apply to this instance.
     * 
* * map<string, string> metadata = 22; */ public Builder putAllMetadata(java.util.Map values) { internalGetMutableMetadata().getMutableMap().putAll(values); bitField0_ |= 0x08000000; return this; } private com.google.protobuf.LazyStringArrayList tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); private void ensureTagsIsMutable() { if (!tags_.isModifiable()) { tags_ = new com.google.protobuf.LazyStringArrayList(tags_); } bitField0_ |= 0x10000000; } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @return A list containing the tags. */ public com.google.protobuf.ProtocolStringList getTagsList() { tags_.makeImmutable(); return tags_; } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @return The count of tags. */ public int getTagsCount() { return tags_.size(); } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @param index The index of the element to return. * @return The tags at the given index. */ public java.lang.String getTags(int index) { return tags_.get(index); } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @param index The index of the value to return. * @return The bytes of the tags at the given index. */ public com.google.protobuf.ByteString getTagsBytes(int index) { return tags_.getByteString(index); } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @param index The index to set the value at. * @param value The tags to set. * @return This builder for chaining. */ public Builder setTags(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureTagsIsMutable(); tags_.set(index, value); bitField0_ |= 0x10000000; onChanged(); return this; } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The tags to add. * @return This builder for chaining. */ public Builder addTags(java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureTagsIsMutable(); tags_.add(value); bitField0_ |= 0x10000000; onChanged(); return this; } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @param values The tags to add. * @return This builder for chaining. */ public Builder addAllTags(java.lang.Iterable values) { ensureTagsIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tags_); bitField0_ |= 0x10000000; onChanged(); return this; } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @return This builder for chaining. */ public Builder clearTags() { tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); bitField0_ = (bitField0_ & ~0x10000000); ; onChanged(); return this; } /** * * *
     * Optional. The Compute Engine tags to add to runtime (see [Tagging
     * instances](https://cloud.google.com/compute/docs/label-or-tag-resources#tags)).
     * 
* * repeated string tags = 32 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The bytes of the tags to add. * @return This builder for chaining. */ public Builder addTagsBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); ensureTagsIsMutable(); tags_.add(value); bitField0_ |= 0x10000000; onChanged(); return this; } private java.util.List upgradeHistory_ = java.util.Collections.emptyList(); private void ensureUpgradeHistoryIsMutable() { if (!((bitField0_ & 0x20000000) != 0)) { upgradeHistory_ = new java.util.ArrayList( upgradeHistory_); bitField0_ |= 0x20000000; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntryOrBuilder> upgradeHistoryBuilder_; /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public java.util.List getUpgradeHistoryList() { if (upgradeHistoryBuilder_ == null) { return java.util.Collections.unmodifiableList(upgradeHistory_); } else { return upgradeHistoryBuilder_.getMessageList(); } } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public int getUpgradeHistoryCount() { if (upgradeHistoryBuilder_ == null) { return upgradeHistory_.size(); } else { return upgradeHistoryBuilder_.getCount(); } } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry getUpgradeHistory(int index) { if (upgradeHistoryBuilder_ == null) { return upgradeHistory_.get(index); } else { return upgradeHistoryBuilder_.getMessage(index); } } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder setUpgradeHistory( int index, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry value) { if (upgradeHistoryBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureUpgradeHistoryIsMutable(); upgradeHistory_.set(index, value); onChanged(); } else { upgradeHistoryBuilder_.setMessage(index, value); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder setUpgradeHistory( int index, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder builderForValue) { if (upgradeHistoryBuilder_ == null) { ensureUpgradeHistoryIsMutable(); upgradeHistory_.set(index, builderForValue.build()); onChanged(); } else { upgradeHistoryBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder addUpgradeHistory( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry value) { if (upgradeHistoryBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureUpgradeHistoryIsMutable(); upgradeHistory_.add(value); onChanged(); } else { upgradeHistoryBuilder_.addMessage(value); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder addUpgradeHistory( int index, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry value) { if (upgradeHistoryBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureUpgradeHistoryIsMutable(); upgradeHistory_.add(index, value); onChanged(); } else { upgradeHistoryBuilder_.addMessage(index, value); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder addUpgradeHistory( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder builderForValue) { if (upgradeHistoryBuilder_ == null) { ensureUpgradeHistoryIsMutable(); upgradeHistory_.add(builderForValue.build()); onChanged(); } else { upgradeHistoryBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder addUpgradeHistory( int index, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder builderForValue) { if (upgradeHistoryBuilder_ == null) { ensureUpgradeHistoryIsMutable(); upgradeHistory_.add(index, builderForValue.build()); onChanged(); } else { upgradeHistoryBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder addAllUpgradeHistory( java.lang.Iterable values) { if (upgradeHistoryBuilder_ == null) { ensureUpgradeHistoryIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, upgradeHistory_); onChanged(); } else { upgradeHistoryBuilder_.addAllMessages(values); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder clearUpgradeHistory() { if (upgradeHistoryBuilder_ == null) { upgradeHistory_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x20000000); onChanged(); } else { upgradeHistoryBuilder_.clear(); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public Builder removeUpgradeHistory(int index) { if (upgradeHistoryBuilder_ == null) { ensureUpgradeHistoryIsMutable(); upgradeHistory_.remove(index); onChanged(); } else { upgradeHistoryBuilder_.remove(index); } return this; } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder getUpgradeHistoryBuilder(int index) { return getUpgradeHistoryFieldBuilder().getBuilder(index); } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntryOrBuilder getUpgradeHistoryOrBuilder(int index) { if (upgradeHistoryBuilder_ == null) { return upgradeHistory_.get(index); } else { return upgradeHistoryBuilder_.getMessageOrBuilder(index); } } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public java.util.List< ? extends com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntryOrBuilder> getUpgradeHistoryOrBuilderList() { if (upgradeHistoryBuilder_ != null) { return upgradeHistoryBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(upgradeHistory_); } } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder addUpgradeHistoryBuilder() { return getUpgradeHistoryFieldBuilder() .addBuilder( com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.getDefaultInstance()); } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder addUpgradeHistoryBuilder(int index) { return getUpgradeHistoryFieldBuilder() .addBuilder( index, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.getDefaultInstance()); } /** * * *
     * The upgrade history of this instance.
     * 
* * repeated .google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry upgrade_history = 29; * */ public java.util.List getUpgradeHistoryBuilderList() { return getUpgradeHistoryFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntryOrBuilder> getUpgradeHistoryFieldBuilder() { if (upgradeHistoryBuilder_ == null) { upgradeHistoryBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntry.Builder, com.google.cloud.notebooks.v1.Instance.UpgradeHistoryEntryOrBuilder>( upgradeHistory_, ((bitField0_ & 0x20000000) != 0), getParentForChildren(), isClean()); upgradeHistory_ = null; } return upgradeHistoryBuilder_; } private int nicType_ = 0; /** * * *
     * Optional. The type of vNIC to be used on this interface. This may be gVNIC or
     * VirtioNet.
     * 
* * * .google.cloud.notebooks.v1.Instance.NicType nic_type = 33 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The enum numeric value on the wire for nicType. */ @java.lang.Override public int getNicTypeValue() { return nicType_; } /** * * *
     * Optional. The type of vNIC to be used on this interface. This may be gVNIC or
     * VirtioNet.
     * 
* * * .google.cloud.notebooks.v1.Instance.NicType nic_type = 33 [(.google.api.field_behavior) = OPTIONAL]; * * * @param value The enum numeric value on the wire for nicType to set. * @return This builder for chaining. */ public Builder setNicTypeValue(int value) { nicType_ = value; bitField0_ |= 0x40000000; onChanged(); return this; } /** * * *
     * Optional. The type of vNIC to be used on this interface. This may be gVNIC or
     * VirtioNet.
     * 
* * * .google.cloud.notebooks.v1.Instance.NicType nic_type = 33 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The nicType. */ @java.lang.Override public com.google.cloud.notebooks.v1.Instance.NicType getNicType() { com.google.cloud.notebooks.v1.Instance.NicType result = com.google.cloud.notebooks.v1.Instance.NicType.forNumber(nicType_); return result == null ? com.google.cloud.notebooks.v1.Instance.NicType.UNRECOGNIZED : result; } /** * * *
     * Optional. The type of vNIC to be used on this interface. This may be gVNIC or
     * VirtioNet.
     * 
* * * .google.cloud.notebooks.v1.Instance.NicType nic_type = 33 [(.google.api.field_behavior) = OPTIONAL]; * * * @param value The nicType to set. * @return This builder for chaining. */ public Builder setNicType(com.google.cloud.notebooks.v1.Instance.NicType value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x40000000; nicType_ = value.getNumber(); onChanged(); return this; } /** * * *
     * Optional. The type of vNIC to be used on this interface. This may be gVNIC or
     * VirtioNet.
     * 
* * * .google.cloud.notebooks.v1.Instance.NicType nic_type = 33 [(.google.api.field_behavior) = OPTIONAL]; * * * @return This builder for chaining. */ public Builder clearNicType() { bitField0_ = (bitField0_ & ~0x40000000); nicType_ = 0; onChanged(); return this; } private com.google.cloud.notebooks.v1.ReservationAffinity reservationAffinity_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.ReservationAffinity, com.google.cloud.notebooks.v1.ReservationAffinity.Builder, com.google.cloud.notebooks.v1.ReservationAffinityOrBuilder> reservationAffinityBuilder_; /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * * * @return Whether the reservationAffinity field is set. */ public boolean hasReservationAffinity() { return ((bitField0_ & 0x80000000) != 0); } /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The reservationAffinity. */ public com.google.cloud.notebooks.v1.ReservationAffinity getReservationAffinity() { if (reservationAffinityBuilder_ == null) { return reservationAffinity_ == null ? com.google.cloud.notebooks.v1.ReservationAffinity.getDefaultInstance() : reservationAffinity_; } else { return reservationAffinityBuilder_.getMessage(); } } /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * */ public Builder setReservationAffinity(com.google.cloud.notebooks.v1.ReservationAffinity value) { if (reservationAffinityBuilder_ == null) { if (value == null) { throw new NullPointerException(); } reservationAffinity_ = value; } else { reservationAffinityBuilder_.setMessage(value); } bitField0_ |= 0x80000000; onChanged(); return this; } /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * */ public Builder setReservationAffinity( com.google.cloud.notebooks.v1.ReservationAffinity.Builder builderForValue) { if (reservationAffinityBuilder_ == null) { reservationAffinity_ = builderForValue.build(); } else { reservationAffinityBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x80000000; onChanged(); return this; } /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * */ public Builder mergeReservationAffinity( com.google.cloud.notebooks.v1.ReservationAffinity value) { if (reservationAffinityBuilder_ == null) { if (((bitField0_ & 0x80000000) != 0) && reservationAffinity_ != null && reservationAffinity_ != com.google.cloud.notebooks.v1.ReservationAffinity.getDefaultInstance()) { getReservationAffinityBuilder().mergeFrom(value); } else { reservationAffinity_ = value; } } else { reservationAffinityBuilder_.mergeFrom(value); } if (reservationAffinity_ != null) { bitField0_ |= 0x80000000; onChanged(); } return this; } /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * */ public Builder clearReservationAffinity() { bitField0_ = (bitField0_ & ~0x80000000); reservationAffinity_ = null; if (reservationAffinityBuilder_ != null) { reservationAffinityBuilder_.dispose(); reservationAffinityBuilder_ = null; } onChanged(); return this; } /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * */ public com.google.cloud.notebooks.v1.ReservationAffinity.Builder getReservationAffinityBuilder() { bitField0_ |= 0x80000000; onChanged(); return getReservationAffinityFieldBuilder().getBuilder(); } /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * */ public com.google.cloud.notebooks.v1.ReservationAffinityOrBuilder getReservationAffinityOrBuilder() { if (reservationAffinityBuilder_ != null) { return reservationAffinityBuilder_.getMessageOrBuilder(); } else { return reservationAffinity_ == null ? com.google.cloud.notebooks.v1.ReservationAffinity.getDefaultInstance() : reservationAffinity_; } } /** * * *
     * Optional. The optional reservation affinity. Setting this field will apply
     * the specified [Zonal Compute
     * Reservation](https://cloud.google.com/compute/docs/instances/reserving-zonal-resources)
     * to this notebook instance.
     * 
* * * .google.cloud.notebooks.v1.ReservationAffinity reservation_affinity = 34 [(.google.api.field_behavior) = OPTIONAL]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.ReservationAffinity, com.google.cloud.notebooks.v1.ReservationAffinity.Builder, com.google.cloud.notebooks.v1.ReservationAffinityOrBuilder> getReservationAffinityFieldBuilder() { if (reservationAffinityBuilder_ == null) { reservationAffinityBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.notebooks.v1.ReservationAffinity, com.google.cloud.notebooks.v1.ReservationAffinity.Builder, com.google.cloud.notebooks.v1.ReservationAffinityOrBuilder>( getReservationAffinity(), getParentForChildren(), isClean()); reservationAffinity_ = null; } return reservationAffinityBuilder_; } private java.lang.Object creator_ = ""; /** * * *
     * Output only. Email address of entity that sent original CreateInstance request.
     * 
* * string creator = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The creator. */ public java.lang.String getCreator() { java.lang.Object ref = creator_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); creator_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Output only. Email address of entity that sent original CreateInstance request.
     * 
* * string creator = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for creator. */ public com.google.protobuf.ByteString getCreatorBytes() { java.lang.Object ref = creator_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); creator_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Output only. Email address of entity that sent original CreateInstance request.
     * 
* * string creator = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The creator to set. * @return This builder for chaining. */ public Builder setCreator(java.lang.String value) { if (value == null) { throw new NullPointerException(); } creator_ = value; bitField1_ |= 0x00000001; onChanged(); return this; } /** * * *
     * Output only. Email address of entity that sent original CreateInstance request.
     * 
* * string creator = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearCreator() { creator_ = getDefaultInstance().getCreator(); bitField1_ = (bitField1_ & ~0x00000001); onChanged(); return this; } /** * * *
     * Output only. Email address of entity that sent original CreateInstance request.
     * 
* * string creator = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for creator to set. * @return This builder for chaining. */ public Builder setCreatorBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); creator_ = value; bitField1_ |= 0x00000001; onChanged(); return this; } private boolean canIpForward_; /** * * *
     * Optional. Flag to enable ip forwarding or not, default false/off.
     * https://cloud.google.com/vpc/docs/using-routes#canipforward
     * 
* * bool can_ip_forward = 39 [(.google.api.field_behavior) = OPTIONAL]; * * @return The canIpForward. */ @java.lang.Override public boolean getCanIpForward() { return canIpForward_; } /** * * *
     * Optional. Flag to enable ip forwarding or not, default false/off.
     * https://cloud.google.com/vpc/docs/using-routes#canipforward
     * 
* * bool can_ip_forward = 39 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The canIpForward to set. * @return This builder for chaining. */ public Builder setCanIpForward(boolean value) { canIpForward_ = value; bitField1_ |= 0x00000002; onChanged(); return this; } /** * * *
     * Optional. Flag to enable ip forwarding or not, default false/off.
     * https://cloud.google.com/vpc/docs/using-routes#canipforward
     * 
* * bool can_ip_forward = 39 [(.google.api.field_behavior) = OPTIONAL]; * * @return This builder for chaining. */ public Builder clearCanIpForward() { bitField1_ = (bitField1_ & ~0x00000002); canIpForward_ = false; onChanged(); return this; } private com.google.protobuf.Timestamp createTime_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the createTime field is set. */ public boolean hasCreateTime() { return ((bitField1_ & 0x00000004) != 0); } /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The createTime. */ public com.google.protobuf.Timestamp getCreateTime() { if (createTimeBuilder_ == null) { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } else { return createTimeBuilder_.getMessage(); } } /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (value == null) { throw new NullPointerException(); } createTime_ = value; } else { createTimeBuilder_.setMessage(value); } bitField1_ |= 0x00000004; onChanged(); return this; } /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (createTimeBuilder_ == null) { createTime_ = builderForValue.build(); } else { createTimeBuilder_.setMessage(builderForValue.build()); } bitField1_ |= 0x00000004; onChanged(); return this; } /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (((bitField1_ & 0x00000004) != 0) && createTime_ != null && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getCreateTimeBuilder().mergeFrom(value); } else { createTime_ = value; } } else { createTimeBuilder_.mergeFrom(value); } if (createTime_ != null) { bitField1_ |= 0x00000004; onChanged(); } return this; } /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder clearCreateTime() { bitField1_ = (bitField1_ & ~0x00000004); createTime_ = null; if (createTimeBuilder_ != null) { createTimeBuilder_.dispose(); createTimeBuilder_ = null; } onChanged(); return this; } /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { bitField1_ |= 0x00000004; onChanged(); return getCreateTimeFieldBuilder().getBuilder(); } /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { if (createTimeBuilder_ != null) { return createTimeBuilder_.getMessageOrBuilder(); } else { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } } /** * * *
     * Output only. Instance creation time.
     * 
* * * .google.protobuf.Timestamp create_time = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> getCreateTimeFieldBuilder() { if (createTimeBuilder_ == null) { createTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( getCreateTime(), getParentForChildren(), isClean()); createTime_ = null; } return createTimeBuilder_; } private com.google.protobuf.Timestamp updateTime_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> updateTimeBuilder_; /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the updateTime field is set. */ public boolean hasUpdateTime() { return ((bitField1_ & 0x00000008) != 0); } /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The updateTime. */ public com.google.protobuf.Timestamp getUpdateTime() { if (updateTimeBuilder_ == null) { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } else { return updateTimeBuilder_.getMessage(); } } /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { if (value == null) { throw new NullPointerException(); } updateTime_ = value; } else { updateTimeBuilder_.setMessage(value); } bitField1_ |= 0x00000008; onChanged(); return this; } /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (updateTimeBuilder_ == null) { updateTime_ = builderForValue.build(); } else { updateTimeBuilder_.setMessage(builderForValue.build()); } bitField1_ |= 0x00000008; onChanged(); return this; } /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { if (((bitField1_ & 0x00000008) != 0) && updateTime_ != null && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getUpdateTimeBuilder().mergeFrom(value); } else { updateTime_ = value; } } else { updateTimeBuilder_.mergeFrom(value); } if (updateTime_ != null) { bitField1_ |= 0x00000008; onChanged(); } return this; } /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder clearUpdateTime() { bitField1_ = (bitField1_ & ~0x00000008); updateTime_ = null; if (updateTimeBuilder_ != null) { updateTimeBuilder_.dispose(); updateTimeBuilder_ = null; } onChanged(); return this; } /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { bitField1_ |= 0x00000008; onChanged(); return getUpdateTimeFieldBuilder().getBuilder(); } /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if (updateTimeBuilder_ != null) { return updateTimeBuilder_.getMessageOrBuilder(); } else { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } } /** * * *
     * Output only. Instance update time.
     * 
* * * .google.protobuf.Timestamp update_time = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> getUpdateTimeFieldBuilder() { if (updateTimeBuilder_ == null) { updateTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( getUpdateTime(), getParentForChildren(), isClean()); updateTime_ = null; } return updateTimeBuilder_; } @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.notebooks.v1.Instance) } // @@protoc_insertion_point(class_scope:google.cloud.notebooks.v1.Instance) private static final com.google.cloud.notebooks.v1.Instance DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.notebooks.v1.Instance(); } public static com.google.cloud.notebooks.v1.Instance getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public Instance parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.notebooks.v1.Instance getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy