package com.chenyang.nse.bussiness.entity.orm.table.console.mapping;

import com.chenyang.nse.bussiness.entity.orm.table.TBaseEntity;
import javax.persistence.Entity;
import javax.persistence.Table;

@Entity
@Table(
   name = "T_CONSOLE_DATAMAPPING_INFO"
)
public class TConsoleDatamappingInfo extends TBaseEntity {
   private String sourcefieldid;
   private String targetfieldid;
   private String targetlength;
   private String targetdecimal;
   private String targetsystemtype;

   public TConsoleDatamappingInfo() {
   }

   public TConsoleDatamappingInfo(String sourcefieldid, String targetfieldid, String targetlength, String targetdecimal, String targetsystemtype) {
      this.sourcefieldid = sourcefieldid;
      this.targetfieldid = targetfieldid;
      this.targetlength = targetlength;
      this.targetdecimal = targetdecimal;
      this.targetsystemtype = targetsystemtype;
   }

   public String getSourcefieldid() {
      return this.sourcefieldid;
   }

   public void setSourcefieldid(String sourcefieldid) {
      this.sourcefieldid = sourcefieldid;
   }

   public String getTargetfieldid() {
      return this.targetfieldid;
   }

   public void setTargetfieldid(String targetfieldid) {
      this.targetfieldid = targetfieldid;
   }

   public String getTargetlength() {
      return this.targetlength;
   }

   public void setTargetlength(String targetlength) {
      this.targetlength = targetlength;
   }

   public String getTargetdecimal() {
      return this.targetdecimal;
   }

   public void setTargetdecimal(String targetdecimal) {
      this.targetdecimal = targetdecimal;
   }

   public String getTargetsystemtype() {
      return this.targetsystemtype;
   }

   public void setTargetsystemtype(String targetsystemtype) {
      this.targetsystemtype = targetsystemtype;
   }

   public String toString() {
      return "TConsoleDatamappingInfo [sourcefieldid=" + this.sourcefieldid + ", targetfieldid=" + this.targetfieldid + ", targetlength=" + this.targetlength + ", targetdecimal=" + this.targetdecimal + ", targetsystemtype=" + this.targetsystemtype + "]";
   }

   public int hashCode() {
      int prime = 31;
      int result = 1;
      result = 31 * result + (this.sourcefieldid == null ? 0 : this.sourcefieldid.hashCode());
      result = 31 * result + (this.targetdecimal == null ? 0 : this.targetdecimal.hashCode());
      result = 31 * result + (this.targetfieldid == null ? 0 : this.targetfieldid.hashCode());
      result = 31 * result + (this.targetlength == null ? 0 : this.targetlength.hashCode());
      result = 31 * result + (this.targetsystemtype == null ? 0 : this.targetsystemtype.hashCode());
      return result;
   }

   public boolean equals(Object obj) {
      if (this == obj) {
         return true;
      } else if (obj == null) {
         return false;
      } else if (this.getClass() != obj.getClass()) {
         return false;
      } else {
         TConsoleDatamappingInfo other = (TConsoleDatamappingInfo)obj;
         if (this.sourcefieldid == null) {
            if (other.sourcefieldid != null) {
               return false;
            }
         } else if (!this.sourcefieldid.equals(other.sourcefieldid)) {
            return false;
         }

         if (this.targetdecimal == null) {
            if (other.targetdecimal != null) {
               return false;
            }
         } else if (!this.targetdecimal.equals(other.targetdecimal)) {
            return false;
         }

         if (this.targetfieldid == null) {
            if (other.targetfieldid != null) {
               return false;
            }
         } else if (!this.targetfieldid.equals(other.targetfieldid)) {
            return false;
         }

         if (this.targetlength == null) {
            if (other.targetlength != null) {
               return false;
            }
         } else if (!this.targetlength.equals(other.targetlength)) {
            return false;
         }

         if (this.targetsystemtype == null) {
            if (other.targetsystemtype != null) {
               return false;
            }
         } else if (!this.targetsystemtype.equals(other.targetsystemtype)) {
            return false;
         }

         return true;
      }
   }
}
