示例#1
0
 /// <summary>
 /// Validate the object.
 /// </summary>
 /// <exception cref="ValidationException">
 /// Thrown if validation fails
 /// </exception>
 public virtual void Validate()
 {
     if (Certificate != null)
     {
         Certificate.Validate();
     }
     if (ClientCertificateCommonNames != null)
     {
         foreach (var element in ClientCertificateCommonNames)
         {
             if (element != null)
             {
                 element.Validate();
             }
         }
     }
     if (ClientCertificateThumbprints != null)
     {
         foreach (var element1 in ClientCertificateThumbprints)
         {
             if (element1 != null)
             {
                 element1.Validate();
             }
         }
     }
     if (FabricSettings != null)
     {
         foreach (var element2 in FabricSettings)
         {
             if (element2 != null)
             {
                 element2.Validate();
             }
         }
     }
     if (NodeTypes != null)
     {
         foreach (var element3 in NodeTypes)
         {
             if (element3 != null)
             {
                 element3.Validate();
             }
         }
     }
     if (ReverseProxyCertificate != null)
     {
         ReverseProxyCertificate.Validate();
     }
     if (UpgradeDescription != null)
     {
         UpgradeDescription.Validate();
     }
     if (ApplicationTypeVersionsCleanupPolicy != null)
     {
         ApplicationTypeVersionsCleanupPolicy.Validate();
     }
 }
示例#2
0
 /// <summary>
 /// Validate the object.
 /// </summary>
 /// <exception cref="ValidationException">
 /// Thrown if validation fails
 /// </exception>
 public override void Validate()
 {
     base.Validate();
     if (ManagementEndpoint == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "ManagementEndpoint");
     }
     if (NodeTypes == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "NodeTypes");
     }
     if (Certificate != null)
     {
         Certificate.Validate();
     }
     if (ClientCertificateCommonNames != null)
     {
         foreach (var element in ClientCertificateCommonNames)
         {
             if (element != null)
             {
                 element.Validate();
             }
         }
     }
     if (ClientCertificateThumbprints != null)
     {
         foreach (var element1 in ClientCertificateThumbprints)
         {
             if (element1 != null)
             {
                 element1.Validate();
             }
         }
     }
     if (DiagnosticsStorageAccountConfig != null)
     {
         DiagnosticsStorageAccountConfig.Validate();
     }
     if (FabricSettings != null)
     {
         foreach (var element2 in FabricSettings)
         {
             if (element2 != null)
             {
                 element2.Validate();
             }
         }
     }
     if (NodeTypes != null)
     {
         foreach (var element3 in NodeTypes)
         {
             if (element3 != null)
             {
                 element3.Validate();
             }
         }
     }
     if (ReverseProxyCertificate != null)
     {
         ReverseProxyCertificate.Validate();
     }
     if (UpgradeDescription != null)
     {
         UpgradeDescription.Validate();
     }
 }