Exemplo n.º 1
0
        /// <summary>
        /// Returns true if ComAdobeGraniteThreaddumpThreadDumpCollectorProperties instances are equal
        /// </summary>
        /// <param name="other">Instance of ComAdobeGraniteThreaddumpThreadDumpCollectorProperties to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(ComAdobeGraniteThreaddumpThreadDumpCollectorProperties other)
        {
            if (other is null)
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     SchedulerPeriod == other.SchedulerPeriod ||
                     SchedulerPeriod != null &&
                     SchedulerPeriod.Equals(other.SchedulerPeriod)
                     ) &&
                 (
                     SchedulerRunOn == other.SchedulerRunOn ||
                     SchedulerRunOn != null &&
                     SchedulerRunOn.Equals(other.SchedulerRunOn)
                 ) &&
                 (
                     GraniteThreaddumpEnabled == other.GraniteThreaddumpEnabled ||
                     GraniteThreaddumpEnabled != null &&
                     GraniteThreaddumpEnabled.Equals(other.GraniteThreaddumpEnabled)
                 ) &&
                 (
                     GraniteThreaddumpDumpsPerFile == other.GraniteThreaddumpDumpsPerFile ||
                     GraniteThreaddumpDumpsPerFile != null &&
                     GraniteThreaddumpDumpsPerFile.Equals(other.GraniteThreaddumpDumpsPerFile)
                 ) &&
                 (
                     GraniteThreaddumpEnableGzipCompression == other.GraniteThreaddumpEnableGzipCompression ||
                     GraniteThreaddumpEnableGzipCompression != null &&
                     GraniteThreaddumpEnableGzipCompression.Equals(other.GraniteThreaddumpEnableGzipCompression)
                 ) &&
                 (
                     GraniteThreaddumpEnableDirectoriesCompression == other.GraniteThreaddumpEnableDirectoriesCompression ||
                     GraniteThreaddumpEnableDirectoriesCompression != null &&
                     GraniteThreaddumpEnableDirectoriesCompression.Equals(other.GraniteThreaddumpEnableDirectoriesCompression)
                 ) &&
                 (
                     GraniteThreaddumpEnableJStack == other.GraniteThreaddumpEnableJStack ||
                     GraniteThreaddumpEnableJStack != null &&
                     GraniteThreaddumpEnableJStack.Equals(other.GraniteThreaddumpEnableJStack)
                 ) &&
                 (
                     GraniteThreaddumpMaxBackupDays == other.GraniteThreaddumpMaxBackupDays ||
                     GraniteThreaddumpMaxBackupDays != null &&
                     GraniteThreaddumpMaxBackupDays.Equals(other.GraniteThreaddumpMaxBackupDays)
                 ) &&
                 (
                     GraniteThreaddumpBackupCleanTrigger == other.GraniteThreaddumpBackupCleanTrigger ||
                     GraniteThreaddumpBackupCleanTrigger != null &&
                     GraniteThreaddumpBackupCleanTrigger.Equals(other.GraniteThreaddumpBackupCleanTrigger)
                 ));
        }
Exemplo n.º 2
0
 /// <summary>
 /// Gets the hash code
 /// </summary>
 /// <returns>Hash code</returns>
 public override int GetHashCode()
 {
     unchecked // Overflow is fine, just wrap
     {
         var hashCode = 41;
         // Suitable nullity checks etc, of course :)
         if (SchedulerPeriod != null)
         {
             hashCode = hashCode * 59 + SchedulerPeriod.GetHashCode();
         }
         if (SchedulerRunOn != null)
         {
             hashCode = hashCode * 59 + SchedulerRunOn.GetHashCode();
         }
         if (GraniteThreaddumpEnabled != null)
         {
             hashCode = hashCode * 59 + GraniteThreaddumpEnabled.GetHashCode();
         }
         if (GraniteThreaddumpDumpsPerFile != null)
         {
             hashCode = hashCode * 59 + GraniteThreaddumpDumpsPerFile.GetHashCode();
         }
         if (GraniteThreaddumpEnableGzipCompression != null)
         {
             hashCode = hashCode * 59 + GraniteThreaddumpEnableGzipCompression.GetHashCode();
         }
         if (GraniteThreaddumpEnableDirectoriesCompression != null)
         {
             hashCode = hashCode * 59 + GraniteThreaddumpEnableDirectoriesCompression.GetHashCode();
         }
         if (GraniteThreaddumpEnableJStack != null)
         {
             hashCode = hashCode * 59 + GraniteThreaddumpEnableJStack.GetHashCode();
         }
         if (GraniteThreaddumpMaxBackupDays != null)
         {
             hashCode = hashCode * 59 + GraniteThreaddumpMaxBackupDays.GetHashCode();
         }
         if (GraniteThreaddumpBackupCleanTrigger != null)
         {
             hashCode = hashCode * 59 + GraniteThreaddumpBackupCleanTrigger.GetHashCode();
         }
         return(hashCode);
     }
 }