Class CreationData
java.lang.Object
com.microsoft.azure.management.compute.CreationData
Data used when creating a disk.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionGet this enumerates the possible sources of a disk's creation.Get required if creating from a Gallery Image.Get disk source information.Get logical sector size in bytes for Ultra disks.Get if createOption is Copy, this is the ARM id of the source snapshot or disk.Get if this field is set, this is the unique id identifying the source of this resource.Get if createOption is Import, this is the URI of a blob to be imported into a managed disk.Get required if createOption is Import.Get if createOption is Upload, this is the size of the contents of the upload including the VHD footer.withCreateOption
(DiskCreateOption createOption) Set this enumerates the possible sources of a disk's creation.withGalleryImageReference
(ImageDiskReference galleryImageReference) Set required if creating from a Gallery Image.withImageReference
(ImageDiskReference imageReference) Set disk source information.withLogicalSectorSize
(Integer logicalSectorSize) Set logical sector size in bytes for Ultra disks.withSourceResourceId
(String sourceResourceId) Set if createOption is Copy, this is the ARM id of the source snapshot or disk.withSourceUri
(String sourceUri) Set if createOption is Import, this is the URI of a blob to be imported into a managed disk.withStorageAccountId
(String storageAccountId) Set required if createOption is Import.withUploadSizeBytes
(Long uploadSizeBytes) Set if createOption is Upload, this is the size of the contents of the upload including the VHD footer.
-
Constructor Details
-
CreationData
public CreationData()
-
-
Method Details
-
createOption
Get this enumerates the possible sources of a disk's creation. Possible values include: 'Empty', 'Attach', 'FromImage', 'Import', 'Copy', 'Restore', 'Upload'.- Returns:
- the createOption value
-
withCreateOption
Set this enumerates the possible sources of a disk's creation. Possible values include: 'Empty', 'Attach', 'FromImage', 'Import', 'Copy', 'Restore', 'Upload'.- Parameters:
createOption
- the createOption value to set- Returns:
- the CreationData object itself.
-
storageAccountId
Get required if createOption is Import. The Azure Resource Manager identifier of the storage account containing the blob to import as a disk.- Returns:
- the storageAccountId value
-
withStorageAccountId
Set required if createOption is Import. The Azure Resource Manager identifier of the storage account containing the blob to import as a disk.- Parameters:
storageAccountId
- the storageAccountId value to set- Returns:
- the CreationData object itself.
-
imageReference
Get disk source information.- Returns:
- the imageReference value
-
withImageReference
Set disk source information.- Parameters:
imageReference
- the imageReference value to set- Returns:
- the CreationData object itself.
-
galleryImageReference
Get required if creating from a Gallery Image. The id of the ImageDiskReference will be the ARM id of the shared galley image version from which to create a disk.- Returns:
- the galleryImageReference value
-
withGalleryImageReference
Set required if creating from a Gallery Image. The id of the ImageDiskReference will be the ARM id of the shared galley image version from which to create a disk.- Parameters:
galleryImageReference
- the galleryImageReference value to set- Returns:
- the CreationData object itself.
-
sourceUri
Get if createOption is Import, this is the URI of a blob to be imported into a managed disk.- Returns:
- the sourceUri value
-
withSourceUri
Set if createOption is Import, this is the URI of a blob to be imported into a managed disk.- Parameters:
sourceUri
- the sourceUri value to set- Returns:
- the CreationData object itself.
-
sourceResourceId
Get if createOption is Copy, this is the ARM id of the source snapshot or disk.- Returns:
- the sourceResourceId value
-
withSourceResourceId
Set if createOption is Copy, this is the ARM id of the source snapshot or disk.- Parameters:
sourceResourceId
- the sourceResourceId value to set- Returns:
- the CreationData object itself.
-
sourceUniqueId
Get if this field is set, this is the unique id identifying the source of this resource.- Returns:
- the sourceUniqueId value
-
uploadSizeBytes
Get 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).- Returns:
- the uploadSizeBytes value
-
withUploadSizeBytes
Set 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).- Parameters:
uploadSizeBytes
- the uploadSizeBytes value to set- Returns:
- the CreationData object itself.
-
logicalSectorSize
Get logical sector size in bytes for Ultra disks. Supported values are 512 ad 4096. 4096 is the default.- Returns:
- the logicalSectorSize value
-
withLogicalSectorSize
Set logical sector size in bytes for Ultra disks. Supported values are 512 ad 4096. 4096 is the default.- Parameters:
logicalSectorSize
- the logicalSectorSize value to set- Returns:
- the CreationData object itself.
-