/// <summary> /// Validate the object. /// </summary> /// <exception cref="ValidationException"> /// Thrown if validation fails /// </exception> public virtual void Validate() { if (TargetConnectionInfo == null) { throw new ValidationException(ValidationRules.CannotBeNull, "TargetConnectionInfo"); } if (TargetDatabaseName == null) { throw new ValidationException(ValidationRules.CannotBeNull, "TargetDatabaseName"); } if (ProjectName == null) { throw new ValidationException(ValidationRules.CannotBeNull, "ProjectName"); } if (ProjectLocation == null) { throw new ValidationException(ValidationRules.CannotBeNull, "ProjectLocation"); } if (SelectedTables == null) { throw new ValidationException(ValidationRules.CannotBeNull, "SelectedTables"); } if (TargetConnectionInfo != null) { TargetConnectionInfo.Validate(); } }
/// <summary> /// Validate the object. /// </summary> /// <exception cref="ValidationException"> /// Thrown if validation fails /// </exception> public virtual void Validate() { if (SourceConnectionInfo == null) { throw new ValidationException(ValidationRules.CannotBeNull, "SourceConnectionInfo"); } if (TargetConnectionInfo == null) { throw new ValidationException(ValidationRules.CannotBeNull, "TargetConnectionInfo"); } if (SelectedSourceDatabases == null) { throw new ValidationException(ValidationRules.CannotBeNull, "SelectedSourceDatabases"); } if (SelectedTargetDatabases == null) { throw new ValidationException(ValidationRules.CannotBeNull, "SelectedTargetDatabases"); } if (SourceConnectionInfo != null) { SourceConnectionInfo.Validate(); } if (TargetConnectionInfo != null) { TargetConnectionInfo.Validate(); } }
/// <summary> /// Validate the object. /// </summary> /// <exception cref="ValidationException"> /// Thrown if validation fails /// </exception> public virtual void Validate() { if (TargetConnectionInfo == null) { throw new ValidationException(ValidationRules.CannotBeNull, "TargetConnectionInfo"); } if (TargetConnectionInfo != null) { TargetConnectionInfo.Validate(); } }
/// <summary> /// Validate the object. /// </summary> /// <exception cref="ValidationException"> /// Thrown if validation fails /// </exception> public virtual void Validate() { if (SelectedDatabases == null) { throw new ValidationException(ValidationRules.CannotBeNull, "SelectedDatabases"); } if (StorageResourceId == null) { throw new ValidationException(ValidationRules.CannotBeNull, "StorageResourceId"); } if (SourceConnectionInfo == null) { throw new ValidationException(ValidationRules.CannotBeNull, "SourceConnectionInfo"); } if (TargetConnectionInfo == null) { throw new ValidationException(ValidationRules.CannotBeNull, "TargetConnectionInfo"); } if (AzureApp == null) { throw new ValidationException(ValidationRules.CannotBeNull, "AzureApp"); } if (SelectedDatabases != null) { foreach (var element in SelectedDatabases) { if (element != null) { element.Validate(); } } } if (BackupFileShare != null) { BackupFileShare.Validate(); } if (SourceConnectionInfo != null) { SourceConnectionInfo.Validate(); } if (TargetConnectionInfo != null) { TargetConnectionInfo.Validate(); } if (AzureApp != null) { AzureApp.Validate(); } }