<divclass="inheritance"title="Inheritance Tree"><ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html"title="class or interface in java.lang"class="external-link">java.lang.Object</a>
<divclass="type-signature"><spanclass="modifiers">public final class </span><spanclass="element-name type-name-label">ServicePool</span>
<spanclass="extends-implements">extends <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html"title="class or interface in java.lang"class="external-link">Object</a></span></div>
</section>
<sectionclass="summary">
<ulclass="summary-list">
<!-- =========== FIELD SUMMARY =========== -->
<li>
<sectionclass="field-summary"id="field-summary">
<h2>Field Summary</h2>
<divclass="caption"><span>Fields</span></div>
<divclass="summary-table three-column-summary">
<divclass="table-header col-first">Modifier and Type</div>
<divclass="col-first even-row-color"><code>private final <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Set.html"title="class or interface in java.util"class="external-link">Set</a><<ahref="../api/IService.html"title="interface in io.github.simplex.api">IService</a>></code></div>
<divclass="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>@NotNull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Set.html"title="class or interface in java.util"class="external-link">Set</a><<ahref="../api/IService.html"title="interface in io.github.simplex.api">IService</a>></code></div>
<divclass="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>@NotNull reactor.core.publisher.Mono<<ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Void.html"title="class or interface in java.lang"class="external-link">Void</a>></code></div>
<divclass="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>@NotNull reactor.core.publisher.Mono<<ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Void.html"title="class or interface in java.lang"class="external-link">Void</a>></code></div>
<h3id="methods-inherited-from-class-java.lang.Object">Methods inherited from class java.lang.<ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html"title="class or interface in java.lang"class="external-link">Object</a></h3>
<code><ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#clone()"title="class or interface in java.lang"class="external-link">clone</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#equals(java.lang.Object)"title="class or interface in java.lang"class="external-link">equals</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#finalize()"title="class or interface in java.lang"class="external-link">finalize</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#getClass()"title="class or interface in java.lang"class="external-link">getClass</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#hashCode()"title="class or interface in java.lang"class="external-link">hashCode</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#notify()"title="class or interface in java.lang"class="external-link">notify</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#notifyAll()"title="class or interface in java.lang"class="external-link">notifyAll</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#toString()"title="class or interface in java.lang"class="external-link">toString</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait()"title="class or interface in java.lang"class="external-link">wait</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait(long)"title="class or interface in java.lang"class="external-link">wait</a>, <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait(long,int)"title="class or interface in java.lang"class="external-link">wait</a></code></div>
</section>
</li>
</ul>
</section>
<sectionclass="details">
<ulclass="details-list">
<!-- ============ FIELD DETAIL =========== -->
<li>
<sectionclass="field-details"id="field-detail">
<h2>Field Details</h2>
<ulclass="member-list">
<li>
<sectionclass="detail"id="associatedServices">
<h3>associatedServices</h3>
<divclass="member-signature"><spanclass="modifiers">private final</span> <spanclass="return-type"><ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Set.html"title="class or interface in java.util"class="external-link">Set</a><<ahref="../api/IService.html"title="interface in io.github.simplex.api">IService</a>></span> <spanclass="element-name">associatedServices</span></div>
<divclass="member-signature"><spanclass="return-type">void</span> <spanclass="element-name">addService</span><wbr><spanclass="parameters">(<ahref="../api/IService.html"title="interface in io.github.simplex.api">IService</a> service)</span></div>
<divclass="member-signature"><spanclass="return-type">boolean</span> <spanclass="element-name">isValidService</span><wbr><spanclass="parameters">(<ahref="../api/IService.html"title="interface in io.github.simplex.api">IService</a> service)</span></div>
</span><spanclass="modifiers">public</span> <spanclass="return-type">@NotNull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Set.html"title="class or interface in java.util"class="external-link">Set</a><<ahref="../api/IService.html"title="interface in io.github.simplex.api">IService</a>></span> <spanclass="element-name">getAssociatedServices</span>()</div>
<dd>A <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Set.html"title="class or interface in java.util"class="external-link"><code>Set</code></a> of <ahref="../api/IService.html"title="interface in io.github.simplex.api"><code>IService</code></a> objects which are registered with this pool.</dd>
<dd>A <code>Flux</code> object which contains a collection of <code>Disposable</code> elements,
which can be used to destroy the registered services using <ahref="#stopServices(reactor.core.publisher.Flux)"><code>stopServices(Flux<Disposable>)</code></a>.</dd>
</span><spanclass="modifiers">public</span> <spanclass="return-type">@NotNull reactor.core.publisher.Mono<<ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Void.html"title="class or interface in java.lang"class="external-link">Void</a>></span> <spanclass="element-name">stopServices</span><wbr><spanclass="parameters">(@NotNull
<dd><code>disposableThread</code> - A <code>reactor.core.publisher.Flux<reactor.core.Disposable></code> which contains all the services that should be disposed..</dd>
<dt>Returns:</dt>
<dd>A <code>reactor.core.publisher.Mono<<ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Void.html"title="class or interface in java.lang"class="external-link">Void</a>></code> object which can be used to stop the services.</dd>
</span><spanclass="modifiers">public</span> <spanclass="return-type">@NotNull reactor.core.publisher.Mono<<ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Void.html"title="class or interface in java.lang"class="external-link">Void</a>></span> <spanclass="element-name">stopService</span><wbr><spanclass="parameters">(@NotNull
<dd><code>service_name</code> - The name of the service to stop.</dd>
<dd><code>disposable</code> - A <code>Disposable</code> object which contains the service that should be disposed.</dd>
<dt>Returns:</dt>
<dd>A <code>reactor.core.publisher.Mono<<ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Void.html"title="class or interface in java.lang"class="external-link">Void</a>></code> object which can be used to stop the service.</dd>
</span><spanclass="modifiers">public</span> <spanclass="return-type">@NotNull reactor.core.publisher.Mono<<ahref="../api/IService.html"title="interface in io.github.simplex.api">IService</a>></span> <spanclass="element-name">getService</span><wbr><spanclass="parameters">(org.bukkit.NamespacedKey service_name)</span></div>
<dlclass="notes">
<dt>Parameters:</dt>
<dd><code>service_name</code> - The name of the service to get.</dd>
<dt>Returns:</dt>
<dd>A <code>Mono</code> object which contains the service.</dd>
<divclass="member-signature"><spanclass="return-type">void</span> <spanclass="element-name">removeService</span><wbr><spanclass="parameters">(<ahref="../api/IService.html"title="interface in io.github.simplex.api">IService</a> service)</span></div>
</span><spanclass="modifiers">public</span> <spanclass="return-type">@NotNull reactor.core.publisher.Mono<<ahref="ServicePool.html"title="class in io.github.simplex.simplexss">ServicePool</a>></span> <spanclass="element-name">recycle</span>()</div>
<dlclass="notes">
<dt>Returns:</dt>
<dd>This service pool after being cleared of all services.
You will need to register services with this pool again before using it.</dd>