class Azure::Compute::Mgmt::V2019_03_01::Models::CreationData

Data used when creating a disk.

Attributes

create_option[RW]

@return [DiskCreateOption] This enumerates the possible sources of a disk's creation. Possible values include: 'Empty', 'Attach', 'FromImage', 'Import', 'Copy', 'Restore', 'Upload'

image_reference[RW]

@return [ImageDiskReference] Disk source information.

source_resource_id[RW]

@return [String] If createOption is Copy, this is the ARM id of the source snapshot or disk.

source_unique_id[RW]

@return [String] If this field is set, this is the unique id identifying the source of this resource.

source_uri[RW]

@return [String] If createOption is Import, this is the URI of a blob to be imported into a managed disk.

storage_account_id[RW]

@return [String] If createOption is Import, the Azure Resource Manager identifier of the storage account containing the blob to import as a disk. Required only if the blob is in a different subscription

upload_size_bytes[RW]

@return [Integer] If createOption is Upload, this is the size of the contents of the upload including the VHD footer. This value should be between 20972032 (20 MiB + 512 bytes for the VHD footer) and 35183298347520 bytes (32 TiB + 512 bytes for the VHD footer).

Public Class Methods

mapper() click to toggle source

Mapper for CreationData class as Ruby Hash. This will be used for serialization/deserialization.

# File lib/2019-03-01/generated/azure_mgmt_compute/models/creation_data.rb, line 51
def self.mapper()
  {
    client_side_validation: true,
    required: false,
    serialized_name: 'CreationData',
    type: {
      name: 'Composite',
      class_name: 'CreationData',
      model_properties: {
        create_option: {
          client_side_validation: true,
          required: true,
          serialized_name: 'createOption',
          type: {
            name: 'String'
          }
        },
        storage_account_id: {
          client_side_validation: true,
          required: false,
          serialized_name: 'storageAccountId',
          type: {
            name: 'String'
          }
        },
        image_reference: {
          client_side_validation: true,
          required: false,
          serialized_name: 'imageReference',
          type: {
            name: 'Composite',
            class_name: 'ImageDiskReference'
          }
        },
        source_uri: {
          client_side_validation: true,
          required: false,
          serialized_name: 'sourceUri',
          type: {
            name: 'String'
          }
        },
        source_resource_id: {
          client_side_validation: true,
          required: false,
          serialized_name: 'sourceResourceId',
          type: {
            name: 'String'
          }
        },
        source_unique_id: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'sourceUniqueId',
          type: {
            name: 'String'
          }
        },
        upload_size_bytes: {
          client_side_validation: true,
          required: false,
          serialized_name: 'uploadSizeBytes',
          type: {
            name: 'Number'
          }
        }
      }
    }
  }
end