/// <summary> /// Determines whether the given ID is a quantity type ID. /// </summary> /// <param name="id">The ID to be tested.</param> /// <returns>True if the given ID is a quantity type ID; false otherwise.</returns> public static bool IsQuantityTypeID(Guid id) { return(QuantityTypeNames.ContainsKey(id)); }
/// <summary> /// Gets the name of the quantity type with the given ID. /// </summary> /// <param name="quantityTypeID">The ID of the quantity type.</param> /// <returns>The name of the quantity type with the given ID.</returns> public static string ToString(Guid quantityTypeID) { string name; return(QuantityTypeNames.TryGetValue(quantityTypeID, out name) ? name : null); }