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