package org.wfc.omada.api.log.model;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.Valid;
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;

/**
 * LogNotificationSettingEditOpenApiV2Vo
 */
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.SpringCodegen", date = "2024-12-04T11:45:56.254+08:00[Asia/Shanghai]")

public class LogNotificationSettingEditOpenApiV2Vo   {
  @JsonProperty("webhookConfig")
  private WebhookConfigEditOpenApiVo webhookConfig;

  @JsonProperty("alertNotifications")
  @Valid
  private List<LogNotificationEditOpenApiV2Vo> alertNotifications = null;

  @JsonProperty("eventNotifications")
  @Valid
  private List<LogNotificationEditOpenApiV2Vo> eventNotifications = null;

  @JsonProperty("alertEmailSetting")
  private LogAlertEmailOpenApiVo alertEmailSetting;

  @JsonProperty("eventEmailSetting")
  private LogAlertEmailOpenApiVo eventEmailSetting;

  public LogNotificationSettingEditOpenApiV2Vo webhookConfig(WebhookConfigEditOpenApiVo webhookConfig) {
    this.webhookConfig = webhookConfig;
    return this;
  }

  /**
   * Get webhookConfig
   * @return webhookConfig
  */
  @ApiModelProperty(value = "")

  @Valid

  public WebhookConfigEditOpenApiVo getWebhookConfig() {
    return webhookConfig;
  }

  public void setWebhookConfig(WebhookConfigEditOpenApiVo webhookConfig) {
    this.webhookConfig = webhookConfig;
  }

  public LogNotificationSettingEditOpenApiV2Vo alertNotifications(List<LogNotificationEditOpenApiV2Vo> alertNotifications) {
    this.alertNotifications = alertNotifications;
    return this;
  }

  public LogNotificationSettingEditOpenApiV2Vo addAlertNotificationsItem(LogNotificationEditOpenApiV2Vo alertNotificationsItem) {
    if (this.alertNotifications == null) {
      this.alertNotifications = new ArrayList<>();
    }
    this.alertNotifications.add(alertNotificationsItem);
    return this;
  }

  /**
   * Alert Notification List
   * @return alertNotifications
  */
  @ApiModelProperty(value = "Alert Notification List")

  @Valid

  public List<LogNotificationEditOpenApiV2Vo> getAlertNotifications() {
    return alertNotifications;
  }

  public void setAlertNotifications(List<LogNotificationEditOpenApiV2Vo> alertNotifications) {
    this.alertNotifications = alertNotifications;
  }

  public LogNotificationSettingEditOpenApiV2Vo eventNotifications(List<LogNotificationEditOpenApiV2Vo> eventNotifications) {
    this.eventNotifications = eventNotifications;
    return this;
  }

  public LogNotificationSettingEditOpenApiV2Vo addEventNotificationsItem(LogNotificationEditOpenApiV2Vo eventNotificationsItem) {
    if (this.eventNotifications == null) {
      this.eventNotifications = new ArrayList<>();
    }
    this.eventNotifications.add(eventNotificationsItem);
    return this;
  }

  /**
   * Event Notification List
   * @return eventNotifications
  */
  @ApiModelProperty(value = "Event Notification List")

  @Valid

  public List<LogNotificationEditOpenApiV2Vo> getEventNotifications() {
    return eventNotifications;
  }

  public void setEventNotifications(List<LogNotificationEditOpenApiV2Vo> eventNotifications) {
    this.eventNotifications = eventNotifications;
  }

  public LogNotificationSettingEditOpenApiV2Vo alertEmailSetting(LogAlertEmailOpenApiVo alertEmailSetting) {
    this.alertEmailSetting = alertEmailSetting;
    return this;
  }

  /**
   * Get alertEmailSetting
   * @return alertEmailSetting
  */
  @ApiModelProperty(value = "")

  @Valid

  public LogAlertEmailOpenApiVo getAlertEmailSetting() {
    return alertEmailSetting;
  }

  public void setAlertEmailSetting(LogAlertEmailOpenApiVo alertEmailSetting) {
    this.alertEmailSetting = alertEmailSetting;
  }

  public LogNotificationSettingEditOpenApiV2Vo eventEmailSetting(LogAlertEmailOpenApiVo eventEmailSetting) {
    this.eventEmailSetting = eventEmailSetting;
    return this;
  }

  /**
   * Get eventEmailSetting
   * @return eventEmailSetting
  */
  @ApiModelProperty(value = "")

  @Valid

  public LogAlertEmailOpenApiVo getEventEmailSetting() {
    return eventEmailSetting;
  }

  public void setEventEmailSetting(LogAlertEmailOpenApiVo eventEmailSetting) {
    this.eventEmailSetting = eventEmailSetting;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    LogNotificationSettingEditOpenApiV2Vo logNotificationSettingEditOpenApiV2Vo = (LogNotificationSettingEditOpenApiV2Vo) o;
    return Objects.equals(this.webhookConfig, logNotificationSettingEditOpenApiV2Vo.webhookConfig) &&
        Objects.equals(this.alertNotifications, logNotificationSettingEditOpenApiV2Vo.alertNotifications) &&
        Objects.equals(this.eventNotifications, logNotificationSettingEditOpenApiV2Vo.eventNotifications) &&
        Objects.equals(this.alertEmailSetting, logNotificationSettingEditOpenApiV2Vo.alertEmailSetting) &&
        Objects.equals(this.eventEmailSetting, logNotificationSettingEditOpenApiV2Vo.eventEmailSetting);
  }

  @Override
  public int hashCode() {
    return Objects.hash(webhookConfig, alertNotifications, eventNotifications, alertEmailSetting, eventEmailSetting);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class LogNotificationSettingEditOpenApiV2Vo {\n");
    
    sb.append("    webhookConfig: ").append(toIndentedString(webhookConfig)).append("\n");
    sb.append("    alertNotifications: ").append(toIndentedString(alertNotifications)).append("\n");
    sb.append("    eventNotifications: ").append(toIndentedString(eventNotifications)).append("\n");
    sb.append("    alertEmailSetting: ").append(toIndentedString(alertEmailSetting)).append("\n");
    sb.append("    eventEmailSetting: ").append(toIndentedString(eventEmailSetting)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }
}

