Class PersistentDisk.Builder

  • All Implemented Interfaces:
    PersistentDiskOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
    Enclosing class:
    PersistentDisk

    public static final class PersistentDisk.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
    implements PersistentDiskOrBuilder
     Configuration for a persistent disk to be attached to the VM.
    
     See https://cloud.google.com/compute/docs/disks/performance for more
     information about disk type, size, and performance considerations.
     
    Protobuf type google.cloud.lifesciences.v2beta.PersistentDisk
    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • clear

        public PersistentDisk.Builder clear()
        Specified by:
        clear in interface com.google.protobuf.Message.Builder
        Specified by:
        clear in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clear in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • getDefaultInstanceForType

        public PersistentDisk getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public PersistentDisk build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public PersistentDisk buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • clone

        public PersistentDisk.Builder clone()
        Specified by:
        clone in interface com.google.protobuf.Message.Builder
        Specified by:
        clone in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clone in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • setField

        public PersistentDisk.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                               Object value)
        Specified by:
        setField in interface com.google.protobuf.Message.Builder
        Overrides:
        setField in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • clearField

        public PersistentDisk.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
        Specified by:
        clearField in interface com.google.protobuf.Message.Builder
        Overrides:
        clearField in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • clearOneof

        public PersistentDisk.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
        Specified by:
        clearOneof in interface com.google.protobuf.Message.Builder
        Overrides:
        clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • setRepeatedField

        public PersistentDisk.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                       int index,
                                                       Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • addRepeatedField

        public PersistentDisk.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                       Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • mergeFrom

        public PersistentDisk.Builder mergeFrom​(com.google.protobuf.Message other)
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<PersistentDisk.Builder>
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • mergeFrom

        public PersistentDisk.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                         throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<PersistentDisk.Builder>
        Throws:
        IOException
      • getSizeGb

        public int getSizeGb()
         The size, in GB, of the disk to attach. If the size is not
         specified, a default is chosen to ensure reasonable I/O performance.
        
         If the disk type is specified as `local-ssd`, multiple local drives are
         automatically combined to provide the requested size. Note, however, that
         each physical SSD is 375GB in size, and no more than 8 drives can be
         attached to a single instance.
         
        int32 size_gb = 1;
        Specified by:
        getSizeGb in interface PersistentDiskOrBuilder
        Returns:
        The sizeGb.
      • setSizeGb

        public PersistentDisk.Builder setSizeGb​(int value)
         The size, in GB, of the disk to attach. If the size is not
         specified, a default is chosen to ensure reasonable I/O performance.
        
         If the disk type is specified as `local-ssd`, multiple local drives are
         automatically combined to provide the requested size. Note, however, that
         each physical SSD is 375GB in size, and no more than 8 drives can be
         attached to a single instance.
         
        int32 size_gb = 1;
        Parameters:
        value - The sizeGb to set.
        Returns:
        This builder for chaining.
      • clearSizeGb

        public PersistentDisk.Builder clearSizeGb()
         The size, in GB, of the disk to attach. If the size is not
         specified, a default is chosen to ensure reasonable I/O performance.
        
         If the disk type is specified as `local-ssd`, multiple local drives are
         automatically combined to provide the requested size. Note, however, that
         each physical SSD is 375GB in size, and no more than 8 drives can be
         attached to a single instance.
         
        int32 size_gb = 1;
        Returns:
        This builder for chaining.
      • getType

        public String getType()
         The Compute Engine disk type. If unspecified, `pd-standard` is used.
         
        string type = 2;
        Specified by:
        getType in interface PersistentDiskOrBuilder
        Returns:
        The type.
      • getTypeBytes

        public com.google.protobuf.ByteString getTypeBytes()
         The Compute Engine disk type. If unspecified, `pd-standard` is used.
         
        string type = 2;
        Specified by:
        getTypeBytes in interface PersistentDiskOrBuilder
        Returns:
        The bytes for type.
      • setType

        public PersistentDisk.Builder setType​(String value)
         The Compute Engine disk type. If unspecified, `pd-standard` is used.
         
        string type = 2;
        Parameters:
        value - The type to set.
        Returns:
        This builder for chaining.
      • clearType

        public PersistentDisk.Builder clearType()
         The Compute Engine disk type. If unspecified, `pd-standard` is used.
         
        string type = 2;
        Returns:
        This builder for chaining.
      • setTypeBytes

        public PersistentDisk.Builder setTypeBytes​(com.google.protobuf.ByteString value)
         The Compute Engine disk type. If unspecified, `pd-standard` is used.
         
        string type = 2;
        Parameters:
        value - The bytes for type to set.
        Returns:
        This builder for chaining.
      • getSourceImage

        public String getSourceImage()
         An image to put on the disk before attaching it to the VM.
         
        string source_image = 3;
        Specified by:
        getSourceImage in interface PersistentDiskOrBuilder
        Returns:
        The sourceImage.
      • getSourceImageBytes

        public com.google.protobuf.ByteString getSourceImageBytes()
         An image to put on the disk before attaching it to the VM.
         
        string source_image = 3;
        Specified by:
        getSourceImageBytes in interface PersistentDiskOrBuilder
        Returns:
        The bytes for sourceImage.
      • setSourceImage

        public PersistentDisk.Builder setSourceImage​(String value)
         An image to put on the disk before attaching it to the VM.
         
        string source_image = 3;
        Parameters:
        value - The sourceImage to set.
        Returns:
        This builder for chaining.
      • clearSourceImage

        public PersistentDisk.Builder clearSourceImage()
         An image to put on the disk before attaching it to the VM.
         
        string source_image = 3;
        Returns:
        This builder for chaining.
      • setSourceImageBytes

        public PersistentDisk.Builder setSourceImageBytes​(com.google.protobuf.ByteString value)
         An image to put on the disk before attaching it to the VM.
         
        string source_image = 3;
        Parameters:
        value - The bytes for sourceImage to set.
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final PersistentDisk.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>
      • mergeUnknownFields

        public final PersistentDisk.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<PersistentDisk.Builder>