コード例 #1
0
 /// <summary>
 /// Returns available quantity.
 /// </summary>
 /// <param name="batch">The batch.</param>
 /// <returns></returns>
 public static double AvailableQuantity(this Batch batch)
 {
     return(batch.FGQuantityAvailable.Value);
 }
コード例 #2
0
 /// <summary>
 /// Check if <paramref name="quantity" /> is availables in the specified batch.
 /// </summary>
 /// <param name="batch">The batch.</param>
 /// <param name="quantity">The requested quantity.</param>
 /// <returns></returns>
 public static bool Available(this Batch batch, double quantity)
 {
     return(batch.FGQuantityAvailable >= quantity);
 }