insertWithOverflow() is the same as insert() except its return value: it returns the object (if any) that was dropped off the heap because it was full. This can be the given parameter (in case it is smaller than the full heap's minimum, and couldn't be added), or another object that was previously the smallest value in the heap and now has been replaced by a larger one, or null if the queue wasn't yet full with maxSize elements.

Namespace: Lucene.Net.Util
Assembly: Lucene.Net (in Lucene.Net.dll) Version: 2.9.4.1

Syntax

C#
public virtual Object InsertWithOverflow(
	Object element
)
Visual Basic
Public Overridable Function InsertWithOverflow ( _
	element As Object _
) As Object
Visual C++
public:
virtual Object^ InsertWithOverflow(
	Object^ element
)

Parameters

element
Type: System..::..Object

[Missing <param name="element"/> documentation for "M:Lucene.Net.Util.PriorityQueue.InsertWithOverflow(System.Object)"]

Return Value

[Missing <returns> documentation for "M:Lucene.Net.Util.PriorityQueue.InsertWithOverflow(System.Object)"]

See Also