package com.chenyang.nse.bussiness.entity.orm.table.core;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.chenyang.nse.bussiness.entity.orm.table.TBaseEntity;
import com.chenyang.nse.bussiness.entity.orm.table.core.scopeproject.TProAttributeGroup;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;

@Entity
@Table(
   name = "T_CORE_SENSITIVE_LEVEL"
)
public class TCoreSensitiveLevel extends TBaseEntity {
   @Column(
      length = 100
   )
   private String edition_id;
   @Column(
      length = 100
   )
   private String sensitive_id;
   @Column(
      length = 100
   )
   private String sensitive_name;
   @Column(
      length = 100
   )
   private String fa_tid;
   @Column(
      length = 50
   )
   private String create_user;
   @Column(
      length = 50
   )
   @JsonFormat(
      pattern = "yyyy-MM-dd HH:mm:ss"
   )
   private Date create_date;
   @Column(
      length = 1
   )
   private char open_level;
   @Column(
      length = 100
   )
   private String scope_according;
   @Column(
      length = 100
   )
   private String level_principle;
   @Column(
      length = 1000
   )
   private String rules;
   @Transient
   private List<TCoreSensitiveLevel> childrens = new ArrayList();
   @Transient
   private List<TProAttributeGroup> groups = new ArrayList();

   public char getOpen_level() {
      return this.open_level;
   }

   public void setOpen_level(char open_level) {
      this.open_level = open_level;
   }

   public String getScope_according() {
      return this.scope_according;
   }

   public void setScope_according(String scope_according) {
      this.scope_according = scope_according;
   }

   public String getLevel_principle() {
      return this.level_principle;
   }

   public void setLevel_principle(String level_principle) {
      this.level_principle = level_principle;
   }

   public String getEdition_id() {
      return this.edition_id;
   }

   public void setEdition_id(String edition_id) {
      this.edition_id = edition_id;
   }

   public String getSensitive_id() {
      return this.sensitive_id;
   }

   public void setSensitive_id(String sensitive_id) {
      this.sensitive_id = sensitive_id;
   }

   public String getSensitive_name() {
      return this.sensitive_name;
   }

   public void setSensitive_name(String sensitive_name) {
      this.sensitive_name = sensitive_name;
   }

   public String getFa_tid() {
      return this.fa_tid;
   }

   public void setFa_tid(String fa_tid) {
      this.fa_tid = fa_tid;
   }

   public String getCreate_user() {
      return this.create_user;
   }

   public void setCreate_user(String create_user) {
      this.create_user = create_user;
   }

   public Date getCreate_date() {
      return this.create_date;
   }

   public void setCreate_date(Date create_date) {
      this.create_date = create_date;
   }

   public String getRules() {
      return this.rules;
   }

   public List<TCoreSensitiveLevel> getChildrens() {
      return this.childrens;
   }

   public List<TProAttributeGroup> getGroups() {
      return this.groups;
   }

   public void setRules(final String rules) {
      this.rules = rules;
   }

   public void setChildrens(final List<TCoreSensitiveLevel> childrens) {
      this.childrens = childrens;
   }

   public void setGroups(final List<TProAttributeGroup> groups) {
      this.groups = groups;
   }

   public boolean equals(final Object o) {
      if (o == this) {
         return true;
      } else if (!(o instanceof TCoreSensitiveLevel)) {
         return false;
      } else {
         TCoreSensitiveLevel other = (TCoreSensitiveLevel)o;
         if (!other.canEqual(this)) {
            return false;
         } else {
            Object this$edition_id = this.getEdition_id();
            Object other$edition_id = other.getEdition_id();
            if (this$edition_id == null) {
               if (other$edition_id != null) {
                  return false;
               }
            } else if (!this$edition_id.equals(other$edition_id)) {
               return false;
            }

            Object this$sensitive_id = this.getSensitive_id();
            Object other$sensitive_id = other.getSensitive_id();
            if (this$sensitive_id == null) {
               if (other$sensitive_id != null) {
                  return false;
               }
            } else if (!this$sensitive_id.equals(other$sensitive_id)) {
               return false;
            }

            Object this$sensitive_name = this.getSensitive_name();
            Object other$sensitive_name = other.getSensitive_name();
            if (this$sensitive_name == null) {
               if (other$sensitive_name != null) {
                  return false;
               }
            } else if (!this$sensitive_name.equals(other$sensitive_name)) {
               return false;
            }

            Object this$fa_tid = this.getFa_tid();
            Object other$fa_tid = other.getFa_tid();
            if (this$fa_tid == null) {
               if (other$fa_tid != null) {
                  return false;
               }
            } else if (!this$fa_tid.equals(other$fa_tid)) {
               return false;
            }

            Object this$create_user = this.getCreate_user();
            Object other$create_user = other.getCreate_user();
            if (this$create_user == null) {
               if (other$create_user != null) {
                  return false;
               }
            } else if (!this$create_user.equals(other$create_user)) {
               return false;
            }

            Object this$create_date = this.getCreate_date();
            Object other$create_date = other.getCreate_date();
            if (this$create_date == null) {
               if (other$create_date != null) {
                  return false;
               }
            } else if (!this$create_date.equals(other$create_date)) {
               return false;
            }

            if (this.getOpen_level() != other.getOpen_level()) {
               return false;
            } else {
               Object this$scope_according = this.getScope_according();
               Object other$scope_according = other.getScope_according();
               if (this$scope_according == null) {
                  if (other$scope_according != null) {
                     return false;
                  }
               } else if (!this$scope_according.equals(other$scope_according)) {
                  return false;
               }

               Object this$level_principle = this.getLevel_principle();
               Object other$level_principle = other.getLevel_principle();
               if (this$level_principle == null) {
                  if (other$level_principle != null) {
                     return false;
                  }
               } else if (!this$level_principle.equals(other$level_principle)) {
                  return false;
               }

               Object this$rules = this.getRules();
               Object other$rules = other.getRules();
               if (this$rules == null) {
                  if (other$rules != null) {
                     return false;
                  }
               } else if (!this$rules.equals(other$rules)) {
                  return false;
               }

               Object this$childrens = this.getChildrens();
               Object other$childrens = other.getChildrens();
               if (this$childrens == null) {
                  if (other$childrens != null) {
                     return false;
                  }
               } else if (!this$childrens.equals(other$childrens)) {
                  return false;
               }

               Object this$groups = this.getGroups();
               Object other$groups = other.getGroups();
               if (this$groups == null) {
                  if (other$groups != null) {
                     return false;
                  }
               } else if (!this$groups.equals(other$groups)) {
                  return false;
               }

               return true;
            }
         }
      }
   }

   protected boolean canEqual(final Object other) {
      return other instanceof TCoreSensitiveLevel;
   }

   public int hashCode() {
      int PRIME = 59;
      int result = 1;
      Object $edition_id = this.getEdition_id();
      result = result * 59 + ($edition_id == null ? 43 : $edition_id.hashCode());
      Object $sensitive_id = this.getSensitive_id();
      result = result * 59 + ($sensitive_id == null ? 43 : $sensitive_id.hashCode());
      Object $sensitive_name = this.getSensitive_name();
      result = result * 59 + ($sensitive_name == null ? 43 : $sensitive_name.hashCode());
      Object $fa_tid = this.getFa_tid();
      result = result * 59 + ($fa_tid == null ? 43 : $fa_tid.hashCode());
      Object $create_user = this.getCreate_user();
      result = result * 59 + ($create_user == null ? 43 : $create_user.hashCode());
      Object $create_date = this.getCreate_date();
      result = result * 59 + ($create_date == null ? 43 : $create_date.hashCode());
      result = result * 59 + this.getOpen_level();
      Object $scope_according = this.getScope_according();
      result = result * 59 + ($scope_according == null ? 43 : $scope_according.hashCode());
      Object $level_principle = this.getLevel_principle();
      result = result * 59 + ($level_principle == null ? 43 : $level_principle.hashCode());
      Object $rules = this.getRules();
      result = result * 59 + ($rules == null ? 43 : $rules.hashCode());
      Object $childrens = this.getChildrens();
      result = result * 59 + ($childrens == null ? 43 : $childrens.hashCode());
      Object $groups = this.getGroups();
      result = result * 59 + ($groups == null ? 43 : $groups.hashCode());
      return result;
   }

   public String toString() {
      return "TCoreSensitiveLevel(edition_id=" + this.getEdition_id() + ", sensitive_id=" + this.getSensitive_id() + ", sensitive_name=" + this.getSensitive_name() + ", fa_tid=" + this.getFa_tid() + ", create_user=" + this.getCreate_user() + ", create_date=" + this.getCreate_date() + ", open_level=" + this.getOpen_level() + ", scope_according=" + this.getScope_according() + ", level_principle=" + this.getLevel_principle() + ", rules=" + this.getRules() + ", childrens=" + this.getChildrens() + ", groups=" + this.getGroups() + ")";
   }
}
