コード例 #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
ファイル: Quote.cs プロジェクト: dan-curran/lusid-sdk-csharp
 /// <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();
     }
 }