You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

628 lines
34 KiB

  1. <!DOCTYPE html>
  2. <!--[if IE]><![endif]-->
  3. <html>
  4. <head>
  5. <meta charset="utf-8">
  6. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  7. <title>Class SingleThreadTaskScheduler
  8. </title>
  9. <meta name="viewport" content="width=device-width">
  10. <meta name="title" content="Class SingleThreadTaskScheduler
  11. ">
  12. <meta name="generator" content="docfx 2.48.0.0">
  13. <link rel="shortcut icon" href="../favicon.ico">
  14. <link rel="stylesheet" href="../styles/docfx.vendor.css">
  15. <link rel="stylesheet" href="../styles/docfx.css">
  16. <link rel="stylesheet" href="../styles/main.css">
  17. <link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
  18. <meta property="docfx:navrel" content="../toc.html">
  19. <meta property="docfx:tocrel" content="toc.html">
  20. <meta property="docfx:rel" content="../">
  21. <meta property="docfx:newtab" content="true">
  22. </head> <body data-spy="scroll" data-target="#affix" data-offset="120">
  23. <div id="wrapper">
  24. <header>
  25. <nav id="autocollapse" class="navbar navbar-inverse ng-scope" role="navigation">
  26. <div class="container">
  27. <div class="navbar-header">
  28. <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar">
  29. <span class="sr-only">Toggle navigation</span>
  30. <span class="icon-bar"></span>
  31. <span class="icon-bar"></span>
  32. <span class="icon-bar"></span>
  33. </button>
  34. <a class="navbar-brand" href="../index.html">
  35. <img id="logo" class="svg" src="../logo.svg" alt="">
  36. </a>
  37. </div>
  38. <div class="collapse navbar-collapse" id="navbar">
  39. <form class="navbar-form navbar-right" role="search" id="search">
  40. <div class="form-group">
  41. <input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off">
  42. </div>
  43. </form>
  44. </div>
  45. </div>
  46. </nav>
  47. <div class="subnav navbar navbar-default">
  48. <div class="container hide-when-search" id="breadcrumb">
  49. <ul class="breadcrumb">
  50. <li></li>
  51. </ul>
  52. </div>
  53. </div>
  54. </header>
  55. <div class="container body-content">
  56. <div id="search-results">
  57. <div class="search-list"></div>
  58. <div class="sr-items">
  59. <p><i class="glyphicon glyphicon-refresh index-loading"></i></p>
  60. </div>
  61. <ul id="pagination"></ul>
  62. </div>
  63. </div>
  64. <div role="main" class="container body-content hide-when-search">
  65. <div class="sidenav hide-when-search">
  66. <a class="btn toc-toggle collapse" data-toggle="collapse" href="#sidetoggle" aria-expanded="false" aria-controls="sidetoggle">Show / Hide Table of Contents</a>
  67. <div class="sidetoggle collapse" id="sidetoggle">
  68. <div id="sidetoc"></div>
  69. </div>
  70. </div>
  71. <div class="article row grid-right">
  72. <div class="col-md-10">
  73. <article class="content wrap" id="_content" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler">
  74. <h1 id="IPA_Utilities_Async_SingleThreadTaskScheduler" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler" class="text-break">Class SingleThreadTaskScheduler
  75. </h1>
  76. <div class="markdown level0 summary"><p>A single-threaded task scheduler that runs all of its tasks on the same thread.</p>
  77. </div>
  78. <div class="markdown level0 conceptual"></div>
  79. <div class="inheritance">
  80. <h5>Inheritance</h5>
  81. <div class="level0"><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object">Object</a></div>
  82. <div class="level1"><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler">TaskScheduler</a></div>
  83. <div class="level2"><span class="xref">SingleThreadTaskScheduler</span></div>
  84. </div>
  85. <div classs="implements">
  86. <h5>Implements</h5>
  87. <div><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.idisposable">IDisposable</a></div>
  88. </div>
  89. <div class="inheritedMembers">
  90. <h5>Inherited Members</h5>
  91. <div>
  92. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.trydequeue#System_Threading_Tasks_TaskScheduler_TryDequeue_System_Threading_Tasks_Task_">TaskScheduler.TryDequeue(Task)</a>
  93. </div>
  94. <div>
  95. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.fromcurrentsynchronizationcontext#System_Threading_Tasks_TaskScheduler_FromCurrentSynchronizationContext">TaskScheduler.FromCurrentSynchronizationContext()</a>
  96. </div>
  97. <div>
  98. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.tryexecutetask#System_Threading_Tasks_TaskScheduler_TryExecuteTask_System_Threading_Tasks_Task_">TaskScheduler.TryExecuteTask(Task)</a>
  99. </div>
  100. <div>
  101. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.maximumconcurrencylevel#System_Threading_Tasks_TaskScheduler_MaximumConcurrencyLevel">TaskScheduler.MaximumConcurrencyLevel</a>
  102. </div>
  103. <div>
  104. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.default#System_Threading_Tasks_TaskScheduler_Default">TaskScheduler.Default</a>
  105. </div>
  106. <div>
  107. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.current#System_Threading_Tasks_TaskScheduler_Current">TaskScheduler.Current</a>
  108. </div>
  109. <div>
  110. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.id#System_Threading_Tasks_TaskScheduler_Id">TaskScheduler.Id</a>
  111. </div>
  112. <div>
  113. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.unobservedtaskexception">TaskScheduler.UnobservedTaskException</a>
  114. </div>
  115. <div>
  116. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.tostring#System_Object_ToString">Object.ToString()</a>
  117. </div>
  118. <div>
  119. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.equals#System_Object_Equals_System_Object_">Object.Equals(Object)</a>
  120. </div>
  121. <div>
  122. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.equals#System_Object_Equals_System_Object_System_Object_">Object.Equals(Object, Object)</a>
  123. </div>
  124. <div>
  125. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.referenceequals#System_Object_ReferenceEquals_System_Object_System_Object_">Object.ReferenceEquals(Object, Object)</a>
  126. </div>
  127. <div>
  128. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.gethashcode#System_Object_GetHashCode">Object.GetHashCode()</a>
  129. </div>
  130. <div>
  131. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.gettype#System_Object_GetType">Object.GetType()</a>
  132. </div>
  133. <div>
  134. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.memberwiseclone#System_Object_MemberwiseClone">Object.MemberwiseClone()</a>
  135. </div>
  136. </div>
  137. <h6><strong>Namespace</strong>: <a class="xref" href="IPA.Utilities.Async.html">IPA.Utilities.Async</a></h6>
  138. <h6><strong>Assembly</strong>: IPA.Loader.dll</h6>
  139. <h5 id="IPA_Utilities_Async_SingleThreadTaskScheduler_syntax">Syntax</h5>
  140. <div class="codewrapper">
  141. <pre><code class="lang-csharp hljs">public class SingleThreadTaskScheduler : TaskScheduler, IDisposable</code></pre>
  142. </div>
  143. <h3 id="properties">Properties
  144. </h3>
  145. <span class="small pull-right mobile-hide">
  146. <span class="divider">|</span>
  147. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_IsRunning.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.IsRunning%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>
  148. </span>
  149. <span class="small pull-right mobile-hide">
  150. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L24">View Source</a>
  151. </span>
  152. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_IsRunning_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.IsRunning*"></a>
  153. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_IsRunning" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.IsRunning">IsRunning</h4>
  154. <div class="markdown level1 summary"><p>Gets whether or not the underlying thread has been started.</p>
  155. </div>
  156. <div class="markdown level1 conceptual"></div>
  157. <h5 class="decalaration">Declaration</h5>
  158. <div class="codewrapper">
  159. <pre><code class="lang-csharp hljs">public bool IsRunning { get; }</code></pre>
  160. </div>
  161. <h5 class="propertyValue">Property Value</h5>
  162. <table class="table table-bordered table-striped table-condensed">
  163. <thead>
  164. <tr>
  165. <th>Type</th>
  166. <th>Description</th>
  167. </tr>
  168. </thead>
  169. <tbody>
  170. <tr>
  171. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.boolean">Boolean</a></td>
  172. <td></td>
  173. </tr>
  174. </tbody>
  175. </table>
  176. <h5 class="exceptions">Exceptions</h5>
  177. <table class="table table-bordered table-striped table-condensed">
  178. <thead>
  179. <tr>
  180. <th>Type</th>
  181. <th>Condition</th>
  182. </tr>
  183. </thead>
  184. <tbody>
  185. <tr>
  186. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.invalidoperationexception">InvalidOperationException</a></td>
  187. <td><p>Thrown if this object has already been disposed.</p>
  188. </td>
  189. </tr>
  190. </tbody>
  191. </table>
  192. <h3 id="methods">Methods
  193. </h3>
  194. <span class="small pull-right mobile-hide">
  195. <span class="divider">|</span>
  196. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_Dispose.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.Dispose%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>
  197. </span>
  198. <span class="small pull-right mobile-hide">
  199. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L179">View Source</a>
  200. </span>
  201. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_Dispose_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Dispose*"></a>
  202. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_Dispose" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Dispose">Dispose()</h4>
  203. <div class="markdown level1 summary"><p>Disposes this object. This puts the object into an unusable state.</p>
  204. </div>
  205. <div class="markdown level1 conceptual"></div>
  206. <h5 class="decalaration">Declaration</h5>
  207. <div class="codewrapper">
  208. <pre><code class="lang-csharp hljs">public void Dispose()</code></pre>
  209. </div>
  210. <span class="small pull-right mobile-hide">
  211. <span class="divider">|</span>
  212. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_Dispose_System_Boolean_.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.Dispose(System.Boolean)%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>
  213. </span>
  214. <span class="small pull-right mobile-hide">
  215. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L162">View Source</a>
  216. </span>
  217. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_Dispose_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Dispose*"></a>
  218. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_Dispose_System_Boolean_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Dispose(System.Boolean)">Dispose(Boolean)</h4>
  219. <div class="markdown level1 summary"><p>Disposes this object.</p>
  220. </div>
  221. <div class="markdown level1 conceptual"></div>
  222. <h5 class="decalaration">Declaration</h5>
  223. <div class="codewrapper">
  224. <pre><code class="lang-csharp hljs">protected virtual void Dispose(bool disposing)</code></pre>
  225. </div>
  226. <h5 class="parameters">Parameters</h5>
  227. <table class="table table-bordered table-striped table-condensed">
  228. <thead>
  229. <tr>
  230. <th>Type</th>
  231. <th>Name</th>
  232. <th>Description</th>
  233. </tr>
  234. </thead>
  235. <tbody>
  236. <tr>
  237. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.boolean">Boolean</a></td>
  238. <td><span class="parametername">disposing</span></td>
  239. <td><p>whether or not to dispose managed objects</p>
  240. </td>
  241. </tr>
  242. </tbody>
  243. </table>
  244. <span class="small pull-right mobile-hide">
  245. <span class="divider">|</span>
  246. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_Exit.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.Exit%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>
  247. </span>
  248. <span class="small pull-right mobile-hide">
  249. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L52">View Source</a>
  250. </span>
  251. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_Exit_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Exit*"></a>
  252. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_Exit" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Exit">Exit()</h4>
  253. <div class="markdown level1 summary"><p>Terminates the runner thread, and waits for the currently running task to complete.</p>
  254. </div>
  255. <div class="markdown level1 conceptual"></div>
  256. <h5 class="decalaration">Declaration</h5>
  257. <div class="codewrapper">
  258. <pre><code class="lang-csharp hljs">public IEnumerable&lt;Task&gt; Exit()</code></pre>
  259. </div>
  260. <h5 class="returns">Returns</h5>
  261. <table class="table table-bordered table-striped table-condensed">
  262. <thead>
  263. <tr>
  264. <th>Type</th>
  265. <th>Description</th>
  266. </tr>
  267. </thead>
  268. <tbody>
  269. <tr>
  270. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1">IEnumerable</a>&lt;<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task">Task</a>&gt;</td>
  271. <td><p>an <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1">IEnumerable&lt;T&gt;</a> of <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task">Task</a>s that did not execute</p>
  272. </td>
  273. </tr>
  274. </tbody>
  275. </table>
  276. <h5 id="IPA_Utilities_Async_SingleThreadTaskScheduler_Exit_remarks">Remarks</h5>
  277. <div class="markdown level1 remarks"><p>After this method returns, this object has been disposed and is no longer in a valid state.</p>
  278. </div>
  279. <h5 class="exceptions">Exceptions</h5>
  280. <table class="table table-bordered table-striped table-condensed">
  281. <thead>
  282. <tr>
  283. <th>Type</th>
  284. <th>Condition</th>
  285. </tr>
  286. </thead>
  287. <tbody>
  288. <tr>
  289. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.invalidoperationexception">InvalidOperationException</a></td>
  290. <td><p>Thrown if this object has already been disposed.</p>
  291. </td>
  292. </tr>
  293. </tbody>
  294. </table>
  295. <span class="small pull-right mobile-hide">
  296. <span class="divider">|</span>
  297. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_GetScheduledTasks.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.GetScheduledTasks%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>
  298. </span>
  299. <span class="small pull-right mobile-hide">
  300. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L86">View Source</a>
  301. </span>
  302. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_GetScheduledTasks_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.GetScheduledTasks*"></a>
  303. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_GetScheduledTasks" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.GetScheduledTasks">GetScheduledTasks()</h4>
  304. <div class="markdown level1 summary"><p>Throws a <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.notsupportedexception">NotSupportedException</a>.</p>
  305. </div>
  306. <div class="markdown level1 conceptual"></div>
  307. <h5 class="decalaration">Declaration</h5>
  308. <div class="codewrapper">
  309. <pre><code class="lang-csharp hljs">protected override IEnumerable&lt;Task&gt; GetScheduledTasks()</code></pre>
  310. </div>
  311. <h5 class="returns">Returns</h5>
  312. <table class="table table-bordered table-striped table-condensed">
  313. <thead>
  314. <tr>
  315. <th>Type</th>
  316. <th>Description</th>
  317. </tr>
  318. </thead>
  319. <tbody>
  320. <tr>
  321. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1">IEnumerable</a>&lt;<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task">Task</a>&gt;</td>
  322. <td><p>nothing</p>
  323. </td>
  324. </tr>
  325. </tbody>
  326. </table>
  327. <h5 class="overrides">Overrides</h5>
  328. <div><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.getscheduledtasks#System_Threading_Tasks_TaskScheduler_GetScheduledTasks">TaskScheduler.GetScheduledTasks()</a></div>
  329. <h5 class="exceptions">Exceptions</h5>
  330. <table class="table table-bordered table-striped table-condensed">
  331. <thead>
  332. <tr>
  333. <th>Type</th>
  334. <th>Condition</th>
  335. </tr>
  336. </thead>
  337. <tbody>
  338. <tr>
  339. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.notsupportedexception">NotSupportedException</a></td>
  340. <td><p>Always.</p>
  341. </td>
  342. </tr>
  343. </tbody>
  344. </table>
  345. <span class="small pull-right mobile-hide">
  346. <span class="divider">|</span>
  347. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_Join.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.Join%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>
  348. </span>
  349. <span class="small pull-right mobile-hide">
  350. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L73">View Source</a>
  351. </span>
  352. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_Join_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Join*"></a>
  353. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_Join" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Join">Join()</h4>
  354. <div class="markdown level1 summary"><p>Waits for the runner thread to complete all tasks in the queue, then exits.</p>
  355. </div>
  356. <div class="markdown level1 conceptual"></div>
  357. <h5 class="decalaration">Declaration</h5>
  358. <div class="codewrapper">
  359. <pre><code class="lang-csharp hljs">public void Join()</code></pre>
  360. </div>
  361. <h5 id="IPA_Utilities_Async_SingleThreadTaskScheduler_Join_remarks">Remarks</h5>
  362. <div class="markdown level1 remarks"><p>After this method returns, this object has been disposed and is no longer in a valid state.</p>
  363. </div>
  364. <h5 class="exceptions">Exceptions</h5>
  365. <table class="table table-bordered table-striped table-condensed">
  366. <thead>
  367. <tr>
  368. <th>Type</th>
  369. <th>Condition</th>
  370. </tr>
  371. </thead>
  372. <tbody>
  373. <tr>
  374. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.invalidoperationexception">InvalidOperationException</a></td>
  375. <td><p>Thrown if this object has already been disposed.</p>
  376. </td>
  377. </tr>
  378. </tbody>
  379. </table>
  380. <span class="small pull-right mobile-hide">
  381. <span class="divider">|</span>
  382. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_QueueTask_System_Threading_Tasks_Task_.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.QueueTask(System.Threading.Tasks.Task)%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>
  383. </span>
  384. <span class="small pull-right mobile-hide">
  385. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L98">View Source</a>
  386. </span>
  387. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_QueueTask_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.QueueTask*"></a>
  388. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_QueueTask_System_Threading_Tasks_Task_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.QueueTask(System.Threading.Tasks.Task)">QueueTask(Task)</h4>
  389. <div class="markdown level1 summary"><p>Queues a given <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task">Task</a> to this scheduler. The <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task">Task</a> <em>must&gt;</em> be
  390. scheduled for this <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler">TaskScheduler</a> by the runtime.</p>
  391. </div>
  392. <div class="markdown level1 conceptual"></div>
  393. <h5 class="decalaration">Declaration</h5>
  394. <div class="codewrapper">
  395. <pre><code class="lang-csharp hljs">protected override void QueueTask(Task task)</code></pre>
  396. </div>
  397. <h5 class="parameters">Parameters</h5>
  398. <table class="table table-bordered table-striped table-condensed">
  399. <thead>
  400. <tr>
  401. <th>Type</th>
  402. <th>Name</th>
  403. <th>Description</th>
  404. </tr>
  405. </thead>
  406. <tbody>
  407. <tr>
  408. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task">Task</a></td>
  409. <td><span class="parametername">task</span></td>
  410. <td><p>the <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task">Task</a> to queue</p>
  411. </td>
  412. </tr>
  413. </tbody>
  414. </table>
  415. <h5 class="overrides">Overrides</h5>
  416. <div><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.queuetask#System_Threading_Tasks_TaskScheduler_QueueTask_System_Threading_Tasks_Task_">TaskScheduler.QueueTask(Task)</a></div>
  417. <h5 class="exceptions">Exceptions</h5>
  418. <table class="table table-bordered table-striped table-condensed">
  419. <thead>
  420. <tr>
  421. <th>Type</th>
  422. <th>Condition</th>
  423. </tr>
  424. </thead>
  425. <tbody>
  426. <tr>
  427. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.invalidoperationexception">InvalidOperationException</a></td>
  428. <td><p>Thrown if this object has already been disposed.</p>
  429. </td>
  430. </tr>
  431. </tbody>
  432. </table>
  433. <span class="small pull-right mobile-hide">
  434. <span class="divider">|</span>
  435. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_Start.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.Start%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>
  436. </span>
  437. <span class="small pull-right mobile-hide">
  438. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L37">View Source</a>
  439. </span>
  440. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_Start_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Start*"></a>
  441. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_Start" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.Start">Start()</h4>
  442. <div class="markdown level1 summary"><p>Starts the thread that executes tasks scheduled with this <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler">TaskScheduler</a></p>
  443. </div>
  444. <div class="markdown level1 conceptual"></div>
  445. <h5 class="decalaration">Declaration</h5>
  446. <div class="codewrapper">
  447. <pre><code class="lang-csharp hljs">public void Start()</code></pre>
  448. </div>
  449. <h5 class="exceptions">Exceptions</h5>
  450. <table class="table table-bordered table-striped table-condensed">
  451. <thead>
  452. <tr>
  453. <th>Type</th>
  454. <th>Condition</th>
  455. </tr>
  456. </thead>
  457. <tbody>
  458. <tr>
  459. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.invalidoperationexception">InvalidOperationException</a></td>
  460. <td><p>Thrown if this object has already been disposed.</p>
  461. </td>
  462. </tr>
  463. </tbody>
  464. </table>
  465. <span class="small pull-right mobile-hide">
  466. <span class="divider">|</span>
  467. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler_TryExecuteTaskInline_System_Threading_Tasks_Task_System_Boolean_.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler.TryExecuteTaskInline(System.Threading.Tasks.Task%2CSystem.Boolean)%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>
  468. </span>
  469. <span class="small pull-right mobile-hide">
  470. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L116">View Source</a>
  471. </span>
  472. <a id="IPA_Utilities_Async_SingleThreadTaskScheduler_TryExecuteTaskInline_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.TryExecuteTaskInline*"></a>
  473. <h4 id="IPA_Utilities_Async_SingleThreadTaskScheduler_TryExecuteTaskInline_System_Threading_Tasks_Task_System_Boolean_" data-uid="IPA.Utilities.Async.SingleThreadTaskScheduler.TryExecuteTaskInline(System.Threading.Tasks.Task,System.Boolean)">TryExecuteTaskInline(Task, Boolean)</h4>
  474. <div class="markdown level1 summary"><p>Rejects any attempts to execute a task inline.</p>
  475. </div>
  476. <div class="markdown level1 conceptual"></div>
  477. <h5 class="decalaration">Declaration</h5>
  478. <div class="codewrapper">
  479. <pre><code class="lang-csharp hljs">protected override bool TryExecuteTaskInline(Task task, bool taskWasPreviouslyQueued)</code></pre>
  480. </div>
  481. <h5 class="parameters">Parameters</h5>
  482. <table class="table table-bordered table-striped table-condensed">
  483. <thead>
  484. <tr>
  485. <th>Type</th>
  486. <th>Name</th>
  487. <th>Description</th>
  488. </tr>
  489. </thead>
  490. <tbody>
  491. <tr>
  492. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task">Task</a></td>
  493. <td><span class="parametername">task</span></td>
  494. <td><p>the task to attempt to execute</p>
  495. </td>
  496. </tr>
  497. <tr>
  498. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.boolean">Boolean</a></td>
  499. <td><span class="parametername">taskWasPreviouslyQueued</span></td>
  500. <td><p>whether the task was previously queued to this scheduler</p>
  501. </td>
  502. </tr>
  503. </tbody>
  504. </table>
  505. <h5 class="returns">Returns</h5>
  506. <table class="table table-bordered table-striped table-condensed">
  507. <thead>
  508. <tr>
  509. <th>Type</th>
  510. <th>Description</th>
  511. </tr>
  512. </thead>
  513. <tbody>
  514. <tr>
  515. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.boolean">Boolean</a></td>
  516. <td><span class="xref">false</span></td>
  517. </tr>
  518. </tbody>
  519. </table>
  520. <h5 class="overrides">Overrides</h5>
  521. <div><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.taskscheduler.tryexecutetaskinline#System_Threading_Tasks_TaskScheduler_TryExecuteTaskInline_System_Threading_Tasks_Task_System_Boolean_">TaskScheduler.TryExecuteTaskInline(Task, Boolean)</a></div>
  522. <h5 id="IPA_Utilities_Async_SingleThreadTaskScheduler_TryExecuteTaskInline_System_Threading_Tasks_Task_System_Boolean__remarks">Remarks</h5>
  523. <div class="markdown level1 remarks"><p>This task scheduler <em>always</em> runs its tasks on the thread that it manages, therefore it doesn&apos;t
  524. make sense to run it inline.</p>
  525. </div>
  526. <h5 class="exceptions">Exceptions</h5>
  527. <table class="table table-bordered table-striped table-condensed">
  528. <thead>
  529. <tr>
  530. <th>Type</th>
  531. <th>Condition</th>
  532. </tr>
  533. </thead>
  534. <tbody>
  535. <tr>
  536. <td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.invalidoperationexception">InvalidOperationException</a></td>
  537. <td><p>Thrown if this object has already been disposed.</p>
  538. </td>
  539. </tr>
  540. </tbody>
  541. </table>
  542. <h3 id="implements">Implements</h3>
  543. <div>
  544. <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.idisposable">System.IDisposable</a>
  545. </div>
  546. <h3 id="extensionmethods">Extension Methods</h3>
  547. <div>
  548. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_SetField_System_Object_System_String_System_Object_">ReflectionUtil.SetField(Object, String, Object)</a>
  549. </div>
  550. <div>
  551. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_SetField__1___0_System_String_System_Object_">ReflectionUtil.SetField&lt;T&gt;(T, String, Object)</a>
  552. </div>
  553. <div>
  554. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_GetField__1_System_Object_System_String_">ReflectionUtil.GetField&lt;T&gt;(Object, String)</a>
  555. </div>
  556. <div>
  557. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_GetField__2___1_System_String_">ReflectionUtil.GetField&lt;T, U&gt;(U, String)</a>
  558. </div>
  559. <div>
  560. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_SetProperty_System_Object_System_String_System_Object_">ReflectionUtil.SetProperty(Object, String, Object)</a>
  561. </div>
  562. <div>
  563. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_SetProperty__1___0_System_String_System_Object_">ReflectionUtil.SetProperty&lt;T&gt;(T, String, Object)</a>
  564. </div>
  565. <div>
  566. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_InvokeMethod_System_Object_System_String_System_Object___">ReflectionUtil.InvokeMethod(Object, String, Object[])</a>
  567. </div>
  568. <div>
  569. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_InvokeMethod__1___0_System_String_System_Object___">ReflectionUtil.InvokeMethod&lt;T&gt;(T, String, Object[])</a>
  570. </div>
  571. <div>
  572. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_InvokeMethod__1_System_Object_System_String_System_Object___">ReflectionUtil.InvokeMethod&lt;T&gt;(Object, String, Object[])</a>
  573. </div>
  574. <div>
  575. <a class="xref" href="IPA.Utilities.ReflectionUtil.html#IPA_Utilities_ReflectionUtil_InvokeMethod__2___1_System_String_System_Object___">ReflectionUtil.InvokeMethod&lt;T, U&gt;(U, String, Object[])</a>
  576. </div>
  577. </article>
  578. </div>
  579. <div class="hidden-sm col-md-2" role="complementary">
  580. <div class="sideaffix">
  581. <div class="contribution">
  582. <ul class="nav">
  583. <li>
  584. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/new/4.0.0-beta/docs/override/new?filename=IPA_Utilities_Async_SingleThreadTaskScheduler.md&amp;value=---%0Auid%3A%20IPA.Utilities.Async.SingleThreadTaskScheduler%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>
  585. </li>
  586. <li>
  587. <a href="https://github.com/beat-saber-modding-group/BeatSaber-IPA-Reloaded/blob/154f22292e0c2566936beb9f47f26c44274627bb/IPA.Loader/Utilities/Async/SingleThreadTaskScheduler.cs/#L14" class="contribution-link">View Source</a>
  588. </li>
  589. </ul>
  590. </div>
  591. <nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix">
  592. <!-- <p><a class="back-to-top" href="#top">Back to top</a><p> -->
  593. </nav>
  594. </div>
  595. </div>
  596. </div>
  597. </div>
  598. <footer>
  599. <div class="grad-bottom"></div>
  600. <div class="footer">
  601. <div class="container">
  602. <span class="pull-right">
  603. <a href="#top">Back to top</a>
  604. </span>
  605. <span>Generated by <strong>DocFX</strong></span>
  606. </div>
  607. </div>
  608. </footer>
  609. </div>
  610. <script type="text/javascript" src="../styles/docfx.vendor.js"></script>
  611. <script type="text/javascript" src="../styles/docfx.js"></script>
  612. <script type="text/javascript" src="../styles/main.js"></script>
  613. </body>
  614. </html>