| <!DOCTYPE html> |
| <!--[if IE]><![endif]--> |
| <html> |
| |
| <head> |
| <meta charset="utf-8"> |
| <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> |
| <title>Class TimeLimitingCollector |
| | Apache Lucene.NET 4.8.0-beta00010 Documentation </title> |
| <meta name="viewport" content="width=device-width"> |
| <meta name="title" content="Class TimeLimitingCollector |
| | Apache Lucene.NET 4.8.0-beta00010 Documentation "> |
| <meta name="generator" content="docfx 2.56.0.0"> |
| |
| <link rel="shortcut icon" href="https://lucenenet.apache.org/docs/4.8.0-beta00009/logo/favicon.ico"> |
| <link rel="stylesheet" href="https://lucenenet.apache.org/docs/4.8.0-beta00009/styles/docfx.vendor.css"> |
| <link rel="stylesheet" href="https://lucenenet.apache.org/docs/4.8.0-beta00009/styles/docfx.css"> |
| <link rel="stylesheet" href="https://lucenenet.apache.org/docs/4.8.0-beta00009/styles/main.css"> |
| <meta property="docfx:navrel" content="toc.html"> |
| <meta property="docfx:tocrel" content="core/toc.html"> |
| |
| <meta property="docfx:rel" content="https://lucenenet.apache.org/docs/4.8.0-beta00009/"> |
| |
| </head> |
| <body data-spy="scroll" data-target="#affix" data-offset="120"> |
| <div id="wrapper"> |
| <header> |
| |
| <nav id="autocollapse" class="navbar ng-scope" role="navigation"> |
| <div class="container"> |
| <div class="navbar-header"> |
| <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar"> |
| <span class="sr-only">Toggle navigation</span> |
| <span class="icon-bar"></span> |
| <span class="icon-bar"></span> |
| <span class="icon-bar"></span> |
| </button> |
| |
| <a class="navbar-brand" href="/"> |
| <img id="logo" class="svg" src="https://lucenenet.apache.org/docs/4.8.0-beta00009/logo/lucene-net-color.png" alt=""> |
| </a> |
| </div> |
| <div class="collapse navbar-collapse" id="navbar"> |
| <form class="navbar-form navbar-right" role="search" id="search"> |
| <div class="form-group"> |
| <input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off"> |
| </div> |
| </form> |
| </div> |
| </div> |
| </nav> |
| |
| <div class="subnav navbar navbar-default"> |
| <div class="container hide-when-search"> |
| <ul class="level0 breadcrumb"> |
| <li> |
| <a href="https://lucenenet.apache.org/docs/4.8.0-beta00009/">API</a> |
| <span id="breadcrumb"> |
| <ul class="breadcrumb"> |
| <li></li> |
| </ul> |
| </span> |
| </li> |
| </ul> |
| </div> |
| </div> |
| </header> |
| <div class="container body-content"> |
| |
| <div id="search-results"> |
| <div class="search-list"></div> |
| <div class="sr-items"> |
| <p><i class="glyphicon glyphicon-refresh index-loading"></i></p> |
| </div> |
| <ul id="pagination"></ul> |
| </div> |
| </div> |
| <div role="main" class="container body-content hide-when-search"> |
| |
| <div class="sidenav hide-when-search"> |
| <a class="btn toc-toggle collapse" data-toggle="collapse" href="#sidetoggle" aria-expanded="false" aria-controls="sidetoggle">Show / Hide Table of Contents</a> |
| <div class="sidetoggle collapse" id="sidetoggle"> |
| <div id="sidetoc"></div> |
| </div> |
| </div> |
| <div class="article row grid-right"> |
| <div class="col-md-10"> |
| <article class="content wrap" id="_content" data-uid="Lucene.Net.Search.TimeLimitingCollector"> |
| |
| |
| <h1 id="Lucene_Net_Search_TimeLimitingCollector" data-uid="Lucene.Net.Search.TimeLimitingCollector" class="text-break">Class TimeLimitingCollector |
| </h1> |
| <div class="markdown level0 summary"><p>The <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.html">TimeLimitingCollector</a> is used to timeout search requests that |
| take longer than the maximum allowed search time limit. After this time is |
| exceeded, the search thread is stopped by throwing a |
| <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimeExceededException.html">TimeLimitingCollector.TimeExceededException</a>.</p> |
| </div> |
| <div class="markdown level0 conceptual"></div> |
| <div class="inheritance"> |
| <h5>Inheritance</h5> |
| <div class="level0"><span class="xref">System.Object</span></div> |
| <div class="level1"><span class="xref">TimeLimitingCollector</span></div> |
| </div> |
| <div classs="implements"> |
| <h5>Implements</h5> |
| <div><a class="xref" href="Lucene.Net.Search.ICollector.html">ICollector</a></div> |
| </div> |
| <div class="inheritedMembers"> |
| <h5>Inherited Members</h5> |
| <div> |
| <span class="xref">System.Object.Equals(System.Object)</span> |
| </div> |
| <div> |
| <span class="xref">System.Object.Equals(System.Object, System.Object)</span> |
| </div> |
| <div> |
| <span class="xref">System.Object.GetHashCode()</span> |
| </div> |
| <div> |
| <span class="xref">System.Object.GetType()</span> |
| </div> |
| <div> |
| <span class="xref">System.Object.MemberwiseClone()</span> |
| </div> |
| <div> |
| <span class="xref">System.Object.ReferenceEquals(System.Object, System.Object)</span> |
| </div> |
| <div> |
| <span class="xref">System.Object.ToString()</span> |
| </div> |
| </div> |
| <h6><strong>Namespace</strong>: <a class="xref" href="Lucene.Net.Search.html">Lucene.Net.Search</a></h6> |
| <h6><strong>Assembly</strong>: Lucene.Net.dll</h6> |
| <h5 id="Lucene_Net_Search_TimeLimitingCollector_syntax">Syntax</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public class TimeLimitingCollector : ICollector</code></pre> |
| </div> |
| <h3 id="constructors">Constructors |
| </h3> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector__ctor_Lucene_Net_Search_ICollector_Lucene_Net_Util_Counter_System_Int64_.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.%23ctor(Lucene.Net.Search.ICollector%2CLucene.Net.Util.Counter%2CSystem.Int64)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L117">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector__ctor_" data-uid="Lucene.Net.Search.TimeLimitingCollector.#ctor*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector__ctor_Lucene_Net_Search_ICollector_Lucene_Net_Util_Counter_System_Int64_" data-uid="Lucene.Net.Search.TimeLimitingCollector.#ctor(Lucene.Net.Search.ICollector,Lucene.Net.Util.Counter,System.Int64)">TimeLimitingCollector(ICollector, Counter, Int64)</h4> |
| <div class="markdown level1 summary"><p>Create a <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.html">TimeLimitingCollector</a> wrapper over another <a class="xref" href="Lucene.Net.Search.ICollector.html">ICollector</a> with a specified timeout. </p> |
| </div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public TimeLimitingCollector(ICollector collector, Counter clock, long ticksAllowed)</code></pre> |
| </div> |
| <h5 class="parameters">Parameters</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Name</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><a class="xref" href="Lucene.Net.Search.ICollector.html">ICollector</a></td> |
| <td><span class="parametername">collector</span></td> |
| <td><p>The wrapped <a class="xref" href="Lucene.Net.Search.ICollector.html">ICollector</a> </p> |
| </td> |
| </tr> |
| <tr> |
| <td><a class="xref" href="Lucene.Net.Util.Counter.html">Counter</a></td> |
| <td><span class="parametername">clock</span></td> |
| <td><p>The timer clock </p> |
| </td> |
| </tr> |
| <tr> |
| <td><span class="xref">System.Int64</span></td> |
| <td><span class="parametername">ticksAllowed</span></td> |
| <td><p>Max time allowed for collecting |
| hits after which <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimeExceededException.html">TimeLimitingCollector.TimeExceededException</a> is thrown </p> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| <h3 id="properties">Properties |
| </h3> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_AcceptsDocsOutOfOrder.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.AcceptsDocsOutOfOrder%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L209">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_AcceptsDocsOutOfOrder_" data-uid="Lucene.Net.Search.TimeLimitingCollector.AcceptsDocsOutOfOrder*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_AcceptsDocsOutOfOrder" data-uid="Lucene.Net.Search.TimeLimitingCollector.AcceptsDocsOutOfOrder">AcceptsDocsOutOfOrder</h4> |
| <div class="markdown level1 summary"></div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public virtual bool AcceptsDocsOutOfOrder { get; }</code></pre> |
| </div> |
| <h5 class="propertyValue">Property Value</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><span class="xref">System.Boolean</span></td> |
| <td></td> |
| </tr> |
| </tbody> |
| </table> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_GlobalCounter.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.GlobalCounter%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L233">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_GlobalCounter_" data-uid="Lucene.Net.Search.TimeLimitingCollector.GlobalCounter*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_GlobalCounter" data-uid="Lucene.Net.Search.TimeLimitingCollector.GlobalCounter">GlobalCounter</h4> |
| <div class="markdown level1 summary"><p>Returns the global <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a>'s <a class="xref" href="Lucene.Net.Util.Counter.html">Counter</a> |
| <p> |
| Invoking this creates may create a new instance of <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a> iff |
| the global <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a> has never been accessed before. The thread |
| returned from this method is started on creation and will be alive unless |
| you stop the <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a> via <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html#Lucene_Net_Search_TimeLimitingCollector_TimerThread_StopTimer">StopTimer()</a>. |
| </p> </p> |
| <div class="lucene-block lucene-experimental">This is a Lucene.NET EXPERIMENTAL API, use at your own risk</div></div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public static Counter GlobalCounter { get; }</code></pre> |
| </div> |
| <h5 class="propertyValue">Property Value</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><a class="xref" href="Lucene.Net.Util.Counter.html">Counter</a></td> |
| <td><p>the global TimerThreads <a class="xref" href="Lucene.Net.Util.Counter.html">Counter</a> </p> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_GlobalTimerThread.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.GlobalTimerThread%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L246">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_GlobalTimerThread_" data-uid="Lucene.Net.Search.TimeLimitingCollector.GlobalTimerThread*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_GlobalTimerThread" data-uid="Lucene.Net.Search.TimeLimitingCollector.GlobalTimerThread">GlobalTimerThread</h4> |
| <div class="markdown level1 summary"><p>Returns the global <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a>. |
| <p> |
| Invoking this creates may create a new instance of <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a> iff |
| the global <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a> has never been accessed before. The thread |
| returned from this method is started on creation and will be alive unless |
| you stop the <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a> via <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html#Lucene_Net_Search_TimeLimitingCollector_TimerThread_StopTimer">StopTimer()</a>. |
| </p></p> |
| <div class="lucene-block lucene-experimental">This is a Lucene.NET EXPERIMENTAL API, use at your own risk</div></div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public static TimeLimitingCollector.TimerThread GlobalTimerThread { get; }</code></pre> |
| </div> |
| <h5 class="propertyValue">Property Value</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a></td> |
| <td><p>the global <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimerThread.html">TimeLimitingCollector.TimerThread</a> </p> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_IsGreedy.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.IsGreedy%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L165">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_IsGreedy_" data-uid="Lucene.Net.Search.TimeLimitingCollector.IsGreedy*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_IsGreedy" data-uid="Lucene.Net.Search.TimeLimitingCollector.IsGreedy">IsGreedy</h4> |
| <div class="markdown level1 summary"><p>Checks if this time limited collector is greedy in collecting the last hit. |
| A non greedy collector, upon a timeout, would throw a <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimeExceededException.html">TimeLimitingCollector.TimeExceededException</a> |
| without allowing the wrapped collector to collect current doc. A greedy one would |
| first allow the wrapped hit collector to collect current doc and only then |
| throw a <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimeExceededException.html">TimeLimitingCollector.TimeExceededException</a>. </p> |
| </div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public virtual bool IsGreedy { get; set; }</code></pre> |
| </div> |
| <h5 class="propertyValue">Property Value</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><span class="xref">System.Boolean</span></td> |
| <td></td> |
| </tr> |
| </tbody> |
| </table> |
| <h3 id="methods">Methods |
| </h3> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_Collect_System_Int32_.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.Collect(System.Int32)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L177">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_Collect_" data-uid="Lucene.Net.Search.TimeLimitingCollector.Collect*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_Collect_System_Int32_" data-uid="Lucene.Net.Search.TimeLimitingCollector.Collect(System.Int32)">Collect(Int32)</h4> |
| <div class="markdown level1 summary"><p>Calls <a class="xref" href="Lucene.Net.Search.ICollector.html#Lucene_Net_Search_ICollector_Collect_System_Int32_">Collect(Int32)</a> on the decorated <a class="xref" href="Lucene.Net.Search.ICollector.html">ICollector</a> |
| unless the allowed time has passed, in which case it throws an exception.</p> |
| </div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public virtual void Collect(int doc)</code></pre> |
| </div> |
| <h5 class="parameters">Parameters</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Name</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><span class="xref">System.Int32</span></td> |
| <td><span class="parametername">doc</span></td> |
| <td></td> |
| </tr> |
| </tbody> |
| </table> |
| <h5 class="exceptions">Exceptions</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Condition</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.TimeExceededException.html">TimeLimitingCollector.TimeExceededException</a></td> |
| <td><p>If the time allowed has exceeded. </p> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_SetBaseline.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.SetBaseline%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L153">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_SetBaseline_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetBaseline*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_SetBaseline" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetBaseline">SetBaseline()</h4> |
| <div class="markdown level1 summary"><p>Syntactic sugar for <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.html#Lucene_Net_Search_TimeLimitingCollector_SetBaseline_System_Int64_">SetBaseline(Int64)</a> using <a class="xref" href="Lucene.Net.Util.Counter.html#Lucene_Net_Util_Counter_Get">Get()</a> |
| on the clock passed to the constructor.</p> |
| </div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public virtual void SetBaseline()</code></pre> |
| </div> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_SetBaseline_System_Int64_.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.SetBaseline(System.Int64)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L143">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_SetBaseline_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetBaseline*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_SetBaseline_System_Int64_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetBaseline(System.Int64)">SetBaseline(Int64)</h4> |
| <div class="markdown level1 summary"><p>Sets the baseline for this collector. By default the collectors baseline is |
| initialized once the first reader is passed to the collector. |
| To include operations executed in prior to the actual document collection |
| set the baseline through this method in your prelude. |
| <p> |
| Example usage:</p> |
| <pre><code> // Counter is in the Lucene.Net.Util namespace |
| Counter clock = Counter.NewCounter(true); |
| long baseline = clock.Get(); |
| // ... prepare search |
| TimeLimitingCollector collector = new TimeLimitingCollector(c, clock, numTicks); |
| collector.SetBaseline(baseline); |
| indexSearcher.Search(query, collector);</code></pre> |
| <p> </p> |
| </div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public virtual void SetBaseline(long clockTime)</code></pre> |
| </div> |
| <h5 class="parameters">Parameters</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Name</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><span class="xref">System.Int64</span></td> |
| <td><span class="parametername">clockTime</span></td> |
| <td></td> |
| </tr> |
| </tbody> |
| </table> |
| <h5 id="Lucene_Net_Search_TimeLimitingCollector_SetBaseline_System_Int64__seealso">See Also</h5> |
| <div class="seealso"> |
| <div><a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.html#Lucene_Net_Search_TimeLimitingCollector_SetBaseline">SetBaseline()</a></div> |
| </div> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_SetCollector_Lucene_Net_Search_ICollector_.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.SetCollector(Lucene.Net.Search.ICollector)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L217">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_SetCollector_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetCollector*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_SetCollector_Lucene_Net_Search_ICollector_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetCollector(Lucene.Net.Search.ICollector)">SetCollector(ICollector)</h4> |
| <div class="markdown level1 summary"><p>This is so the same timer can be used with a multi-phase search process such as grouping. |
| We don't want to create a new <a class="xref" href="Lucene.Net.Search.TimeLimitingCollector.html">TimeLimitingCollector</a> for each phase because that would |
| reset the timer for each phase. Once time is up subsequent phases need to timeout quickly.</p> |
| </div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public virtual void SetCollector(ICollector collector)</code></pre> |
| </div> |
| <h5 class="parameters">Parameters</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Name</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><a class="xref" href="Lucene.Net.Search.ICollector.html">ICollector</a></td> |
| <td><span class="parametername">collector</span></td> |
| <td><p>The actual collector performing search functionality. </p> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_SetNextReader_Lucene_Net_Index_AtomicReaderContext_.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.SetNextReader(Lucene.Net.Index.AtomicReaderContext)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L194">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_SetNextReader_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetNextReader*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_SetNextReader_Lucene_Net_Index_AtomicReaderContext_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetNextReader(Lucene.Net.Index.AtomicReaderContext)">SetNextReader(AtomicReaderContext)</h4> |
| <div class="markdown level1 summary"></div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public virtual void SetNextReader(AtomicReaderContext context)</code></pre> |
| </div> |
| <h5 class="parameters">Parameters</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Name</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><a class="xref" href="Lucene.Net.Index.AtomicReaderContext.html">AtomicReaderContext</a></td> |
| <td><span class="parametername">context</span></td> |
| <td></td> |
| </tr> |
| </tbody> |
| </table> |
| <span class="small pull-right mobile-hide"> |
| <span class="divider">|</span> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector_SetScorer_Lucene_Net_Search_Scorer_.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector.SetScorer(Lucene.Net.Search.Scorer)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a> |
| </span> |
| <span class="small pull-right mobile-hide"> |
| <a href="https://github.com/NightOwl888/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L204">View Source</a> |
| </span> |
| <a id="Lucene_Net_Search_TimeLimitingCollector_SetScorer_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetScorer*"></a> |
| <h4 id="Lucene_Net_Search_TimeLimitingCollector_SetScorer_Lucene_Net_Search_Scorer_" data-uid="Lucene.Net.Search.TimeLimitingCollector.SetScorer(Lucene.Net.Search.Scorer)">SetScorer(Scorer)</h4> |
| <div class="markdown level1 summary"></div> |
| <div class="markdown level1 conceptual"></div> |
| <h5 class="decalaration">Declaration</h5> |
| <div class="codewrapper"> |
| <pre><code class="lang-csharp hljs">public virtual void SetScorer(Scorer scorer)</code></pre> |
| </div> |
| <h5 class="parameters">Parameters</h5> |
| <table class="table table-bordered table-striped table-condensed"> |
| <thead> |
| <tr> |
| <th>Type</th> |
| <th>Name</th> |
| <th>Description</th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td><a class="xref" href="Lucene.Net.Search.Scorer.html">Scorer</a></td> |
| <td><span class="parametername">scorer</span></td> |
| <td></td> |
| </tr> |
| </tbody> |
| </table> |
| <h3 id="implements">Implements</h3> |
| <div> |
| <a class="xref" href="Lucene.Net.Search.ICollector.html">ICollector</a> |
| </div> |
| </article> |
| </div> |
| |
| <div class="hidden-sm col-md-2" role="complementary"> |
| <div class="sideaffix"> |
| <div class="contribution"> |
| <ul class="nav"> |
| <li> |
| <a href="https://github.com/apache/lucenenet/new/docs/4.8.0-beta00010/websites/apidocs/apiSpec/new?filename=Lucene_Net_Search_TimeLimitingCollector.md&value=---%0Auid%3A%20Lucene.Net.Search.TimeLimitingCollector%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A" class="contribution-link">Improve this Doc</a> |
| </li> |
| <li> |
| <a href="https://github.com/apache/lucenenet/blob/release/Lucene.Net_4_8_0_beta00010/src/Lucene.Net/Search/TimeLimitingCollector.cs/#L37" class="contribution-link">View Source</a> |
| </li> |
| </ul> |
| </div> |
| <nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix"> |
| <!-- <p><a class="back-to-top" href="#top">Back to top</a><p> --> |
| </nav> |
| </div> |
| </div> |
| </div> |
| </div> |
| |
| <footer> |
| <div class="grad-bottom"></div> |
| <div class="footer"> |
| <div class="container"> |
| <span class="pull-right"> |
| <a href="#top">Back to top</a> |
| </span> |
| Copyright © 2020 Licensed to the Apache Software Foundation (ASF) |
| |
| </div> |
| </div> |
| </footer> |
| </div> |
| |
| <script type="text/javascript" src="https://lucenenet.apache.org/docs/4.8.0-beta00009/styles/docfx.vendor.js"></script> |
| <script type="text/javascript" src="https://lucenenet.apache.org/docs/4.8.0-beta00009/styles/docfx.js"></script> |
| <script type="text/javascript" src="https://lucenenet.apache.org/docs/4.8.0-beta00009/styles/main.js"></script> |
| </body> |
| </html> |