/// <summary> /// Gets the hash code /// </summary> /// <returns>Hash code</returns> public override int GetHashCode() { // credit: http://stackoverflow.com/a/263416/677735 unchecked // Overflow is fine, just wrap { var hash = 41; // Suitable nullity checks etc, of course :) if (Id != null) { hash = hash * 57 + Id.GetHashCode(); } if (Rid != null) { hash = hash * 57 + Rid.GetHashCode(); } if (Ts != null) { hash = hash * 57 + Ts.GetHashCode(); } if (Self != null) { hash = hash * 57 + Self.GetHashCode(); } if (Etag != null) { hash = hash * 57 + Etag.GetHashCode(); } if (Doc != null) { hash = hash * 57 + Doc.GetHashCode(); } if (Sprocs != null) { hash = hash * 57 + Sprocs.GetHashCode(); } if (Triggers != null) { hash = hash * 57 + Triggers.GetHashCode(); } if (Udfs != null) { hash = hash * 57 + Udfs.GetHashCode(); } if (Conflicts != null) { hash = hash * 57 + Conflicts.GetHashCode(); } if (IndexingPolicy != null) { hash = hash * 57 + IndexingPolicy.GetHashCode(); } return(hash); } }