예제 #1
0
파일: DataDisk.cs 프로젝트: sjh37/aznetsdk
 /// <summary>
 /// Initializes a new instance of the DataDisk class.
 /// </summary>
 /// <param name="lun">The logical unit number.</param>
 /// <param name="diskSizeGB">The initial disk size in GB when creating
 /// new data disk.</param>
 /// <param name="caching">The type of caching to be enabled for the
 /// data disks.</param>
 /// <param name="storageAccountType">The storage account type to be
 /// used for the data disk.</param>
 public DataDisk(int lun, int diskSizeGB, CachingType?caching = default(CachingType?), StorageAccountType?storageAccountType = default(StorageAccountType?))
 {
     Lun                = lun;
     Caching            = caching;
     DiskSizeGB         = diskSizeGB;
     StorageAccountType = storageAccountType;
     CustomInit();
 }
예제 #2
0
 /// <summary>
 /// Initializes a new instance of the DataDisks class.
 /// </summary>
 /// <param name="diskSizeInGB">Initial disk size in GB for blank data
 /// disks, and the new desired size for resizing existing data
 /// disks.</param>
 /// <param name="diskCount">Number of data disks to be attached to the
 /// VM. RAID level 0 will be applied in the case of multiple
 /// disks.</param>
 /// <param name="storageAccountType">Specifies the type of storage
 /// account to be used on the disk. Possible values are: Standard_LRS
 /// or Premium_LRS.</param>
 /// <param name="cachingType">None, ReadOnly, ReadWrite. Default value
 /// is None. This property is not patchable.</param>
 public DataDisks(int diskSizeInGB, int diskCount, string storageAccountType, CachingType?cachingType = default(CachingType?))
 {
     DiskSizeInGB       = diskSizeInGB;
     CachingType        = cachingType;
     DiskCount          = diskCount;
     StorageAccountType = storageAccountType;
     CustomInit();
 }
 /// <summary>
 /// Initializes a new instance of the OSDisk class.
 /// </summary>
 /// <param name="caching">The type of caching to be enabled for the
 /// data disks. none - The caching mode for the disk is not enabled.
 /// readOnly - The caching mode for the disk is read only. readWrite -
 /// The caching mode for the disk is read and write.</param>
 public OSDisk(CachingType?caching = default(CachingType?))
 {
     Caching = caching;
     CustomInit();
 }
예제 #4
0
 internal static string ToSerializedValue(this CachingType?value)
 {
     return(value == null ? null : ((CachingType)value).ToSerializedValue());
 }