Class Snapshot
Snapshot resource.
Namespace: System.Dynamic.ExpandoObject
Assembly: Microsoft.Azure.Management.Compute.dll
Syntax
[Microsoft.Rest.Serialization.JsonTransformation]
public class Snapshot : Microsoft.Azure.Management.Compute.Models.Resource
Constructors
Snapshot()
Initializes a new instance of the Snapshot class.
Declaration
public Snapshot ();
Snapshot(String, CreationData, String, String, String, IDictionary<String,String>, String, SnapshotSku, Nullable<DateTime>, Nullable<OperatingSystemTypes>, String, Nullable<Int32>, Nullable<Int64>, String, EncryptionSettingsCollection, String, Nullable<Boolean>)
Initializes a new instance of the Snapshot class.
Declaration
public Snapshot (string location, Microsoft.Azure.Management.Compute.Models.CreationData creationData, string id = null, string name = null, string type = null, System.Collections.Generic.IDictionary<string,string> tags = null, string managedBy = null, Microsoft.Azure.Management.Compute.Models.SnapshotSku sku = null, Nullable<DateTime> timeCreated = null, Nullable<Microsoft.Azure.Management.Compute.Models.OperatingSystemTypes> osType = null, string hyperVGeneration = null, Nullable<int> diskSizeGB = null, Nullable<long> diskSizeBytes = null, string uniqueId = null, Microsoft.Azure.Management.Compute.Models.EncryptionSettingsCollection encryptionSettingsCollection = null, string provisioningState = null, Nullable<bool> incremental = null);
Parameters
|
String
location
Resource location |
|
CreationData
creationData
Disk source information. CreationData information cannot be changed after the disk has been created. |
|
String
id
Resource Id |
|
String
name
Resource name |
|
String
type
Resource type |
|
IDictionary<String,String>
tags
Resource tags |
|
String
managedBy
Unused. Always Null. |
|
SnapshotSku
sku
|
|
Nullable<DateTime>
timeCreated
The time when the disk was created. |
|
Nullable<OperatingSystemTypes>
osType
The Operating System type. Possible values include: 'Windows', 'Linux' |
|
String
hyperVGeneration
The hypervisor generation of the Virtual Machine. Applicable to OS disks only. Possible values include: 'V1', 'V2' |
|
Nullable<Int32>
diskSizeGB
If creationData.createOption is Empty, this field is mandatory and it indicates the size of the disk to create. If this field is present for updates or creation with other options, it indicates a resize. Resizes are only allowed if the disk is not attached to a running VM, and can only increase the disk's size. |
|
Nullable<Int64>
diskSizeBytes
The size of the disk in bytes. This field is read only. |
|
String
uniqueId
Unique Guid identifying the resource. |
|
EncryptionSettingsCollection
encryptionSettingsCollection
Encryption settings collection used be Azure Disk Encryption, can contain multiple encryption settings per disk or snapshot. |
|
String
provisioningState
The disk provisioning state. |
|
Nullable<Boolean>
incremental
Whether a snapshot is incremental. Incremental snapshots on the same disk occupy less space than full snapshots and can be diffed. |
Properties
CreationData
Gets or sets disk source information. CreationData information cannot be changed after the disk has been created.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.creationData")]
public Microsoft.Azure.Management.Compute.Models.CreationData CreationData { get; set; }
Property Value
|
CreationData
|
DiskSizeBytes
Gets the size of the disk in bytes. This field is read only.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.diskSizeBytes")]
public Nullable<long> DiskSizeBytes { get; }
Property Value
|
Nullable<Int64>
|
DiskSizeGB
Gets or sets if creationData.createOption is Empty, this field is mandatory and it indicates the size of the disk to create. If this field is present for updates or creation with other options, it indicates a resize. Resizes are only allowed if the disk is not attached to a running VM, and can only increase the disk's size.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.diskSizeGB")]
public Nullable<int> DiskSizeGB { get; set; }
Property Value
|
Nullable<Int32>
|
EncryptionSettingsCollection
Gets or sets encryption settings collection used be Azure Disk Encryption, can contain multiple encryption settings per disk or snapshot.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.encryptionSettingsCollection")]
public Microsoft.Azure.Management.Compute.Models.EncryptionSettingsCollection EncryptionSettingsCollection { get; set; }
Property Value
|
EncryptionSettingsCollection
|
HyperVGeneration
Gets or sets the hypervisor generation of the Virtual Machine. Applicable to OS disks only. Possible values include: 'V1', 'V2'
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.hyperVGeneration")]
public string HyperVGeneration { get; set; }
Property Value
|
String
|
Incremental
Gets or sets whether a snapshot is incremental. Incremental snapshots on the same disk occupy less space than full snapshots and can be diffed.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.incremental")]
public Nullable<bool> Incremental { get; set; }
Property Value
|
Nullable<Boolean>
|
ManagedBy
Gets unused. Always Null.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="managedBy")]
public string ManagedBy { get; }
Property Value
|
String
|
OsType
Gets or sets the Operating System type. Possible values include: 'Windows', 'Linux'
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.osType")]
public Nullable<Microsoft.Azure.Management.Compute.Models.OperatingSystemTypes> OsType { get; set; }
Property Value
|
Nullable<OperatingSystemTypes>
|
ProvisioningState
Gets the disk provisioning state.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.provisioningState")]
public string ProvisioningState { get; }
Property Value
|
String
|
Sku
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="sku")]
public Microsoft.Azure.Management.Compute.Models.SnapshotSku Sku { get; set; }
Property Value
|
SnapshotSku
|
TimeCreated
Gets the time when the disk was created.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.timeCreated")]
public Nullable<DateTime> TimeCreated { get; }
Property Value
|
Nullable<DateTime>
|
UniqueId
Gets unique Guid identifying the resource.
Declaration
[Newtonsoft.Json.JsonProperty(PropertyName="properties.uniqueId")]
public string UniqueId { get; }
Property Value
|
String
|
Methods
Validate()
Validate the object.
Declaration
public override void Validate ();
Exceptions
|
ValidationException
Thrown if validation fails |