Example #1
0
        /// <summary>
        /// Returns true if PdfExtractTextParameters instances are equal
        /// </summary>
        /// <param name="input">Instance of PdfExtractTextParameters to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(PdfExtractTextParameters input)
        {
            if (input == null)
            {
                return(false);
            }

            return
                ((
                     FileId == input.FileId ||
                     (FileId != null &&
                      FileId.Equals(input.FileId))
                     ) &&
                 (
                     PageRange == input.PageRange ||
                     (PageRange != null &&
                      PageRange.Equals(input.PageRange))
                 ) &&
                 (
                     TextExtractionMode == input.TextExtractionMode ||
                     TextExtractionMode.Equals(input.TextExtractionMode)
                 ) &&
                 (
                     TextExtractionAreaLeft == input.TextExtractionAreaLeft ||
                     TextExtractionAreaLeft.Equals(input.TextExtractionAreaLeft)
                 ) &&
                 (
                     TextExtractionAreaTop == input.TextExtractionAreaTop ||
                     TextExtractionAreaTop.Equals(input.TextExtractionAreaTop)
                 ) &&
                 (
                     TextExtractionAreaWidth == input.TextExtractionAreaWidth ||
                     TextExtractionAreaWidth.Equals(input.TextExtractionAreaWidth)
                 ) &&
                 (
                     TextExtractionAreaHeight == input.TextExtractionAreaHeight ||
                     TextExtractionAreaHeight.Equals(input.TextExtractionAreaHeight)
                 ) &&
                 (
                     IncludeHeader == input.IncludeHeader ||
                     IncludeHeader.Equals(input.IncludeHeader)
                 ));
        }
Example #2
0
 /// <summary>
 /// Gets the hash code
 /// </summary>
 /// <returns>Hash code</returns>
 public override int GetHashCode()
 {
     unchecked // Overflow is fine, just wrap
     {
         int hashCode = 41;
         if (FileId != null)
         {
             hashCode = hashCode * 59 + FileId.GetHashCode();
         }
         if (PageRange != null)
         {
             hashCode = hashCode * 59 + PageRange.GetHashCode();
         }
         hashCode = hashCode * 59 + TextExtractionMode.GetHashCode();
         hashCode = hashCode * 59 + TextExtractionAreaLeft.GetHashCode();
         hashCode = hashCode * 59 + TextExtractionAreaTop.GetHashCode();
         hashCode = hashCode * 59 + TextExtractionAreaWidth.GetHashCode();
         hashCode = hashCode * 59 + TextExtractionAreaHeight.GetHashCode();
         hashCode = hashCode * 59 + IncludeHeader.GetHashCode();
         return(hashCode);
     }
 }