예제 #1
0
 /// <summary>
 /// Validate the object.
 /// </summary>
 /// <exception cref="ValidationException">
 /// Thrown if validation fails
 /// </exception>
 public virtual void Validate()
 {
     if (QuoteId == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "QuoteId");
     }
     if (QuoteId != null)
     {
         QuoteId.Validate();
     }
 }
예제 #2
0
 /// <summary>
 /// Validate the object.
 /// </summary>
 /// <exception cref="ValidationException">
 /// Thrown if validation fails
 /// </exception>
 public virtual void Validate()
 {
     if (QuoteId == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "QuoteId");
     }
     if (MetricValue == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "MetricValue");
     }
     if (QuoteLineage == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "QuoteLineage");
     }
     if (QuoteId != null)
     {
         QuoteId.Validate();
     }
     if (QuoteLineage != null)
     {
         QuoteLineage.Validate();
     }
 }