compute  v1
Public Member Functions | Static Public Member Functions | List of all members
google_compute_api::AttachedDisk Class Reference

#include <attached_disk.h>

Inheritance diagram for google_compute_api::AttachedDisk:

Public Member Functions

 AttachedDisk (const Json::Value &storage)
 
 AttachedDisk (Json::Value *storage)
 
virtual ~AttachedDisk ()
 
const StringPiece GetTypeName () const
 
bool has_auto_delete () const
 
void clear_auto_delete ()
 
bool get_auto_delete () const
 
void set_auto_delete (bool value)
 
bool has_boot () const
 
void clear_boot ()
 
bool get_boot () const
 
void set_boot (bool value)
 
bool has_device_name () const
 
void clear_device_name ()
 
const StringPiece get_device_name () const
 
void set_device_name (const StringPiece &value)
 
bool has_disk_encryption_key () const
 
void clear_disk_encryption_key ()
 
const CustomerEncryptionKey get_disk_encryption_key () const
 
CustomerEncryptionKey mutable_diskEncryptionKey ()
 
bool has_guest_os_features () const
 
void clear_guest_os_features ()
 
const client::JsonCppArray< GuestOsFeatureget_guest_os_features () const
 
client::JsonCppArray< GuestOsFeaturemutable_guestOsFeatures ()
 
bool has_index () const
 
void clear_index ()
 
int32 get_index () const
 
void set_index (int32 value)
 
bool has_initialize_params () const
 
void clear_initialize_params ()
 
const AttachedDiskInitializeParams get_initialize_params () const
 
AttachedDiskInitializeParams mutable_initializeParams ()
 
bool has_interface () const
 
void clear_interface ()
 
const StringPiece get_interface () const
 
void set_interface (const StringPiece &value)
 
bool has_kind () const
 
void clear_kind ()
 
const StringPiece get_kind () const
 
void set_kind (const StringPiece &value)
 
bool has_licenses () const
 
void clear_licenses ()
 
const client::JsonCppArray< string > get_licenses () const
 
client::JsonCppArray< string > mutable_licenses ()
 
bool has_mode () const
 
void clear_mode ()
 
const StringPiece get_mode () const
 
void set_mode (const StringPiece &value)
 
bool has_source () const
 
void clear_source ()
 
const StringPiece get_source () const
 
void set_source (const StringPiece &value)
 
bool has_type () const
 
void clear_type ()
 
const StringPiece get_type () const
 
void set_type (const StringPiece &value)
 

Static Public Member Functions

static AttachedDiskNew ()
 

Detailed Description

An instance-attached disk resource.

Constructor & Destructor Documentation

◆ AttachedDisk() [1/2]

google_compute_api::AttachedDisk::AttachedDisk ( const Json::Value &  storage)
explicit

Standard constructor for an immutable data object instance.

Parameters
[in]storageThe underlying data storage for this instance.

◆ AttachedDisk() [2/2]

google_compute_api::AttachedDisk::AttachedDisk ( Json::Value *  storage)
explicit

Standard constructor for a mutable data object instance.

Parameters
[in]storageThe underlying data storage for this instance.

◆ ~AttachedDisk()

google_compute_api::AttachedDisk::~AttachedDisk ( )
virtual

Standard destructor.

Member Function Documentation

◆ clear_auto_delete()

void google_compute_api::AttachedDisk::clear_auto_delete ( )
inline

Clears the 'autoDelete' attribute.

◆ clear_boot()

void google_compute_api::AttachedDisk::clear_boot ( )
inline

Clears the 'boot' attribute.

◆ clear_device_name()

void google_compute_api::AttachedDisk::clear_device_name ( )
inline

Clears the 'deviceName' attribute.

◆ clear_disk_encryption_key()

void google_compute_api::AttachedDisk::clear_disk_encryption_key ( )
inline

Clears the 'diskEncryptionKey' attribute.

◆ clear_guest_os_features()

void google_compute_api::AttachedDisk::clear_guest_os_features ( )
inline

Clears the 'guestOsFeatures' attribute.

◆ clear_index()

void google_compute_api::AttachedDisk::clear_index ( )
inline

Clears the 'index' attribute.

◆ clear_initialize_params()

void google_compute_api::AttachedDisk::clear_initialize_params ( )
inline

Clears the 'initializeParams' attribute.

◆ clear_interface()

void google_compute_api::AttachedDisk::clear_interface ( )
inline

Clears the 'interface' attribute.

◆ clear_kind()

void google_compute_api::AttachedDisk::clear_kind ( )
inline

Clears the 'kind' attribute.

◆ clear_licenses()

void google_compute_api::AttachedDisk::clear_licenses ( )
inline

Clears the 'licenses' attribute.

◆ clear_mode()

void google_compute_api::AttachedDisk::clear_mode ( )
inline

Clears the 'mode' attribute.

◆ clear_source()

void google_compute_api::AttachedDisk::clear_source ( )
inline

Clears the 'source' attribute.

◆ clear_type()

void google_compute_api::AttachedDisk::clear_type ( )
inline

Clears the 'type' attribute.

◆ get_auto_delete()

bool google_compute_api::AttachedDisk::get_auto_delete ( ) const
inline

Get the value of the 'autoDelete' attribute.

◆ get_boot()

bool google_compute_api::AttachedDisk::get_boot ( ) const
inline

Get the value of the 'boot' attribute.

◆ get_device_name()

const StringPiece google_compute_api::AttachedDisk::get_device_name ( ) const
inline

Get the value of the 'deviceName' attribute.

◆ get_disk_encryption_key()

const CustomerEncryptionKey google_compute_api::AttachedDisk::get_disk_encryption_key ( ) const

Get a reference to the value of the 'diskEncryptionKey' attribute.

◆ get_guest_os_features()

const client::JsonCppArray<GuestOsFeature > google_compute_api::AttachedDisk::get_guest_os_features ( ) const

Get a reference to the value of the 'guestOsFeatures' attribute.

◆ get_index()

int32 google_compute_api::AttachedDisk::get_index ( ) const
inline

Get the value of the 'index' attribute.

◆ get_initialize_params()

const AttachedDiskInitializeParams google_compute_api::AttachedDisk::get_initialize_params ( ) const

Get a reference to the value of the 'initializeParams' attribute.

◆ get_interface()

const StringPiece google_compute_api::AttachedDisk::get_interface ( ) const
inline

Get the value of the 'interface' attribute.

◆ get_kind()

const StringPiece google_compute_api::AttachedDisk::get_kind ( ) const
inline

Get the value of the 'kind' attribute.

◆ get_licenses()

const client::JsonCppArray<string > google_compute_api::AttachedDisk::get_licenses ( ) const
inline

Get a reference to the value of the 'licenses' attribute.

◆ get_mode()

const StringPiece google_compute_api::AttachedDisk::get_mode ( ) const
inline

Get the value of the 'mode' attribute.

◆ get_source()

const StringPiece google_compute_api::AttachedDisk::get_source ( ) const
inline

Get the value of the 'source' attribute.

◆ get_type()

const StringPiece google_compute_api::AttachedDisk::get_type ( ) const
inline

Get the value of the 'type' attribute.

◆ GetTypeName()

const StringPiece google_compute_api::AttachedDisk::GetTypeName ( ) const
inline

Returns a string denoting the type of this data object.

Returns
google_compute_api::AttachedDisk

◆ has_auto_delete()

bool google_compute_api::AttachedDisk::has_auto_delete ( ) const
inline

Determine if the 'autoDelete' attribute was set.

Returns
true if the 'autoDelete' attribute was set.

◆ has_boot()

bool google_compute_api::AttachedDisk::has_boot ( ) const
inline

Determine if the 'boot' attribute was set.

Returns
true if the 'boot' attribute was set.

◆ has_device_name()

bool google_compute_api::AttachedDisk::has_device_name ( ) const
inline

Determine if the 'deviceName' attribute was set.

Returns
true if the 'deviceName' attribute was set.

◆ has_disk_encryption_key()

bool google_compute_api::AttachedDisk::has_disk_encryption_key ( ) const
inline

Determine if the 'diskEncryptionKey' attribute was set.

Returns
true if the 'diskEncryptionKey' attribute was set.

◆ has_guest_os_features()

bool google_compute_api::AttachedDisk::has_guest_os_features ( ) const
inline

Determine if the 'guestOsFeatures' attribute was set.

Returns
true if the 'guestOsFeatures' attribute was set.

◆ has_index()

bool google_compute_api::AttachedDisk::has_index ( ) const
inline

Determine if the 'index' attribute was set.

Returns
true if the 'index' attribute was set.

◆ has_initialize_params()

bool google_compute_api::AttachedDisk::has_initialize_params ( ) const
inline

Determine if the 'initializeParams' attribute was set.

Returns
true if the 'initializeParams' attribute was set.

◆ has_interface()

bool google_compute_api::AttachedDisk::has_interface ( ) const
inline

Determine if the 'interface' attribute was set.

Returns
true if the 'interface' attribute was set.

◆ has_kind()

bool google_compute_api::AttachedDisk::has_kind ( ) const
inline

Determine if the 'kind' attribute was set.

Returns
true if the 'kind' attribute was set.

◆ has_licenses()

bool google_compute_api::AttachedDisk::has_licenses ( ) const
inline

Determine if the 'licenses' attribute was set.

Returns
true if the 'licenses' attribute was set.

◆ has_mode()

bool google_compute_api::AttachedDisk::has_mode ( ) const
inline

Determine if the 'mode' attribute was set.

Returns
true if the 'mode' attribute was set.

◆ has_source()

bool google_compute_api::AttachedDisk::has_source ( ) const
inline

Determine if the 'source' attribute was set.

Returns
true if the 'source' attribute was set.

◆ has_type()

bool google_compute_api::AttachedDisk::has_type ( ) const
inline

Determine if the 'type' attribute was set.

Returns
true if the 'type' attribute was set.

◆ mutable_diskEncryptionKey()

CustomerEncryptionKey google_compute_api::AttachedDisk::mutable_diskEncryptionKey ( )

Gets a reference to a mutable value of the 'diskEncryptionKey' property.

Encrypts or decrypts a disk using a customer-supplied encryption key.

If you are creating a new disk, this field encrypts the new disk using an encryption key that you provide. If you are attaching an existing disk that is already encrypted, this field decrypts the disk using the customer- supplied encryption key.

If you encrypt a disk using a customer-supplied key, you must provide the same key again when you attempt to use this resource at a later time. For example, you must provide the key when you create a snapshot or an image from the disk or when you attach the disk to a virtual machine instance.

If you do not provide an encryption key, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the disk later.

Instance templates do not store customer-supplied encryption keys, so you cannot use your own keys to encrypt disks in a managed instance group.

Returns
The result can be modified to change the attribute value.

◆ mutable_guestOsFeatures()

client::JsonCppArray<GuestOsFeature > google_compute_api::AttachedDisk::mutable_guestOsFeatures ( )

Gets a reference to a mutable value of the 'guestOsFeatures' property.

A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options.

Returns
The result can be modified to change the attribute value.

◆ mutable_initializeParams()

AttachedDiskInitializeParams google_compute_api::AttachedDisk::mutable_initializeParams ( )

Gets a reference to a mutable value of the 'initializeParams' property.

[Input Only] Specifies the parameters for a new disk that will be created alongside the new instance. Use initialization parameters to create boot disks or local SSDs attached to the new instance.

This property is mutually exclusive with the source property; you can only define one or the other, but not both.

Returns
The result can be modified to change the attribute value.

◆ mutable_licenses()

client::JsonCppArray<string > google_compute_api::AttachedDisk::mutable_licenses ( )
inline

Gets a reference to a mutable value of the 'licenses' property.

[Output Only] Any valid publicly visible licenses.

Returns
The result can be modified to change the attribute value.

◆ New()

AttachedDisk * google_compute_api::AttachedDisk::New ( )
static

Creates a new default instance.

Returns
Ownership is passed back to the caller.

◆ set_auto_delete()

void google_compute_api::AttachedDisk::set_auto_delete ( bool  value)
inline

Change the 'autoDelete' attribute.

Specifies whether the disk will be auto-deleted when the instance is deleted (but not when the disk is detached from the instance).

Parameters
[in]valueThe new value.

◆ set_boot()

void google_compute_api::AttachedDisk::set_boot ( bool  value)
inline

Change the 'boot' attribute.

Indicates that this is a boot disk. The virtual machine will use the first partition of the disk for its root filesystem.

Parameters
[in]valueThe new value.

◆ set_device_name()

void google_compute_api::AttachedDisk::set_device_name ( const StringPiece &  value)
inline

Change the 'deviceName' attribute.

Specifies a unique device name of your choice that is reflected into the /dev/disk/by-id/google-* tree of a Linux operating system running within the instance. This name can be used to reference the device for mounting, resizing, and so on, from within the instance.

If not specified, the server chooses a default device name to apply to this disk, in the form persistent-disk-x, where x is a number assigned by Google Compute Engine. This field is only applicable for persistent disks.

Parameters
[in]valueThe new value.

◆ set_index()

void google_compute_api::AttachedDisk::set_index ( int32  value)
inline

Change the 'index' attribute.

[Output Only] A zero-based index to this disk, where 0 is reserved for the boot disk. If you have many disks attached to an instance, each disk would have a unique index number.

Parameters
[in]valueThe new value.

◆ set_interface()

void google_compute_api::AttachedDisk::set_interface ( const StringPiece &  value)
inline

Change the 'interface' attribute.

Specifies the disk interface to use for attaching this disk, which is either SCSI or NVME. The default is SCSI. Persistent disks must always use SCSI and the request will fail if you attempt to attach a persistent disk in any other format than SCSI. Local SSDs can use either NVME or SCSI. For performance characteristics of SCSI over NVMe, see Local SSD performance.

Parameters
[in]valueThe new value.

◆ set_kind()

void google_compute_api::AttachedDisk::set_kind ( const StringPiece &  value)
inline

Change the 'kind' attribute.

[Output Only] Type of the resource. Always compute::attachedDisk for attached disks.

Parameters
[in]valueThe new value.

◆ set_mode()

void google_compute_api::AttachedDisk::set_mode ( const StringPiece &  value)
inline

Change the 'mode' attribute.

The mode in which to attach this disk, either READ_WRITE or READ_ONLY. If not specified, the default is to attach the disk in READ_WRITE mode.

Parameters
[in]valueThe new value.

◆ set_source()

void google_compute_api::AttachedDisk::set_source ( const StringPiece &  value)
inline

Change the 'source' attribute.

Specifies a valid partial or full URL to an existing Persistent Disk resource. When creating a new instance, one of initializeParams.sourceImage or disks.source is required except for local SSD.

If desired, you can also attach existing non-root persistent disks using this property. This field is only applicable for persistent disks.

Note that for InstanceTemplate, specify the disk name, not the URL for the disk.

Parameters
[in]valueThe new value.

◆ set_type()

void google_compute_api::AttachedDisk::set_type ( const StringPiece &  value)
inline

Change the 'type' attribute.

Specifies the type of the disk, either SCRATCH or PERSISTENT. If not specified, the default is PERSISTENT.

Parameters
[in]valueThe new value.

The documentation for this class was generated from the following files: