public override object Clone() { SpanPositionRangeQuery result = new SpanPositionRangeQuery((SpanQuery)m_match.Clone(), m_start, m_end); result.Boost = Boost; return(result); }
public override bool Equals(object o) { if (this == o) { return(true); } if (!(o is SpanPositionRangeQuery)) { return(false); } SpanPositionRangeQuery other = (SpanPositionRangeQuery)o; return(this.m_end == other.m_end && this.m_start == other.m_start && this.m_match.Equals(other.m_match) && this.Boost == other.Boost); }
public override bool Equals(object o) { if (this == o) { return(true); } if (!(o is SpanPositionRangeQuery)) { return(false); } SpanPositionRangeQuery other = (SpanPositionRangeQuery)o; // LUCENENET specific - compare bits rather than using equality operators to prevent these comparisons from failing in x86 in .NET Framework with optimizations enabled return(this.m_end == other.m_end && this.m_start == other.m_start && this.m_match.Equals(other.m_match) && NumericUtils.SingleToSortableInt32(this.Boost) == NumericUtils.SingleToSortableInt32(other.Boost)); }