Class Image.Builder (1.59.0)

public static final class Image.Builder extends GeneratedMessageV3.Builder<Image.Builder> implements ImageOrBuilder

Represents an Image resource. You can use images to create boot disks for your VM instances. For more information, read Images.

Protobuf type google.cloud.compute.v1.Image

Implements

ImageOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addAllGuestOsFeatures(Iterable<? extends GuestOsFeature> values)

public Image.Builder addAllGuestOsFeatures(Iterable<? extends GuestOsFeature> values)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameter
Name Description
values Iterable<? extends com.google.cloud.compute.v1.GuestOsFeature>
Returns
Type Description
Image.Builder

addAllLicenseCodes(Iterable<? extends Long> values)

public Image.Builder addAllLicenseCodes(Iterable<? extends Long> values)

Integer license codes indicating which licenses are attached to this image.

repeated int64 license_codes = 45482664;

Parameter
Name Description
values Iterable<? extends java.lang.Long>

The licenseCodes to add.

Returns
Type Description
Image.Builder

This builder for chaining.

addAllLicenses(Iterable<String> values)

public Image.Builder addAllLicenses(Iterable<String> values)

Any applicable license URI.

repeated string licenses = 337642578;

Parameter
Name Description
values Iterable<String>

The licenses to add.

Returns
Type Description
Image.Builder

This builder for chaining.

addAllStorageLocations(Iterable<String> values)

public Image.Builder addAllStorageLocations(Iterable<String> values)

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Parameter
Name Description
values Iterable<String>

The storageLocations to add.

Returns
Type Description
Image.Builder

This builder for chaining.

addGuestOsFeatures(GuestOsFeature value)

public Image.Builder addGuestOsFeatures(GuestOsFeature value)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameter
Name Description
value GuestOsFeature
Returns
Type Description
Image.Builder

addGuestOsFeatures(GuestOsFeature.Builder builderForValue)

public Image.Builder addGuestOsFeatures(GuestOsFeature.Builder builderForValue)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameter
Name Description
builderForValue GuestOsFeature.Builder
Returns
Type Description
Image.Builder

addGuestOsFeatures(int index, GuestOsFeature value)

public Image.Builder addGuestOsFeatures(int index, GuestOsFeature value)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameters
Name Description
index int
value GuestOsFeature
Returns
Type Description
Image.Builder

addGuestOsFeatures(int index, GuestOsFeature.Builder builderForValue)

public Image.Builder addGuestOsFeatures(int index, GuestOsFeature.Builder builderForValue)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameters
Name Description
index int
builderForValue GuestOsFeature.Builder
Returns
Type Description
Image.Builder

addGuestOsFeaturesBuilder()

public GuestOsFeature.Builder addGuestOsFeaturesBuilder()

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Returns
Type Description
GuestOsFeature.Builder

addGuestOsFeaturesBuilder(int index)

public GuestOsFeature.Builder addGuestOsFeaturesBuilder(int index)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameter
Name Description
index int
Returns
Type Description
GuestOsFeature.Builder

addLicenseCodes(long value)

public Image.Builder addLicenseCodes(long value)

Integer license codes indicating which licenses are attached to this image.

repeated int64 license_codes = 45482664;

Parameter
Name Description
value long

The licenseCodes to add.

Returns
Type Description
Image.Builder

This builder for chaining.

addLicenses(String value)

public Image.Builder addLicenses(String value)

Any applicable license URI.

repeated string licenses = 337642578;

Parameter
Name Description
value String

The licenses to add.

Returns
Type Description
Image.Builder

This builder for chaining.

addLicensesBytes(ByteString value)

public Image.Builder addLicensesBytes(ByteString value)

Any applicable license URI.

repeated string licenses = 337642578;

Parameter
Name Description
value ByteString

The bytes of the licenses to add.

Returns
Type Description
Image.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Image.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
Image.Builder
Overrides

addStorageLocations(String value)

public Image.Builder addStorageLocations(String value)

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Parameter
Name Description
value String

The storageLocations to add.

Returns
Type Description
Image.Builder

This builder for chaining.

addStorageLocationsBytes(ByteString value)

public Image.Builder addStorageLocationsBytes(ByteString value)

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Parameter
Name Description
value ByteString

The bytes of the storageLocations to add.

Returns
Type Description
Image.Builder

This builder for chaining.

build()

public Image build()
Returns
Type Description
Image

buildPartial()

public Image buildPartial()
Returns
Type Description
Image

clear()

public Image.Builder clear()
Returns
Type Description
Image.Builder
Overrides

clearArchitecture()

public Image.Builder clearArchitecture()

The architecture of the image. Valid values are ARM64 or X86_64. Check the Architecture enum for the list of possible values.

optional string architecture = 302803283;

Returns
Type Description
Image.Builder

This builder for chaining.

clearArchiveSizeBytes()

public Image.Builder clearArchiveSizeBytes()

Size of the image tar.gz archive stored in Google Cloud Storage (in bytes).

optional int64 archive_size_bytes = 381093450;

Returns
Type Description
Image.Builder

This builder for chaining.

clearCreationTimestamp()

public Image.Builder clearCreationTimestamp()

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Returns
Type Description
Image.Builder

This builder for chaining.

clearDeprecated()

public Image.Builder clearDeprecated()

The deprecation status associated with this image.

optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;

Returns
Type Description
Image.Builder

clearDescription()

public Image.Builder clearDescription()

An optional description of this resource. Provide this property when you create the resource.

optional string description = 422937596;

Returns
Type Description
Image.Builder

This builder for chaining.

clearDiskSizeGb()

public Image.Builder clearDiskSizeGb()

Size of the image when restored onto a persistent disk (in GB).

optional int64 disk_size_gb = 316263735;

Returns
Type Description
Image.Builder

This builder for chaining.

clearEnableConfidentialCompute()

public Image.Builder clearEnableConfidentialCompute()

Whether this image is created from a confidential compute mode disk. [Output Only]: This field is not set by user, but from source disk.

optional bool enable_confidential_compute = 102135228;

Returns
Type Description
Image.Builder

This builder for chaining.

clearFamily()

public Image.Builder clearFamily()

The name of the image family to which this image belongs. The image family name can be from a publicly managed image family provided by Compute Engine, or from a custom image family you create. For example, centos-stream-9 is a publicly available image family. For more information, see Image family best practices. When creating disks, you can specify an image family instead of a specific image name. The image family always returns its latest image that is not deprecated. The name of the image family must comply with RFC1035.

optional string family = 328751972;

Returns
Type Description
Image.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public Image.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
Image.Builder
Overrides

clearGuestOsFeatures()

public Image.Builder clearGuestOsFeatures()

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Returns
Type Description
Image.Builder

clearId()

public Image.Builder clearId()

[Output Only] The unique identifier for the resource. This identifier is defined by the server.

optional uint64 id = 3355;

Returns
Type Description
Image.Builder

This builder for chaining.

clearImageEncryptionKey()

public Image.Builder clearImageEncryptionKey()

Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later.

optional .google.cloud.compute.v1.CustomerEncryptionKey image_encryption_key = 379512583;

Returns
Type Description
Image.Builder

clearKind()

public Image.Builder clearKind()

[Output Only] Type of the resource. Always compute#image for images.

optional string kind = 3292052;

Returns
Type Description
Image.Builder

This builder for chaining.

clearLabelFingerprint()

public Image.Builder clearLabelFingerprint()

A fingerprint for the labels being applied to this image, which is essentially a hash of the labels used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an image.

optional string label_fingerprint = 178124825;

Returns
Type Description
Image.Builder

This builder for chaining.

clearLabels()

public Image.Builder clearLabels()
Returns
Type Description
Image.Builder

clearLicenseCodes()

public Image.Builder clearLicenseCodes()

Integer license codes indicating which licenses are attached to this image.

repeated int64 license_codes = 45482664;

Returns
Type Description
Image.Builder

This builder for chaining.

clearLicenses()

public Image.Builder clearLicenses()

Any applicable license URI.

repeated string licenses = 337642578;

Returns
Type Description
Image.Builder

This builder for chaining.

clearName()

public Image.Builder clearName()

Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.

optional string name = 3373707;

Returns
Type Description
Image.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public Image.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
Image.Builder
Overrides

clearRawDisk()

public Image.Builder clearRawDisk()

The parameters of the raw disk image.

optional .google.cloud.compute.v1.RawDisk raw_disk = 503113556;

Returns
Type Description
Image.Builder

clearSatisfiesPzi()

public Image.Builder clearSatisfiesPzi()

Output only. Reserved for future use.

optional bool satisfies_pzi = 480964257;

Returns
Type Description
Image.Builder

This builder for chaining.

clearSatisfiesPzs()

public Image.Builder clearSatisfiesPzs()

[Output Only] Reserved for future use.

optional bool satisfies_pzs = 480964267;

Returns
Type Description
Image.Builder

This builder for chaining.

public Image.Builder clearSelfLink()

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Returns
Type Description
Image.Builder

This builder for chaining.

clearShieldedInstanceInitialState()

public Image.Builder clearShieldedInstanceInitialState()

Set the secure boot keys of shielded instance.

optional .google.cloud.compute.v1.InitialStateConfig shielded_instance_initial_state = 192356867;

Returns
Type Description
Image.Builder

clearSourceDisk()

public Image.Builder clearSourceDisk()

URL of the source disk used to create this image. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_disk = 451753793;

Returns
Type Description
Image.Builder

This builder for chaining.

clearSourceDiskEncryptionKey()

public Image.Builder clearSourceDiskEncryptionKey()

The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_disk_encryption_key = 531501153;

Returns
Type Description
Image.Builder

clearSourceDiskId()

public Image.Builder clearSourceDiskId()

[Output Only] The ID value of the disk used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given disk name.

optional string source_disk_id = 454190809;

Returns
Type Description
Image.Builder

This builder for chaining.

clearSourceImage()

public Image.Builder clearSourceImage()

URL of the source image used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ images/image_name - projects/project_id/global/images/image_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_image = 50443319;

Returns
Type Description
Image.Builder

This builder for chaining.

clearSourceImageEncryptionKey()

public Image.Builder clearSourceImageEncryptionKey()

The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;

Returns
Type Description
Image.Builder

clearSourceImageId()

public Image.Builder clearSourceImageId()

[Output Only] The ID value of the image used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given image name.

optional string source_image_id = 55328291;

Returns
Type Description
Image.Builder

This builder for chaining.

clearSourceSnapshot()

public Image.Builder clearSourceSnapshot()

URL of the source snapshot used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ snapshots/snapshot_name - projects/project_id/global/snapshots/snapshot_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_snapshot = 126061928;

Returns
Type Description
Image.Builder

This builder for chaining.

clearSourceSnapshotEncryptionKey()

public Image.Builder clearSourceSnapshotEncryptionKey()

The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;

Returns
Type Description
Image.Builder

clearSourceSnapshotId()

public Image.Builder clearSourceSnapshotId()

[Output Only] The ID value of the snapshot used to create this image. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given snapshot name.

optional string source_snapshot_id = 98962258;

Returns
Type Description
Image.Builder

This builder for chaining.

clearSourceType()

public Image.Builder clearSourceType()

The type of the image used to create this disk. The default and only valid value is RAW. Check the SourceType enum for the list of possible values.

optional string source_type = 452245726;

Returns
Type Description
Image.Builder

This builder for chaining.

clearStatus()

public Image.Builder clearStatus()

[Output Only] The status of the image. An image can be used to create other resources, such as instances, only after the image has been successfully created and the status is set to READY. Possible values are FAILED, PENDING, or READY. Check the Status enum for the list of possible values.

optional string status = 181260274;

Returns
Type Description
Image.Builder

This builder for chaining.

clearStorageLocations()

public Image.Builder clearStorageLocations()

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Returns
Type Description
Image.Builder

This builder for chaining.

clone()

public Image.Builder clone()
Returns
Type Description
Image.Builder
Overrides

containsLabels(String key)

public boolean containsLabels(String key)

Labels to apply to this image. These can be later modified by the setLabels method.

map<string, string> labels = 500195327;

Parameter
Name Description
key String
Returns
Type Description
boolean

getArchitecture()

public String getArchitecture()

The architecture of the image. Valid values are ARM64 or X86_64. Check the Architecture enum for the list of possible values.

optional string architecture = 302803283;

Returns
Type Description
String

The architecture.

getArchitectureBytes()

public ByteString getArchitectureBytes()

The architecture of the image. Valid values are ARM64 or X86_64. Check the Architecture enum for the list of possible values.

optional string architecture = 302803283;

Returns
Type Description
ByteString

The bytes for architecture.

getArchiveSizeBytes()

public long getArchiveSizeBytes()

Size of the image tar.gz archive stored in Google Cloud Storage (in bytes).

optional int64 archive_size_bytes = 381093450;

Returns
Type Description
long

The archiveSizeBytes.

getCreationTimestamp()

public String getCreationTimestamp()

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Returns
Type Description
String

The creationTimestamp.

getCreationTimestampBytes()

public ByteString getCreationTimestampBytes()

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Returns
Type Description
ByteString

The bytes for creationTimestamp.

getDefaultInstanceForType()

public Image getDefaultInstanceForType()
Returns
Type Description
Image

getDeprecated()

public DeprecationStatus getDeprecated()

The deprecation status associated with this image.

optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;

Returns
Type Description
DeprecationStatus

The deprecated.

getDeprecatedBuilder()

public DeprecationStatus.Builder getDeprecatedBuilder()

The deprecation status associated with this image.

optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;

Returns
Type Description
DeprecationStatus.Builder

getDeprecatedOrBuilder()

public DeprecationStatusOrBuilder getDeprecatedOrBuilder()

The deprecation status associated with this image.

optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;

Returns
Type Description
DeprecationStatusOrBuilder

getDescription()

public String getDescription()

An optional description of this resource. Provide this property when you create the resource.

optional string description = 422937596;

Returns
Type Description
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

An optional description of this resource. Provide this property when you create the resource.

optional string description = 422937596;

Returns
Type Description
ByteString

The bytes for description.

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getDiskSizeGb()

public long getDiskSizeGb()

Size of the image when restored onto a persistent disk (in GB).

optional int64 disk_size_gb = 316263735;

Returns
Type Description
long

The diskSizeGb.

getEnableConfidentialCompute()

public boolean getEnableConfidentialCompute()

Whether this image is created from a confidential compute mode disk. [Output Only]: This field is not set by user, but from source disk.

optional bool enable_confidential_compute = 102135228;

Returns
Type Description
boolean

The enableConfidentialCompute.

getFamily()

public String getFamily()

The name of the image family to which this image belongs. The image family name can be from a publicly managed image family provided by Compute Engine, or from a custom image family you create. For example, centos-stream-9 is a publicly available image family. For more information, see Image family best practices. When creating disks, you can specify an image family instead of a specific image name. The image family always returns its latest image that is not deprecated. The name of the image family must comply with RFC1035.

optional string family = 328751972;

Returns
Type Description
String

The family.

getFamilyBytes()

public ByteString getFamilyBytes()

The name of the image family to which this image belongs. The image family name can be from a publicly managed image family provided by Compute Engine, or from a custom image family you create. For example, centos-stream-9 is a publicly available image family. For more information, see Image family best practices. When creating disks, you can specify an image family instead of a specific image name. The image family always returns its latest image that is not deprecated. The name of the image family must comply with RFC1035.

optional string family = 328751972;

Returns
Type Description
ByteString

The bytes for family.

getGuestOsFeatures(int index)

public GuestOsFeature getGuestOsFeatures(int index)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameter
Name Description
index int
Returns
Type Description
GuestOsFeature

getGuestOsFeaturesBuilder(int index)

public GuestOsFeature.Builder getGuestOsFeaturesBuilder(int index)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameter
Name Description
index int
Returns
Type Description
GuestOsFeature.Builder

getGuestOsFeaturesBuilderList()

public List<GuestOsFeature.Builder> getGuestOsFeaturesBuilderList()

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Returns
Type Description
List<Builder>

getGuestOsFeaturesCount()

public int getGuestOsFeaturesCount()

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Returns
Type Description
int

getGuestOsFeaturesList()

public List<GuestOsFeature> getGuestOsFeaturesList()

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Returns
Type Description
List<GuestOsFeature>

getGuestOsFeaturesOrBuilder(int index)

public GuestOsFeatureOrBuilder getGuestOsFeaturesOrBuilder(int index)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameter
Name Description
index int
Returns
Type Description
GuestOsFeatureOrBuilder

getGuestOsFeaturesOrBuilderList()

public List<? extends GuestOsFeatureOrBuilder> getGuestOsFeaturesOrBuilderList()

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Returns
Type Description
List<? extends com.google.cloud.compute.v1.GuestOsFeatureOrBuilder>

getId()

public long getId()

[Output Only] The unique identifier for the resource. This identifier is defined by the server.

optional uint64 id = 3355;

Returns
Type Description
long

The id.

getImageEncryptionKey()

public CustomerEncryptionKey getImageEncryptionKey()

Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later.

optional .google.cloud.compute.v1.CustomerEncryptionKey image_encryption_key = 379512583;

Returns
Type Description
CustomerEncryptionKey

The imageEncryptionKey.

getImageEncryptionKeyBuilder()

public CustomerEncryptionKey.Builder getImageEncryptionKeyBuilder()

Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later.

optional .google.cloud.compute.v1.CustomerEncryptionKey image_encryption_key = 379512583;

Returns
Type Description
CustomerEncryptionKey.Builder

getImageEncryptionKeyOrBuilder()

public CustomerEncryptionKeyOrBuilder getImageEncryptionKeyOrBuilder()

Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later.

optional .google.cloud.compute.v1.CustomerEncryptionKey image_encryption_key = 379512583;

Returns
Type Description
CustomerEncryptionKeyOrBuilder

getKind()

public String getKind()

[Output Only] Type of the resource. Always compute#image for images.

optional string kind = 3292052;

Returns
Type Description
String

The kind.

getKindBytes()

public ByteString getKindBytes()

[Output Only] Type of the resource. Always compute#image for images.

optional string kind = 3292052;

Returns
Type Description
ByteString

The bytes for kind.

getLabelFingerprint()

public String getLabelFingerprint()

A fingerprint for the labels being applied to this image, which is essentially a hash of the labels used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an image.

optional string label_fingerprint = 178124825;

Returns
Type Description
String

The labelFingerprint.

getLabelFingerprintBytes()

public ByteString getLabelFingerprintBytes()

A fingerprint for the labels being applied to this image, which is essentially a hash of the labels used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an image.

optional string label_fingerprint = 178124825;

Returns
Type Description
ByteString

The bytes for labelFingerprint.

getLabels() (deprecated)

public Map<String,String> getLabels()

Use #getLabelsMap() instead.

Returns
Type Description
Map<String,String>

getLabelsCount()

public int getLabelsCount()

Labels to apply to this image. These can be later modified by the setLabels method.

map<string, string> labels = 500195327;

Returns
Type Description
int

getLabelsMap()

public Map<String,String> getLabelsMap()

Labels to apply to this image. These can be later modified by the setLabels method.

map<string, string> labels = 500195327;

Returns
Type Description
Map<String,String>

getLabelsOrDefault(String key, String defaultValue)

public String getLabelsOrDefault(String key, String defaultValue)

Labels to apply to this image. These can be later modified by the setLabels method.

map<string, string> labels = 500195327;

Parameters
Name Description
key String
defaultValue String
Returns
Type Description
String

getLabelsOrThrow(String key)

public String getLabelsOrThrow(String key)

Labels to apply to this image. These can be later modified by the setLabels method.

map<string, string> labels = 500195327;

Parameter
Name Description
key String
Returns
Type Description
String

getLicenseCodes(int index)

public long getLicenseCodes(int index)

Integer license codes indicating which licenses are attached to this image.

repeated int64 license_codes = 45482664;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
long

The licenseCodes at the given index.

getLicenseCodesCount()

public int getLicenseCodesCount()

Integer license codes indicating which licenses are attached to this image.

repeated int64 license_codes = 45482664;

Returns
Type Description
int

The count of licenseCodes.

getLicenseCodesList()

public List<Long> getLicenseCodesList()

Integer license codes indicating which licenses are attached to this image.

repeated int64 license_codes = 45482664;

Returns
Type Description
List<Long>

A list containing the licenseCodes.

getLicenses(int index)

public String getLicenses(int index)

Any applicable license URI.

repeated string licenses = 337642578;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The licenses at the given index.

getLicensesBytes(int index)

public ByteString getLicensesBytes(int index)

Any applicable license URI.

repeated string licenses = 337642578;

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the licenses at the given index.

getLicensesCount()

public int getLicensesCount()

Any applicable license URI.

repeated string licenses = 337642578;

Returns
Type Description
int

The count of licenses.

getLicensesList()

public ProtocolStringList getLicensesList()

Any applicable license URI.

repeated string licenses = 337642578;

Returns
Type Description
ProtocolStringList

A list containing the licenses.

getMutableLabels() (deprecated)

public Map<String,String> getMutableLabels()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,String>

getName()

public String getName()

Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.

optional string name = 3373707;

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.

optional string name = 3373707;

Returns
Type Description
ByteString

The bytes for name.

getRawDisk()

public RawDisk getRawDisk()

The parameters of the raw disk image.

optional .google.cloud.compute.v1.RawDisk raw_disk = 503113556;

Returns
Type Description
RawDisk

The rawDisk.

getRawDiskBuilder()

public RawDisk.Builder getRawDiskBuilder()

The parameters of the raw disk image.

optional .google.cloud.compute.v1.RawDisk raw_disk = 503113556;

Returns
Type Description
RawDisk.Builder

getRawDiskOrBuilder()

public RawDiskOrBuilder getRawDiskOrBuilder()

The parameters of the raw disk image.

optional .google.cloud.compute.v1.RawDisk raw_disk = 503113556;

Returns
Type Description
RawDiskOrBuilder

getSatisfiesPzi()

public boolean getSatisfiesPzi()

Output only. Reserved for future use.

optional bool satisfies_pzi = 480964257;

Returns
Type Description
boolean

The satisfiesPzi.

getSatisfiesPzs()

public boolean getSatisfiesPzs()

[Output Only] Reserved for future use.

optional bool satisfies_pzs = 480964267;

Returns
Type Description
boolean

The satisfiesPzs.

public String getSelfLink()

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Returns
Type Description
String

The selfLink.

getSelfLinkBytes()

public ByteString getSelfLinkBytes()

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Returns
Type Description
ByteString

The bytes for selfLink.

getShieldedInstanceInitialState()

public InitialStateConfig getShieldedInstanceInitialState()

Set the secure boot keys of shielded instance.

optional .google.cloud.compute.v1.InitialStateConfig shielded_instance_initial_state = 192356867;

Returns
Type Description
InitialStateConfig

The shieldedInstanceInitialState.

getShieldedInstanceInitialStateBuilder()

public InitialStateConfig.Builder getShieldedInstanceInitialStateBuilder()

Set the secure boot keys of shielded instance.

optional .google.cloud.compute.v1.InitialStateConfig shielded_instance_initial_state = 192356867;

Returns
Type Description
InitialStateConfig.Builder

getShieldedInstanceInitialStateOrBuilder()

public InitialStateConfigOrBuilder getShieldedInstanceInitialStateOrBuilder()

Set the secure boot keys of shielded instance.

optional .google.cloud.compute.v1.InitialStateConfig shielded_instance_initial_state = 192356867;

Returns
Type Description
InitialStateConfigOrBuilder

getSourceDisk()

public String getSourceDisk()

URL of the source disk used to create this image. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_disk = 451753793;

Returns
Type Description
String

The sourceDisk.

getSourceDiskBytes()

public ByteString getSourceDiskBytes()

URL of the source disk used to create this image. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_disk = 451753793;

Returns
Type Description
ByteString

The bytes for sourceDisk.

getSourceDiskEncryptionKey()

public CustomerEncryptionKey getSourceDiskEncryptionKey()

The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_disk_encryption_key = 531501153;

Returns
Type Description
CustomerEncryptionKey

The sourceDiskEncryptionKey.

getSourceDiskEncryptionKeyBuilder()

public CustomerEncryptionKey.Builder getSourceDiskEncryptionKeyBuilder()

The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_disk_encryption_key = 531501153;

Returns
Type Description
CustomerEncryptionKey.Builder

getSourceDiskEncryptionKeyOrBuilder()

public CustomerEncryptionKeyOrBuilder getSourceDiskEncryptionKeyOrBuilder()

The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_disk_encryption_key = 531501153;

Returns
Type Description
CustomerEncryptionKeyOrBuilder

getSourceDiskId()

public String getSourceDiskId()

[Output Only] The ID value of the disk used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given disk name.

optional string source_disk_id = 454190809;

Returns
Type Description
String

The sourceDiskId.

getSourceDiskIdBytes()

public ByteString getSourceDiskIdBytes()

[Output Only] The ID value of the disk used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given disk name.

optional string source_disk_id = 454190809;

Returns
Type Description
ByteString

The bytes for sourceDiskId.

getSourceImage()

public String getSourceImage()

URL of the source image used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ images/image_name - projects/project_id/global/images/image_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_image = 50443319;

Returns
Type Description
String

The sourceImage.

getSourceImageBytes()

public ByteString getSourceImageBytes()

URL of the source image used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ images/image_name - projects/project_id/global/images/image_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_image = 50443319;

Returns
Type Description
ByteString

The bytes for sourceImage.

getSourceImageEncryptionKey()

public CustomerEncryptionKey getSourceImageEncryptionKey()

The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;

Returns
Type Description
CustomerEncryptionKey

The sourceImageEncryptionKey.

getSourceImageEncryptionKeyBuilder()

public CustomerEncryptionKey.Builder getSourceImageEncryptionKeyBuilder()

The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;

Returns
Type Description
CustomerEncryptionKey.Builder

getSourceImageEncryptionKeyOrBuilder()

public CustomerEncryptionKeyOrBuilder getSourceImageEncryptionKeyOrBuilder()

The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;

Returns
Type Description
CustomerEncryptionKeyOrBuilder

getSourceImageId()

public String getSourceImageId()

[Output Only] The ID value of the image used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given image name.

optional string source_image_id = 55328291;

Returns
Type Description
String

The sourceImageId.

getSourceImageIdBytes()

public ByteString getSourceImageIdBytes()

[Output Only] The ID value of the image used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given image name.

optional string source_image_id = 55328291;

Returns
Type Description
ByteString

The bytes for sourceImageId.

getSourceSnapshot()

public String getSourceSnapshot()

URL of the source snapshot used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ snapshots/snapshot_name - projects/project_id/global/snapshots/snapshot_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_snapshot = 126061928;

Returns
Type Description
String

The sourceSnapshot.

getSourceSnapshotBytes()

public ByteString getSourceSnapshotBytes()

URL of the source snapshot used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ snapshots/snapshot_name - projects/project_id/global/snapshots/snapshot_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_snapshot = 126061928;

Returns
Type Description
ByteString

The bytes for sourceSnapshot.

getSourceSnapshotEncryptionKey()

public CustomerEncryptionKey getSourceSnapshotEncryptionKey()

The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;

Returns
Type Description
CustomerEncryptionKey

The sourceSnapshotEncryptionKey.

getSourceSnapshotEncryptionKeyBuilder()

public CustomerEncryptionKey.Builder getSourceSnapshotEncryptionKeyBuilder()

The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;

Returns
Type Description
CustomerEncryptionKey.Builder

getSourceSnapshotEncryptionKeyOrBuilder()

public CustomerEncryptionKeyOrBuilder getSourceSnapshotEncryptionKeyOrBuilder()

The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;

Returns
Type Description
CustomerEncryptionKeyOrBuilder

getSourceSnapshotId()

public String getSourceSnapshotId()

[Output Only] The ID value of the snapshot used to create this image. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given snapshot name.

optional string source_snapshot_id = 98962258;

Returns
Type Description
String

The sourceSnapshotId.

getSourceSnapshotIdBytes()

public ByteString getSourceSnapshotIdBytes()

[Output Only] The ID value of the snapshot used to create this image. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given snapshot name.

optional string source_snapshot_id = 98962258;

Returns
Type Description
ByteString

The bytes for sourceSnapshotId.

getSourceType()

public String getSourceType()

The type of the image used to create this disk. The default and only valid value is RAW. Check the SourceType enum for the list of possible values.

optional string source_type = 452245726;

Returns
Type Description
String

The sourceType.

getSourceTypeBytes()

public ByteString getSourceTypeBytes()

The type of the image used to create this disk. The default and only valid value is RAW. Check the SourceType enum for the list of possible values.

optional string source_type = 452245726;

Returns
Type Description
ByteString

The bytes for sourceType.

getStatus()

public String getStatus()

[Output Only] The status of the image. An image can be used to create other resources, such as instances, only after the image has been successfully created and the status is set to READY. Possible values are FAILED, PENDING, or READY. Check the Status enum for the list of possible values.

optional string status = 181260274;

Returns
Type Description
String

The status.

getStatusBytes()

public ByteString getStatusBytes()

[Output Only] The status of the image. An image can be used to create other resources, such as instances, only after the image has been successfully created and the status is set to READY. Possible values are FAILED, PENDING, or READY. Check the Status enum for the list of possible values.

optional string status = 181260274;

Returns
Type Description
ByteString

The bytes for status.

getStorageLocations(int index)

public String getStorageLocations(int index)

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The storageLocations at the given index.

getStorageLocationsBytes(int index)

public ByteString getStorageLocationsBytes(int index)

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the storageLocations at the given index.

getStorageLocationsCount()

public int getStorageLocationsCount()

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Returns
Type Description
int

The count of storageLocations.

getStorageLocationsList()

public ProtocolStringList getStorageLocationsList()

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Returns
Type Description
ProtocolStringList

A list containing the storageLocations.

hasArchitecture()

public boolean hasArchitecture()

The architecture of the image. Valid values are ARM64 or X86_64. Check the Architecture enum for the list of possible values.

optional string architecture = 302803283;

Returns
Type Description
boolean

Whether the architecture field is set.

hasArchiveSizeBytes()

public boolean hasArchiveSizeBytes()

Size of the image tar.gz archive stored in Google Cloud Storage (in bytes).

optional int64 archive_size_bytes = 381093450;

Returns
Type Description
boolean

Whether the archiveSizeBytes field is set.

hasCreationTimestamp()

public boolean hasCreationTimestamp()

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Returns
Type Description
boolean

Whether the creationTimestamp field is set.

hasDeprecated()

public boolean hasDeprecated()

The deprecation status associated with this image.

optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;

Returns
Type Description
boolean

Whether the deprecated field is set.

hasDescription()

public boolean hasDescription()

An optional description of this resource. Provide this property when you create the resource.

optional string description = 422937596;

Returns
Type Description
boolean

Whether the description field is set.

hasDiskSizeGb()

public boolean hasDiskSizeGb()

Size of the image when restored onto a persistent disk (in GB).

optional int64 disk_size_gb = 316263735;

Returns
Type Description
boolean

Whether the diskSizeGb field is set.

hasEnableConfidentialCompute()

public boolean hasEnableConfidentialCompute()

Whether this image is created from a confidential compute mode disk. [Output Only]: This field is not set by user, but from source disk.

optional bool enable_confidential_compute = 102135228;

Returns
Type Description
boolean

Whether the enableConfidentialCompute field is set.

hasFamily()

public boolean hasFamily()

The name of the image family to which this image belongs. The image family name can be from a publicly managed image family provided by Compute Engine, or from a custom image family you create. For example, centos-stream-9 is a publicly available image family. For more information, see Image family best practices. When creating disks, you can specify an image family instead of a specific image name. The image family always returns its latest image that is not deprecated. The name of the image family must comply with RFC1035.

optional string family = 328751972;

Returns
Type Description
boolean

Whether the family field is set.

hasId()

public boolean hasId()

[Output Only] The unique identifier for the resource. This identifier is defined by the server.

optional uint64 id = 3355;

Returns
Type Description
boolean

Whether the id field is set.

hasImageEncryptionKey()

public boolean hasImageEncryptionKey()

Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later.

optional .google.cloud.compute.v1.CustomerEncryptionKey image_encryption_key = 379512583;

Returns
Type Description
boolean

Whether the imageEncryptionKey field is set.

hasKind()

public boolean hasKind()

[Output Only] Type of the resource. Always compute#image for images.

optional string kind = 3292052;

Returns
Type Description
boolean

Whether the kind field is set.

hasLabelFingerprint()

public boolean hasLabelFingerprint()

A fingerprint for the labels being applied to this image, which is essentially a hash of the labels used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an image.

optional string label_fingerprint = 178124825;

Returns
Type Description
boolean

Whether the labelFingerprint field is set.

hasName()

public boolean hasName()

Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.

optional string name = 3373707;

Returns
Type Description
boolean

Whether the name field is set.

hasRawDisk()

public boolean hasRawDisk()

The parameters of the raw disk image.

optional .google.cloud.compute.v1.RawDisk raw_disk = 503113556;

Returns
Type Description
boolean

Whether the rawDisk field is set.

hasSatisfiesPzi()

public boolean hasSatisfiesPzi()

Output only. Reserved for future use.

optional bool satisfies_pzi = 480964257;

Returns
Type Description
boolean

Whether the satisfiesPzi field is set.

hasSatisfiesPzs()

public boolean hasSatisfiesPzs()

[Output Only] Reserved for future use.

optional bool satisfies_pzs = 480964267;

Returns
Type Description
boolean

Whether the satisfiesPzs field is set.

public boolean hasSelfLink()

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Returns
Type Description
boolean

Whether the selfLink field is set.

hasShieldedInstanceInitialState()

public boolean hasShieldedInstanceInitialState()

Set the secure boot keys of shielded instance.

optional .google.cloud.compute.v1.InitialStateConfig shielded_instance_initial_state = 192356867;

Returns
Type Description
boolean

Whether the shieldedInstanceInitialState field is set.

hasSourceDisk()

public boolean hasSourceDisk()

URL of the source disk used to create this image. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_disk = 451753793;

Returns
Type Description
boolean

Whether the sourceDisk field is set.

hasSourceDiskEncryptionKey()

public boolean hasSourceDiskEncryptionKey()

The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_disk_encryption_key = 531501153;

Returns
Type Description
boolean

Whether the sourceDiskEncryptionKey field is set.

hasSourceDiskId()

public boolean hasSourceDiskId()

[Output Only] The ID value of the disk used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given disk name.

optional string source_disk_id = 454190809;

Returns
Type Description
boolean

Whether the sourceDiskId field is set.

hasSourceImage()

public boolean hasSourceImage()

URL of the source image used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ images/image_name - projects/project_id/global/images/image_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_image = 50443319;

Returns
Type Description
boolean

Whether the sourceImage field is set.

hasSourceImageEncryptionKey()

public boolean hasSourceImageEncryptionKey()

The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;

Returns
Type Description
boolean

Whether the sourceImageEncryptionKey field is set.

hasSourceImageId()

public boolean hasSourceImageId()

[Output Only] The ID value of the image used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given image name.

optional string source_image_id = 55328291;

Returns
Type Description
boolean

Whether the sourceImageId field is set.

hasSourceSnapshot()

public boolean hasSourceSnapshot()

URL of the source snapshot used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ snapshots/snapshot_name - projects/project_id/global/snapshots/snapshot_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_snapshot = 126061928;

Returns
Type Description
boolean

Whether the sourceSnapshot field is set.

hasSourceSnapshotEncryptionKey()

public boolean hasSourceSnapshotEncryptionKey()

The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;

Returns
Type Description
boolean

Whether the sourceSnapshotEncryptionKey field is set.

hasSourceSnapshotId()

public boolean hasSourceSnapshotId()

[Output Only] The ID value of the snapshot used to create this image. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given snapshot name.

optional string source_snapshot_id = 98962258;

Returns
Type Description
boolean

Whether the sourceSnapshotId field is set.

hasSourceType()

public boolean hasSourceType()

The type of the image used to create this disk. The default and only valid value is RAW. Check the SourceType enum for the list of possible values.

optional string source_type = 452245726;

Returns
Type Description
boolean

Whether the sourceType field is set.

hasStatus()

public boolean hasStatus()

[Output Only] The status of the image. An image can be used to create other resources, such as instances, only after the image has been successfully created and the status is set to READY. Possible values are FAILED, PENDING, or READY. Check the Status enum for the list of possible values.

optional string status = 181260274;

Returns
Type Description
boolean

Whether the status field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeDeprecated(DeprecationStatus value)

public Image.Builder mergeDeprecated(DeprecationStatus value)

The deprecation status associated with this image.

optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;

Parameter
Name Description
value DeprecationStatus
Returns
Type Description
Image.Builder

mergeFrom(Image other)

public Image.Builder mergeFrom(Image other)
Parameter
Name Description
other Image
Returns
Type Description
Image.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Image.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Image.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public Image.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
Image.Builder
Overrides

mergeImageEncryptionKey(CustomerEncryptionKey value)

public Image.Builder mergeImageEncryptionKey(CustomerEncryptionKey value)

Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later.

optional .google.cloud.compute.v1.CustomerEncryptionKey image_encryption_key = 379512583;

Parameter
Name Description
value CustomerEncryptionKey
Returns
Type Description
Image.Builder

mergeRawDisk(RawDisk value)

public Image.Builder mergeRawDisk(RawDisk value)

The parameters of the raw disk image.

optional .google.cloud.compute.v1.RawDisk raw_disk = 503113556;

Parameter
Name Description
value RawDisk
Returns
Type Description
Image.Builder

mergeShieldedInstanceInitialState(InitialStateConfig value)

public Image.Builder mergeShieldedInstanceInitialState(InitialStateConfig value)

Set the secure boot keys of shielded instance.

optional .google.cloud.compute.v1.InitialStateConfig shielded_instance_initial_state = 192356867;

Parameter
Name Description
value InitialStateConfig
Returns
Type Description
Image.Builder

mergeSourceDiskEncryptionKey(CustomerEncryptionKey value)

public Image.Builder mergeSourceDiskEncryptionKey(CustomerEncryptionKey value)

The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_disk_encryption_key = 531501153;

Parameter
Name Description
value CustomerEncryptionKey
Returns
Type Description
Image.Builder

mergeSourceImageEncryptionKey(CustomerEncryptionKey value)

public Image.Builder mergeSourceImageEncryptionKey(CustomerEncryptionKey value)

The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;

Parameter
Name Description
value CustomerEncryptionKey
Returns
Type Description
Image.Builder

mergeSourceSnapshotEncryptionKey(CustomerEncryptionKey value)

public Image.Builder mergeSourceSnapshotEncryptionKey(CustomerEncryptionKey value)

The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;

Parameter
Name Description
value CustomerEncryptionKey
Returns
Type Description
Image.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Image.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
Image.Builder
Overrides

putAllLabels(Map<String,String> values)

public Image.Builder putAllLabels(Map<String,String> values)

Labels to apply to this image. These can be later modified by the setLabels method.

map<string, string> labels = 500195327;

Parameter
Name Description
values Map<String,String>
Returns
Type Description
Image.Builder

putLabels(String key, String value)

public Image.Builder putLabels(String key, String value)

Labels to apply to this image. These can be later modified by the setLabels method.

map<string, string> labels = 500195327;

Parameters
Name Description
key String
value String
Returns
Type Description
Image.Builder

removeGuestOsFeatures(int index)

public Image.Builder removeGuestOsFeatures(int index)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameter
Name Description
index int
Returns
Type Description
Image.Builder

removeLabels(String key)

public Image.Builder removeLabels(String key)

Labels to apply to this image. These can be later modified by the setLabels method.

map<string, string> labels = 500195327;

Parameter
Name Description
key String
Returns
Type Description
Image.Builder

setArchitecture(String value)

public Image.Builder setArchitecture(String value)

The architecture of the image. Valid values are ARM64 or X86_64. Check the Architecture enum for the list of possible values.

optional string architecture = 302803283;

Parameter
Name Description
value String

The architecture to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setArchitectureBytes(ByteString value)

public Image.Builder setArchitectureBytes(ByteString value)

The architecture of the image. Valid values are ARM64 or X86_64. Check the Architecture enum for the list of possible values.

optional string architecture = 302803283;

Parameter
Name Description
value ByteString

The bytes for architecture to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setArchiveSizeBytes(long value)

public Image.Builder setArchiveSizeBytes(long value)

Size of the image tar.gz archive stored in Google Cloud Storage (in bytes).

optional int64 archive_size_bytes = 381093450;

Parameter
Name Description
value long

The archiveSizeBytes to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setCreationTimestamp(String value)

public Image.Builder setCreationTimestamp(String value)

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Parameter
Name Description
value String

The creationTimestamp to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setCreationTimestampBytes(ByteString value)

public Image.Builder setCreationTimestampBytes(ByteString value)

[Output Only] Creation timestamp in RFC3339 text format.

optional string creation_timestamp = 30525366;

Parameter
Name Description
value ByteString

The bytes for creationTimestamp to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setDeprecated(DeprecationStatus value)

public Image.Builder setDeprecated(DeprecationStatus value)

The deprecation status associated with this image.

optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;

Parameter
Name Description
value DeprecationStatus
Returns
Type Description
Image.Builder

setDeprecated(DeprecationStatus.Builder builderForValue)

public Image.Builder setDeprecated(DeprecationStatus.Builder builderForValue)

The deprecation status associated with this image.

optional .google.cloud.compute.v1.DeprecationStatus deprecated = 515138995;

Parameter
Name Description
builderForValue DeprecationStatus.Builder
Returns
Type Description
Image.Builder

setDescription(String value)

public Image.Builder setDescription(String value)

An optional description of this resource. Provide this property when you create the resource.

optional string description = 422937596;

Parameter
Name Description
value String

The description to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setDescriptionBytes(ByteString value)

public Image.Builder setDescriptionBytes(ByteString value)

An optional description of this resource. Provide this property when you create the resource.

optional string description = 422937596;

Parameter
Name Description
value ByteString

The bytes for description to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setDiskSizeGb(long value)

public Image.Builder setDiskSizeGb(long value)

Size of the image when restored onto a persistent disk (in GB).

optional int64 disk_size_gb = 316263735;

Parameter
Name Description
value long

The diskSizeGb to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setEnableConfidentialCompute(boolean value)

public Image.Builder setEnableConfidentialCompute(boolean value)

Whether this image is created from a confidential compute mode disk. [Output Only]: This field is not set by user, but from source disk.

optional bool enable_confidential_compute = 102135228;

Parameter
Name Description
value boolean

The enableConfidentialCompute to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setFamily(String value)

public Image.Builder setFamily(String value)

The name of the image family to which this image belongs. The image family name can be from a publicly managed image family provided by Compute Engine, or from a custom image family you create. For example, centos-stream-9 is a publicly available image family. For more information, see Image family best practices. When creating disks, you can specify an image family instead of a specific image name. The image family always returns its latest image that is not deprecated. The name of the image family must comply with RFC1035.

optional string family = 328751972;

Parameter
Name Description
value String

The family to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setFamilyBytes(ByteString value)

public Image.Builder setFamilyBytes(ByteString value)

The name of the image family to which this image belongs. The image family name can be from a publicly managed image family provided by Compute Engine, or from a custom image family you create. For example, centos-stream-9 is a publicly available image family. For more information, see Image family best practices. When creating disks, you can specify an image family instead of a specific image name. The image family always returns its latest image that is not deprecated. The name of the image family must comply with RFC1035.

optional string family = 328751972;

Parameter
Name Description
value ByteString

The bytes for family to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public Image.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
Image.Builder
Overrides

setGuestOsFeatures(int index, GuestOsFeature value)

public Image.Builder setGuestOsFeatures(int index, GuestOsFeature value)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameters
Name Description
index int
value GuestOsFeature
Returns
Type Description
Image.Builder

setGuestOsFeatures(int index, GuestOsFeature.Builder builderForValue)

public Image.Builder setGuestOsFeatures(int index, GuestOsFeature.Builder builderForValue)

A list of features to enable on the guest operating system. Applicable only for bootable images. To see a list of available options, see the guestOSfeatures[].type parameter.

repeated .google.cloud.compute.v1.GuestOsFeature guest_os_features = 79294545;

Parameters
Name Description
index int
builderForValue GuestOsFeature.Builder
Returns
Type Description
Image.Builder

setId(long value)

public Image.Builder setId(long value)

[Output Only] The unique identifier for the resource. This identifier is defined by the server.

optional uint64 id = 3355;

Parameter
Name Description
value long

The id to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setImageEncryptionKey(CustomerEncryptionKey value)

public Image.Builder setImageEncryptionKey(CustomerEncryptionKey value)

Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later.

optional .google.cloud.compute.v1.CustomerEncryptionKey image_encryption_key = 379512583;

Parameter
Name Description
value CustomerEncryptionKey
Returns
Type Description
Image.Builder

setImageEncryptionKey(CustomerEncryptionKey.Builder builderForValue)

public Image.Builder setImageEncryptionKey(CustomerEncryptionKey.Builder builderForValue)

Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later.

optional .google.cloud.compute.v1.CustomerEncryptionKey image_encryption_key = 379512583;

Parameter
Name Description
builderForValue CustomerEncryptionKey.Builder
Returns
Type Description
Image.Builder

setKind(String value)

public Image.Builder setKind(String value)

[Output Only] Type of the resource. Always compute#image for images.

optional string kind = 3292052;

Parameter
Name Description
value String

The kind to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setKindBytes(ByteString value)

public Image.Builder setKindBytes(ByteString value)

[Output Only] Type of the resource. Always compute#image for images.

optional string kind = 3292052;

Parameter
Name Description
value ByteString

The bytes for kind to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setLabelFingerprint(String value)

public Image.Builder setLabelFingerprint(String value)

A fingerprint for the labels being applied to this image, which is essentially a hash of the labels used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an image.

optional string label_fingerprint = 178124825;

Parameter
Name Description
value String

The labelFingerprint to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setLabelFingerprintBytes(ByteString value)

public Image.Builder setLabelFingerprintBytes(ByteString value)

A fingerprint for the labels being applied to this image, which is essentially a hash of the labels used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an image.

optional string label_fingerprint = 178124825;

Parameter
Name Description
value ByteString

The bytes for labelFingerprint to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setLicenseCodes(int index, long value)

public Image.Builder setLicenseCodes(int index, long value)

Integer license codes indicating which licenses are attached to this image.

repeated int64 license_codes = 45482664;

Parameters
Name Description
index int

The index to set the value at.

value long

The licenseCodes to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setLicenses(int index, String value)

public Image.Builder setLicenses(int index, String value)

Any applicable license URI.

repeated string licenses = 337642578;

Parameters
Name Description
index int

The index to set the value at.

value String

The licenses to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setName(String value)

public Image.Builder setName(String value)

Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.

optional string name = 3373707;

Parameter
Name Description
value String

The name to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Image.Builder setNameBytes(ByteString value)

Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.

optional string name = 3373707;

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setRawDisk(RawDisk value)

public Image.Builder setRawDisk(RawDisk value)

The parameters of the raw disk image.

optional .google.cloud.compute.v1.RawDisk raw_disk = 503113556;

Parameter
Name Description
value RawDisk
Returns
Type Description
Image.Builder

setRawDisk(RawDisk.Builder builderForValue)

public Image.Builder setRawDisk(RawDisk.Builder builderForValue)

The parameters of the raw disk image.

optional .google.cloud.compute.v1.RawDisk raw_disk = 503113556;

Parameter
Name Description
builderForValue RawDisk.Builder
Returns
Type Description
Image.Builder

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public Image.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
Image.Builder
Overrides

setSatisfiesPzi(boolean value)

public Image.Builder setSatisfiesPzi(boolean value)

Output only. Reserved for future use.

optional bool satisfies_pzi = 480964257;

Parameter
Name Description
value boolean

The satisfiesPzi to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSatisfiesPzs(boolean value)

public Image.Builder setSatisfiesPzs(boolean value)

[Output Only] Reserved for future use.

optional bool satisfies_pzs = 480964267;

Parameter
Name Description
value boolean

The satisfiesPzs to set.

Returns
Type Description
Image.Builder

This builder for chaining.

public Image.Builder setSelfLink(String value)

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Parameter
Name Description
value String

The selfLink to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSelfLinkBytes(ByteString value)

public Image.Builder setSelfLinkBytes(ByteString value)

[Output Only] Server-defined URL for the resource.

optional string self_link = 456214797;

Parameter
Name Description
value ByteString

The bytes for selfLink to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setShieldedInstanceInitialState(InitialStateConfig value)

public Image.Builder setShieldedInstanceInitialState(InitialStateConfig value)

Set the secure boot keys of shielded instance.

optional .google.cloud.compute.v1.InitialStateConfig shielded_instance_initial_state = 192356867;

Parameter
Name Description
value InitialStateConfig
Returns
Type Description
Image.Builder

setShieldedInstanceInitialState(InitialStateConfig.Builder builderForValue)

public Image.Builder setShieldedInstanceInitialState(InitialStateConfig.Builder builderForValue)

Set the secure boot keys of shielded instance.

optional .google.cloud.compute.v1.InitialStateConfig shielded_instance_initial_state = 192356867;

Parameter
Name Description
builderForValue InitialStateConfig.Builder
Returns
Type Description
Image.Builder

setSourceDisk(String value)

public Image.Builder setSourceDisk(String value)

URL of the source disk used to create this image. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_disk = 451753793;

Parameter
Name Description
value String

The sourceDisk to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceDiskBytes(ByteString value)

public Image.Builder setSourceDiskBytes(ByteString value)

URL of the source disk used to create this image. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone /disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_disk = 451753793;

Parameter
Name Description
value ByteString

The bytes for sourceDisk to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceDiskEncryptionKey(CustomerEncryptionKey value)

public Image.Builder setSourceDiskEncryptionKey(CustomerEncryptionKey value)

The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_disk_encryption_key = 531501153;

Parameter
Name Description
value CustomerEncryptionKey
Returns
Type Description
Image.Builder

setSourceDiskEncryptionKey(CustomerEncryptionKey.Builder builderForValue)

public Image.Builder setSourceDiskEncryptionKey(CustomerEncryptionKey.Builder builderForValue)

The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_disk_encryption_key = 531501153;

Parameter
Name Description
builderForValue CustomerEncryptionKey.Builder
Returns
Type Description
Image.Builder

setSourceDiskId(String value)

public Image.Builder setSourceDiskId(String value)

[Output Only] The ID value of the disk used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given disk name.

optional string source_disk_id = 454190809;

Parameter
Name Description
value String

The sourceDiskId to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceDiskIdBytes(ByteString value)

public Image.Builder setSourceDiskIdBytes(ByteString value)

[Output Only] The ID value of the disk used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given disk name.

optional string source_disk_id = 454190809;

Parameter
Name Description
value ByteString

The bytes for sourceDiskId to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceImage(String value)

public Image.Builder setSourceImage(String value)

URL of the source image used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ images/image_name - projects/project_id/global/images/image_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_image = 50443319;

Parameter
Name Description
value String

The sourceImage to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceImageBytes(ByteString value)

public Image.Builder setSourceImageBytes(ByteString value)

URL of the source image used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ images/image_name - projects/project_id/global/images/image_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_image = 50443319;

Parameter
Name Description
value ByteString

The bytes for sourceImage to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceImageEncryptionKey(CustomerEncryptionKey value)

public Image.Builder setSourceImageEncryptionKey(CustomerEncryptionKey value)

The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;

Parameter
Name Description
value CustomerEncryptionKey
Returns
Type Description
Image.Builder

setSourceImageEncryptionKey(CustomerEncryptionKey.Builder builderForValue)

public Image.Builder setSourceImageEncryptionKey(CustomerEncryptionKey.Builder builderForValue)

The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_image_encryption_key = 381503659;

Parameter
Name Description
builderForValue CustomerEncryptionKey.Builder
Returns
Type Description
Image.Builder

setSourceImageId(String value)

public Image.Builder setSourceImageId(String value)

[Output Only] The ID value of the image used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given image name.

optional string source_image_id = 55328291;

Parameter
Name Description
value String

The sourceImageId to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceImageIdBytes(ByteString value)

public Image.Builder setSourceImageIdBytes(ByteString value)

[Output Only] The ID value of the image used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given image name.

optional string source_image_id = 55328291;

Parameter
Name Description
value ByteString

The bytes for sourceImageId to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceSnapshot(String value)

public Image.Builder setSourceSnapshot(String value)

URL of the source snapshot used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ snapshots/snapshot_name - projects/project_id/global/snapshots/snapshot_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_snapshot = 126061928;

Parameter
Name Description
value String

The sourceSnapshot to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceSnapshotBytes(ByteString value)

public Image.Builder setSourceSnapshotBytes(ByteString value)

URL of the source snapshot used to create this image. The following are valid formats for the URL: - https://www.googleapis.com/compute/v1/projects/project_id/global/ snapshots/snapshot_name - projects/project_id/global/snapshots/snapshot_name In order to create an image, you must provide the full or partial URL of one of the following: - The rawDisk.source URL - The sourceDisk URL - The sourceImage URL - The sourceSnapshot URL

optional string source_snapshot = 126061928;

Parameter
Name Description
value ByteString

The bytes for sourceSnapshot to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceSnapshotEncryptionKey(CustomerEncryptionKey value)

public Image.Builder setSourceSnapshotEncryptionKey(CustomerEncryptionKey value)

The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;

Parameter
Name Description
value CustomerEncryptionKey
Returns
Type Description
Image.Builder

setSourceSnapshotEncryptionKey(CustomerEncryptionKey.Builder builderForValue)

public Image.Builder setSourceSnapshotEncryptionKey(CustomerEncryptionKey.Builder builderForValue)

The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.

optional .google.cloud.compute.v1.CustomerEncryptionKey source_snapshot_encryption_key = 303679322;

Parameter
Name Description
builderForValue CustomerEncryptionKey.Builder
Returns
Type Description
Image.Builder

setSourceSnapshotId(String value)

public Image.Builder setSourceSnapshotId(String value)

[Output Only] The ID value of the snapshot used to create this image. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given snapshot name.

optional string source_snapshot_id = 98962258;

Parameter
Name Description
value String

The sourceSnapshotId to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceSnapshotIdBytes(ByteString value)

public Image.Builder setSourceSnapshotIdBytes(ByteString value)

[Output Only] The ID value of the snapshot used to create this image. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given snapshot name.

optional string source_snapshot_id = 98962258;

Parameter
Name Description
value ByteString

The bytes for sourceSnapshotId to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceType(String value)

public Image.Builder setSourceType(String value)

The type of the image used to create this disk. The default and only valid value is RAW. Check the SourceType enum for the list of possible values.

optional string source_type = 452245726;

Parameter
Name Description
value String

The sourceType to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setSourceTypeBytes(ByteString value)

public Image.Builder setSourceTypeBytes(ByteString value)

The type of the image used to create this disk. The default and only valid value is RAW. Check the SourceType enum for the list of possible values.

optional string source_type = 452245726;

Parameter
Name Description
value ByteString

The bytes for sourceType to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setStatus(String value)

public Image.Builder setStatus(String value)

[Output Only] The status of the image. An image can be used to create other resources, such as instances, only after the image has been successfully created and the status is set to READY. Possible values are FAILED, PENDING, or READY. Check the Status enum for the list of possible values.

optional string status = 181260274;

Parameter
Name Description
value String

The status to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setStatusBytes(ByteString value)

public Image.Builder setStatusBytes(ByteString value)

[Output Only] The status of the image. An image can be used to create other resources, such as instances, only after the image has been successfully created and the status is set to READY. Possible values are FAILED, PENDING, or READY. Check the Status enum for the list of possible values.

optional string status = 181260274;

Parameter
Name Description
value ByteString

The bytes for status to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setStorageLocations(int index, String value)

public Image.Builder setStorageLocations(int index, String value)

Cloud Storage bucket storage location of the image (regional or multi-regional).

repeated string storage_locations = 328005274;

Parameters
Name Description
index int

The index to set the value at.

value String

The storageLocations to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final Image.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
Image.Builder
Overrides