Exemple #1
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 (ScriptFilename != null)
         {
             hashCode = hashCode * 59 + ScriptFilename.GetHashCode();
         }
         if (ScriptDisplay != null)
         {
             hashCode = hashCode * 59 + ScriptDisplay.GetHashCode();
         }
         if (ScriptPath != null)
         {
             hashCode = hashCode * 59 + ScriptPath.GetHashCode();
         }
         if (ScriptPlatform != null)
         {
             hashCode = hashCode * 59 + ScriptPlatform.GetHashCode();
         }
         if (Interval != null)
         {
             hashCode = hashCode * 59 + Interval.GetHashCode();
         }
         if (Jmxdomain != null)
         {
             hashCode = hashCode * 59 + Jmxdomain.GetHashCode();
         }
         return(hashCode);
     }
 }
Exemple #2
0
        /// <summary>
        /// Returns true if ComAdobeGraniteMonitoringImplScriptConfigImplProperties instances are equal
        /// </summary>
        /// <param name="other">Instance of ComAdobeGraniteMonitoringImplScriptConfigImplProperties to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(ComAdobeGraniteMonitoringImplScriptConfigImplProperties other)
        {
            if (other is null)
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     ScriptFilename == other.ScriptFilename ||
                     ScriptFilename != null &&
                     ScriptFilename.Equals(other.ScriptFilename)
                     ) &&
                 (
                     ScriptDisplay == other.ScriptDisplay ||
                     ScriptDisplay != null &&
                     ScriptDisplay.Equals(other.ScriptDisplay)
                 ) &&
                 (
                     ScriptPath == other.ScriptPath ||
                     ScriptPath != null &&
                     ScriptPath.Equals(other.ScriptPath)
                 ) &&
                 (
                     ScriptPlatform == other.ScriptPlatform ||
                     ScriptPlatform != null &&
                     ScriptPlatform.Equals(other.ScriptPlatform)
                 ) &&
                 (
                     Interval == other.Interval ||
                     Interval != null &&
                     Interval.Equals(other.Interval)
                 ) &&
                 (
                     Jmxdomain == other.Jmxdomain ||
                     Jmxdomain != null &&
                     Jmxdomain.Equals(other.Jmxdomain)
                 ));
        }