Class DiskType.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<DiskType.Builder>
com.google.cloud.compute.v1.DiskType.Builder
All Implemented Interfaces:
DiskTypeOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
DiskType

public static final class DiskType.Builder extends com.google.protobuf.GeneratedMessage.Builder<DiskType.Builder> implements DiskTypeOrBuilder
 Represents a Disk Type resource.

 Google Compute Engine has two Disk Type resources:

 * [Regional](/compute/docs/reference/rest/v1/regionDiskTypes)
 * [Zonal](/compute/docs/reference/rest/v1/diskTypes)

 You can choose from a variety of disk types based on your needs.
 For more information, readStorage options.

 The diskTypes resource represents disk types for a zonal
 persistent disk.
 For more information, readZonal persistent disks.

 The regionDiskTypes resource represents disk types for a
 regional persistent disk. For more information, read Regional persistent disks.
 
Protobuf type google.cloud.compute.v1.DiskType
  • Method Details

    • getDescriptor

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

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

      public DiskType.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.GeneratedMessage.Builder<DiskType.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.GeneratedMessage.Builder<DiskType.Builder>
    • getDefaultInstanceForType

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

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

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

      public DiskType.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<DiskType.Builder>
    • mergeFrom

      public DiskType.Builder mergeFrom(DiskType other)
    • isInitialized

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

      public DiskType.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<DiskType.Builder>
      Throws:
      IOException
    • hasCreationTimestamp

      public boolean hasCreationTimestamp()
       [Output Only] Creation timestamp inRFC3339
       text format.
       
      optional string creation_timestamp = 30525366;
      Specified by:
      hasCreationTimestamp in interface DiskTypeOrBuilder
      Returns:
      Whether the creationTimestamp field is set.
    • getCreationTimestamp

      public String getCreationTimestamp()
       [Output Only] Creation timestamp inRFC3339
       text format.
       
      optional string creation_timestamp = 30525366;
      Specified by:
      getCreationTimestamp in interface DiskTypeOrBuilder
      Returns:
      The creationTimestamp.
    • getCreationTimestampBytes

      public com.google.protobuf.ByteString getCreationTimestampBytes()
       [Output Only] Creation timestamp inRFC3339
       text format.
       
      optional string creation_timestamp = 30525366;
      Specified by:
      getCreationTimestampBytes in interface DiskTypeOrBuilder
      Returns:
      The bytes for creationTimestamp.
    • setCreationTimestamp

      public DiskType.Builder setCreationTimestamp(String value)
       [Output Only] Creation timestamp inRFC3339
       text format.
       
      optional string creation_timestamp = 30525366;
      Parameters:
      value - The creationTimestamp to set.
      Returns:
      This builder for chaining.
    • clearCreationTimestamp

      public DiskType.Builder clearCreationTimestamp()
       [Output Only] Creation timestamp inRFC3339
       text format.
       
      optional string creation_timestamp = 30525366;
      Returns:
      This builder for chaining.
    • setCreationTimestampBytes

      public DiskType.Builder setCreationTimestampBytes(com.google.protobuf.ByteString value)
       [Output Only] Creation timestamp inRFC3339
       text format.
       
      optional string creation_timestamp = 30525366;
      Parameters:
      value - The bytes for creationTimestamp to set.
      Returns:
      This builder for chaining.
    • hasDefaultDiskSizeGb

      public boolean hasDefaultDiskSizeGb()
       [Output Only] Server-defined default disk size in GB.
       
      optional int64 default_disk_size_gb = 270619253;
      Specified by:
      hasDefaultDiskSizeGb in interface DiskTypeOrBuilder
      Returns:
      Whether the defaultDiskSizeGb field is set.
    • getDefaultDiskSizeGb

      public long getDefaultDiskSizeGb()
       [Output Only] Server-defined default disk size in GB.
       
      optional int64 default_disk_size_gb = 270619253;
      Specified by:
      getDefaultDiskSizeGb in interface DiskTypeOrBuilder
      Returns:
      The defaultDiskSizeGb.
    • setDefaultDiskSizeGb

      public DiskType.Builder setDefaultDiskSizeGb(long value)
       [Output Only] Server-defined default disk size in GB.
       
      optional int64 default_disk_size_gb = 270619253;
      Parameters:
      value - The defaultDiskSizeGb to set.
      Returns:
      This builder for chaining.
    • clearDefaultDiskSizeGb

      public DiskType.Builder clearDefaultDiskSizeGb()
       [Output Only] Server-defined default disk size in GB.
       
      optional int64 default_disk_size_gb = 270619253;
      Returns:
      This builder for chaining.
    • hasDeprecated

      public boolean hasDeprecated()
       [Output Only] The deprecation status associated with this disk type.
       
      optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;
      Specified by:
      hasDeprecated in interface DiskTypeOrBuilder
      Returns:
      Whether the deprecated field is set.
    • getDeprecated

      public DeprecationStatus getDeprecated()
       [Output Only] The deprecation status associated with this disk type.
       
      optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;
      Specified by:
      getDeprecated in interface DiskTypeOrBuilder
      Returns:
      The deprecated.
    • setDeprecated

      public DiskType.Builder setDeprecated(DeprecationStatus value)
       [Output Only] The deprecation status associated with this disk type.
       
      optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;
    • setDeprecated

      public DiskType.Builder setDeprecated(DeprecationStatus.Builder builderForValue)
       [Output Only] The deprecation status associated with this disk type.
       
      optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;
    • mergeDeprecated

      public DiskType.Builder mergeDeprecated(DeprecationStatus value)
       [Output Only] The deprecation status associated with this disk type.
       
      optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;
    • clearDeprecated

      public DiskType.Builder clearDeprecated()
       [Output Only] The deprecation status associated with this disk type.
       
      optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;
    • getDeprecatedBuilder

      public DeprecationStatus.Builder getDeprecatedBuilder()
       [Output Only] The deprecation status associated with this disk type.
       
      optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;
    • getDeprecatedOrBuilder

      public DeprecationStatusOrBuilder getDeprecatedOrBuilder()
       [Output Only] The deprecation status associated with this disk type.
       
      optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;
      Specified by:
      getDeprecatedOrBuilder in interface DiskTypeOrBuilder
    • hasDescription

      public boolean hasDescription()
       [Output Only] An optional description of this resource.
       
      optional string description = 422937596;
      Specified by:
      hasDescription in interface DiskTypeOrBuilder
      Returns:
      Whether the description field is set.
    • getDescription

      public String getDescription()
       [Output Only] An optional description of this resource.
       
      optional string description = 422937596;
      Specified by:
      getDescription in interface DiskTypeOrBuilder
      Returns:
      The description.
    • getDescriptionBytes

      public com.google.protobuf.ByteString getDescriptionBytes()
       [Output Only] An optional description of this resource.
       
      optional string description = 422937596;
      Specified by:
      getDescriptionBytes in interface DiskTypeOrBuilder
      Returns:
      The bytes for description.
    • setDescription

      public DiskType.Builder setDescription(String value)
       [Output Only] An optional description of this resource.
       
      optional string description = 422937596;
      Parameters:
      value - The description to set.
      Returns:
      This builder for chaining.
    • clearDescription

      public DiskType.Builder clearDescription()
       [Output Only] An optional description of this resource.
       
      optional string description = 422937596;
      Returns:
      This builder for chaining.
    • setDescriptionBytes

      public DiskType.Builder setDescriptionBytes(com.google.protobuf.ByteString value)
       [Output Only] An optional description of this resource.
       
      optional string description = 422937596;
      Parameters:
      value - The bytes for description to set.
      Returns:
      This builder for chaining.
    • hasId

      public boolean hasId()
       [Output Only] The unique identifier for the resource. This identifier is
       defined by the server.
       
      optional uint64 id = 3355;
      Specified by:
      hasId in interface DiskTypeOrBuilder
      Returns:
      Whether the id field is set.
    • getId

      public long getId()
       [Output Only] The unique identifier for the resource. This identifier is
       defined by the server.
       
      optional uint64 id = 3355;
      Specified by:
      getId in interface DiskTypeOrBuilder
      Returns:
      The id.
    • setId

      public DiskType.Builder setId(long value)
       [Output Only] The unique identifier for the resource. This identifier is
       defined by the server.
       
      optional uint64 id = 3355;
      Parameters:
      value - The id to set.
      Returns:
      This builder for chaining.
    • clearId

      public DiskType.Builder clearId()
       [Output Only] The unique identifier for the resource. This identifier is
       defined by the server.
       
      optional uint64 id = 3355;
      Returns:
      This builder for chaining.
    • hasKind

      public boolean hasKind()
       Output only. [Output Only] Type of the resource. Always compute#diskType
       for disk types.
       
      optional string kind = 3292052;
      Specified by:
      hasKind in interface DiskTypeOrBuilder
      Returns:
      Whether the kind field is set.
    • getKind

      public String getKind()
       Output only. [Output Only] Type of the resource. Always compute#diskType
       for disk types.
       
      optional string kind = 3292052;
      Specified by:
      getKind in interface DiskTypeOrBuilder
      Returns:
      The kind.
    • getKindBytes

      public com.google.protobuf.ByteString getKindBytes()
       Output only. [Output Only] Type of the resource. Always compute#diskType
       for disk types.
       
      optional string kind = 3292052;
      Specified by:
      getKindBytes in interface DiskTypeOrBuilder
      Returns:
      The bytes for kind.
    • setKind

      public DiskType.Builder setKind(String value)
       Output only. [Output Only] Type of the resource. Always compute#diskType
       for disk types.
       
      optional string kind = 3292052;
      Parameters:
      value - The kind to set.
      Returns:
      This builder for chaining.
    • clearKind

      public DiskType.Builder clearKind()
       Output only. [Output Only] Type of the resource. Always compute#diskType
       for disk types.
       
      optional string kind = 3292052;
      Returns:
      This builder for chaining.
    • setKindBytes

      public DiskType.Builder setKindBytes(com.google.protobuf.ByteString value)
       Output only. [Output Only] Type of the resource. Always compute#diskType
       for disk types.
       
      optional string kind = 3292052;
      Parameters:
      value - The bytes for kind to set.
      Returns:
      This builder for chaining.
    • hasName

      public boolean hasName()
       [Output Only] Name of the resource.
       
      optional string name = 3373707;
      Specified by:
      hasName in interface DiskTypeOrBuilder
      Returns:
      Whether the name field is set.
    • getName

      public String getName()
       [Output Only] Name of the resource.
       
      optional string name = 3373707;
      Specified by:
      getName in interface DiskTypeOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       [Output Only] Name of the resource.
       
      optional string name = 3373707;
      Specified by:
      getNameBytes in interface DiskTypeOrBuilder
      Returns:
      The bytes for name.
    • setName

      public DiskType.Builder setName(String value)
       [Output Only] Name of the resource.
       
      optional string name = 3373707;
      Parameters:
      value - The name to set.
      Returns:
      This builder for chaining.
    • clearName

      public DiskType.Builder clearName()
       [Output Only] Name of the resource.
       
      optional string name = 3373707;
      Returns:
      This builder for chaining.
    • setNameBytes

      public DiskType.Builder setNameBytes(com.google.protobuf.ByteString value)
       [Output Only] Name of the resource.
       
      optional string name = 3373707;
      Parameters:
      value - The bytes for name to set.
      Returns:
      This builder for chaining.
    • hasRegion

      public boolean hasRegion()
       [Output Only] URL of the region where the disk type resides. Only
       applicable for regional resources.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string region = 138946292;
      Specified by:
      hasRegion in interface DiskTypeOrBuilder
      Returns:
      Whether the region field is set.
    • getRegion

      public String getRegion()
       [Output Only] URL of the region where the disk type resides. Only
       applicable for regional resources.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string region = 138946292;
      Specified by:
      getRegion in interface DiskTypeOrBuilder
      Returns:
      The region.
    • getRegionBytes

      public com.google.protobuf.ByteString getRegionBytes()
       [Output Only] URL of the region where the disk type resides. Only
       applicable for regional resources.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string region = 138946292;
      Specified by:
      getRegionBytes in interface DiskTypeOrBuilder
      Returns:
      The bytes for region.
    • setRegion

      public DiskType.Builder setRegion(String value)
       [Output Only] URL of the region where the disk type resides. Only
       applicable for regional resources.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string region = 138946292;
      Parameters:
      value - The region to set.
      Returns:
      This builder for chaining.
    • clearRegion

      public DiskType.Builder clearRegion()
       [Output Only] URL of the region where the disk type resides. Only
       applicable for regional resources.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string region = 138946292;
      Returns:
      This builder for chaining.
    • setRegionBytes

      public DiskType.Builder setRegionBytes(com.google.protobuf.ByteString value)
       [Output Only] URL of the region where the disk type resides. Only
       applicable for regional resources.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string region = 138946292;
      Parameters:
      value - The bytes for region to set.
      Returns:
      This builder for chaining.
    • hasSelfLink

      public boolean hasSelfLink()
       [Output Only] Server-defined URL for the resource.
       
      optional string self_link = 456214797;
      Specified by:
      hasSelfLink in interface DiskTypeOrBuilder
      Returns:
      Whether the selfLink field is set.
    • getSelfLink

      public String getSelfLink()
       [Output Only] Server-defined URL for the resource.
       
      optional string self_link = 456214797;
      Specified by:
      getSelfLink in interface DiskTypeOrBuilder
      Returns:
      The selfLink.
    • getSelfLinkBytes

      public com.google.protobuf.ByteString getSelfLinkBytes()
       [Output Only] Server-defined URL for the resource.
       
      optional string self_link = 456214797;
      Specified by:
      getSelfLinkBytes in interface DiskTypeOrBuilder
      Returns:
      The bytes for selfLink.
    • setSelfLink

      public DiskType.Builder setSelfLink(String value)
       [Output Only] Server-defined URL for the resource.
       
      optional string self_link = 456214797;
      Parameters:
      value - The selfLink to set.
      Returns:
      This builder for chaining.
    • clearSelfLink

      public DiskType.Builder clearSelfLink()
       [Output Only] Server-defined URL for the resource.
       
      optional string self_link = 456214797;
      Returns:
      This builder for chaining.
    • setSelfLinkBytes

      public DiskType.Builder setSelfLinkBytes(com.google.protobuf.ByteString value)
       [Output Only] Server-defined URL for the resource.
       
      optional string self_link = 456214797;
      Parameters:
      value - The bytes for selfLink to set.
      Returns:
      This builder for chaining.
    • hasValidDiskSize

      public boolean hasValidDiskSize()
       [Output Only] An optional textual description of the valid disk size,
       such as "10GB-10TB".
       
      optional string valid_disk_size = 493962464;
      Specified by:
      hasValidDiskSize in interface DiskTypeOrBuilder
      Returns:
      Whether the validDiskSize field is set.
    • getValidDiskSize

      public String getValidDiskSize()
       [Output Only] An optional textual description of the valid disk size,
       such as "10GB-10TB".
       
      optional string valid_disk_size = 493962464;
      Specified by:
      getValidDiskSize in interface DiskTypeOrBuilder
      Returns:
      The validDiskSize.
    • getValidDiskSizeBytes

      public com.google.protobuf.ByteString getValidDiskSizeBytes()
       [Output Only] An optional textual description of the valid disk size,
       such as "10GB-10TB".
       
      optional string valid_disk_size = 493962464;
      Specified by:
      getValidDiskSizeBytes in interface DiskTypeOrBuilder
      Returns:
      The bytes for validDiskSize.
    • setValidDiskSize

      public DiskType.Builder setValidDiskSize(String value)
       [Output Only] An optional textual description of the valid disk size,
       such as "10GB-10TB".
       
      optional string valid_disk_size = 493962464;
      Parameters:
      value - The validDiskSize to set.
      Returns:
      This builder for chaining.
    • clearValidDiskSize

      public DiskType.Builder clearValidDiskSize()
       [Output Only] An optional textual description of the valid disk size,
       such as "10GB-10TB".
       
      optional string valid_disk_size = 493962464;
      Returns:
      This builder for chaining.
    • setValidDiskSizeBytes

      public DiskType.Builder setValidDiskSizeBytes(com.google.protobuf.ByteString value)
       [Output Only] An optional textual description of the valid disk size,
       such as "10GB-10TB".
       
      optional string valid_disk_size = 493962464;
      Parameters:
      value - The bytes for validDiskSize to set.
      Returns:
      This builder for chaining.
    • hasZone

      public boolean hasZone()
       [Output Only] URL of the zone where the disk type resides.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string zone = 3744684;
      Specified by:
      hasZone in interface DiskTypeOrBuilder
      Returns:
      Whether the zone field is set.
    • getZone

      public String getZone()
       [Output Only] URL of the zone where the disk type resides.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string zone = 3744684;
      Specified by:
      getZone in interface DiskTypeOrBuilder
      Returns:
      The zone.
    • getZoneBytes

      public com.google.protobuf.ByteString getZoneBytes()
       [Output Only] URL of the zone where the disk type resides.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string zone = 3744684;
      Specified by:
      getZoneBytes in interface DiskTypeOrBuilder
      Returns:
      The bytes for zone.
    • setZone

      public DiskType.Builder setZone(String value)
       [Output Only] URL of the zone where the disk type resides.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string zone = 3744684;
      Parameters:
      value - The zone to set.
      Returns:
      This builder for chaining.
    • clearZone

      public DiskType.Builder clearZone()
       [Output Only] URL of the zone where the disk type resides.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string zone = 3744684;
      Returns:
      This builder for chaining.
    • setZoneBytes

      public DiskType.Builder setZoneBytes(com.google.protobuf.ByteString value)
       [Output Only] URL of the zone where the disk type resides.
       You must specify this field as part of the HTTP request URL. It is
       not settable as a field in the request body.
       
      optional string zone = 3744684;
      Parameters:
      value - The bytes for zone to set.
      Returns:
      This builder for chaining.