content: package com.alibaba.tdata.aisp.server.repository.domain;
  
  import java.io.Serializable;
  import java.util.ArrayList;
  import java.util.Arrays;
  import java.util.Date;
  
  public class DetectorConfigDO implements Serializable {
      private String detectorCode;
  
      private Date gmtCreate;
  
      private Date gmtModified;
  
      private String detectorUrl;
  
      private String comment;
  
      private static final long serialVersionUID = 1L;
  
      public String getDetectorCode() {
          return detectorCode;
      }
  
      public void setDetectorCode(String detectorCode) {
          this.detectorCode = detectorCode == null ? null : detectorCode.trim();
      }
  
      public Date getGmtCreate() {
          return gmtCreate;
      }
  
      public void setGmtCreate(Date gmtCreate) {
          this.gmtCreate = gmtCreate;
      }
  
      public Date getGmtModified() {
          return gmtModified;
      }
  
      public void setGmtModified(Date gmtModified) {
          this.gmtModified = gmtModified;
      }
  
      public String getDetectorUrl() {
          return detectorUrl;
      }
  
      public void setDetectorUrl(String detectorUrl) {
          this.detectorUrl = detectorUrl == null ? null : detectorUrl.trim();
      }
  
      public String getComment() {
          return comment;
      }
  
      public void setComment(String comment) {
          this.comment = comment == null ? null : comment.trim();
      }
  
      @Override
      public boolean equals(Object that) {
          if (this == that) {
              return true;
          }
          if (that == null) {
              return false;
          }
          if (getClass() != that.getClass()) {
              return false;
          }
          DetectorConfigDO other = (DetectorConfigDO) that;
          return (this.getDetectorCode() == null ? other.getDetectorCode() == null : this.getDetectorCode().equals(other.getDetectorCode()))
              && (this.getGmtCreate() == null ? other.getGmtCreate() == null : this.getGmtCreate().equals(other.getGmtCreate()))
              && (this.getGmtModified() == null ? other.getGmtModified() == null : this.getGmtModified().equals(other.getGmtModified()))
              && (this.getDetectorUrl() == null ? other.getDetectorUrl() == null : this.getDetectorUrl().equals(other.getDetectorUrl()))
              && (this.getComment() == null ? other.getComment() == null : this.getComment().equals(other.getComment()));
      }
  
      @Override
      public int hashCode() {
          final int prime = 31;
          int result = 1;
          result = prime * result + ((getDetectorCode() == null) ? 0 : getDetectorCode().hashCode());
          result = prime * result + ((getGmtCreate() == null) ? 0 : getGmtCreate().hashCode());
          result = prime * result + ((getGmtModified() == null) ? 0 : getGmtModified().hashCode());
          result = prime * result + ((getDetectorUrl() == null) ? 0 : getDetectorUrl().hashCode());
          result = prime * result + ((getComment() == null) ? 0 : getComment().hashCode());
          return result;
      }
  
      @Override
      public String toString() {
          StringBuilder sb = new StringBuilder();
          sb.append(getClass().getSimpleName());
          sb.append(" [");
          sb.append("Hash = ").append(hashCode());
          sb.append(", detectorCode=").append(detectorCode);
          sb.append(", gmtCreate=").append(gmtCreate);
          sb.append(", gmtModified=").append(gmtModified);
          sb.append(", detectorUrl=").append(detectorUrl);
          sb.append(", comment=").append(comment);
          sb.append(", serialVersionUID=").append(serialVersionUID);
          sb.append("]");
          return sb.toString();
      }
  
      public enum Column {
          detectorCode("detector_code", "detectorCode", "VARCHAR", false),
          gmtCreate("gmt_create", "gmtCreate", "TIMESTAMP", false),
          gmtModified("gmt_modified", "gmtModified", "TIMESTAMP", false),
          detectorUrl("detector_url", "detectorUrl", "VARCHAR", false),
          comment("comment", "comment", "LONGVARCHAR", false);
  
          private static final String BEGINNING_DELIMITER = "\"";
  
          private static final String ENDING_DELIMITER = "\"";
  
          private final String column;
  
          private final boolean isColumnNameDelimited;
  
          private final String javaProperty;
  
          private final String jdbcType;
  
          public String value() {
              return this.column;
          }
  
          public String getValue() {
              return this.column;
          }
  
          public String getJavaProperty() {
              return this.javaProperty;
          }
  
          public String getJdbcType() {
              return this.jdbcType;
          }
  
          Column(String column, String javaProperty, String jdbcType, boolean isColumnNameDelimited) {
              this.column = column;
              this.javaProperty = javaProperty;
              this.jdbcType = jdbcType;
              this.isColumnNameDelimited = isColumnNameDelimited;
          }
  
          public String desc() {
              return this.getEscapedColumnName() + " DESC";
          }
  
          public String asc() {
              return this.getEscapedColumnName() + " ASC";
          }
  
          public static Column[] excludes(Column ... excludes) {
              ArrayList<Column> columns = new ArrayList<>(Arrays.asList(Column.values()));
              if (excludes != null && excludes.length > 0) {
                  columns.removeAll(new ArrayList<>(Arrays.asList(excludes)));
              }
              return columns.toArray(new Column[]{});
          }
  
          public static Column[] all() {
              return Column.values();
          }
  
          public String getEscapedColumnName() {
              if (this.isColumnNameDelimited) {
                  return new StringBuilder().append(BEGINNING_DELIMITER).append(this.column).append(ENDING_DELIMITER).toString();
              } else {
                  return this.column;
              }
          }
  
          public String getAliasedEscapedColumnName() {
              return this.getEscapedColumnName();
          }
      }
  }