/// <summary>
 /// The Add Disk operation adds a disk to the user image repository.
 /// The disk can be an operating system disk or a data disk.  (see
 /// http://msdn.microsoft.com/en-us/library/windowsazure/jj157178.aspx
 /// for more information)
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.WindowsAzure.Management.Compute.IVirtualMachineDiskOperations.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the Create Virtual Machine Disk operation.
 /// </param>
 /// <returns>
 /// A virtual machine disk associated with your subscription.
 /// </returns>
 public static Task<VirtualMachineDiskCreateDiskResponse> CreateDiskAsync(this IVirtualMachineDiskOperations operations, VirtualMachineDiskCreateDiskParameters parameters)
 {
     return operations.CreateDiskAsync(parameters, CancellationToken.None);
 }
 /// <summary>
 /// The Add Disk operation adds a disk to the user image repository.
 /// The disk can be an operating system disk or a data disk.  (see
 /// http://msdn.microsoft.com/en-us/library/windowsazure/jj157178.aspx
 /// for more information)
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.WindowsAzure.Management.Compute.IVirtualMachineDiskOperations.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the Create Virtual Machine Disk operation.
 /// </param>
 /// <returns>
 /// A virtual machine disk associated with your subscription.
 /// </returns>
 public static VirtualMachineDiskCreateDiskResponse CreateDisk(this IVirtualMachineDiskOperations operations, VirtualMachineDiskCreateDiskParameters parameters)
 {
     try
     {
         return operations.CreateDiskAsync(parameters).Result;
     }
     catch (AggregateException ex)
     {
         if (ex.InnerExceptions.Count > 1)
         {
             throw;
         }
         else
         {
             throw ex.InnerException;
         }
     }
 }