Beispiel #1
0
 public fCraftCriterion([NotNull] fCraftCriterion other)
 {
     if (other == null)
     {
         throw new ArgumentNullException("other");
     }
     FromRank  = other.FromRank;
     ToRank    = other.ToRank;
     Condition = other.Condition;
 }
Beispiel #2
0
 /// <summary> Adds a new criterion to the list. Throws an ArgumentException on duplicates. </summary>
 public static void Add([NotNull] fCraftCriterion criterion)
 {
     if (criterion == null)
     {
         throw new ArgumentNullException("criterion");
     }
     if (Criteria.Contains(criterion))
     {
         throw new ArgumentException("This criterion has already been added.");
     }
     Criteria.Add(criterion);
 }