blob: 0f918f58ace2481a2467733f48117d4fb16d0452 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<title>SseEventSource</title>
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="SseEventSource";
}
}
catch(err) {
}
//-->
var methods = {"i0":18,"i1":6,"i2":6,"i3":6,"i4":6,"i5":6,"i6":6,"i7":17};
var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"],16:["t5","Default Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../jakarta/ws/rs/sse/SseEventSink.html" title="interface in jakarta.ws.rs.sse"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../jakarta/ws/rs/sse/SseEventSource.Builder.html" title="class in jakarta.ws.rs.sse"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?jakarta/ws/rs/sse/SseEventSource.html" target="_top">Frames</a></li>
<li><a href="SseEventSource.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li><a href="#nested.class.summary">Nested</a>&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">jakarta.ws.rs.sse</div>
<h2 title="Interface SseEventSource" class="title">Interface SseEventSource</h2>
</div>
<div class="contentContainer">
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Superinterfaces:</dt>
<dd>java.lang.AutoCloseable</dd>
</dl>
<hr>
<br>
<pre>public interface <span class="typeNameLabel">SseEventSource</span>
extends java.lang.AutoCloseable</pre>
<div class="block">Client for reading and processing <a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>incoming Server-Sent Events</code></a>.
<p>
SSE event source instances of this class are thread safe. To build a new instance, you can use the
<a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#target-jakarta.ws.rs.client.WebTarget-"><code>SseEventSource.target(endpoint)</code></a> factory method to get a new event
source builder that can be further customised and eventually used to create a new SSE event source.
<p>
Once a <a href="../../../../jakarta/ws/rs/sse/SseEventSource.html" title="interface in jakarta.ws.rs.sse"><code>SseEventSource</code></a> is created, it can be used to <a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#open--"><code>open a connection</code></a> to the associated
<a href="../../../../jakarta/ws/rs/client/WebTarget.html" title="interface in jakarta.ws.rs.client"><code>web target</code></a>. After establishing the connection, the event source starts processing any incoming
inbound events. Whenever a new event is received, an <code>Consumer&lt;InboundSseEvent&gt;#accept(InboundSseEvent)</code> method is invoked on any registered event consumers.
<h2>Reconnect support</h2>
<p>
The <code>SseEventSource</code> supports automated recuperation from a connection loss, including
negotiation of delivery of any missed events based on the last received SSE event <code>id</code> field value, provided
this field is set by the server and the negotiation facility is supported by the server. In case of a connection loss,
the last received SSE event <code>id</code> field value is sent in the
<code><a href="../../../../jakarta/ws/rs/core/HttpHeaders.html#LAST_EVENT_ID_HEADER">"Last-Event-ID"</a></code> HTTP
request header as part of a new connection request sent to the SSE endpoint. Upon a receipt of such reconnect request, the SSE
endpoint that supports this negotiation facility is expected to replay all missed events. Note however, that this is a
best-effort mechanism which does not provide any guaranty that all events would be delivered without a loss. You should
therefore not rely on receiving every single event and design your client application code accordingly.
<p>
By default, when a connection to the SSE endpoint is lost, the event source will wait 500&nbsp;ms
before attempting to reconnect to the SSE endpoint. The SSE endpoint can however control the client-side retry delay
by including a special <code>retry</code> field value in any sent event. JAX-RS <code>SseEventSource</code> tracks any
received SSE event <code>retry</code> field values set by the endpoint and adjusts the reconnect delay accordingly,
using the last received <code>retry</code> field value as the reconnect delay.
<p>
In addition to handling the standard connection loss failures, JAX-RS <code>SseEventSource</code> behaves differently to various
HTTP response status codes and headers:
<ul>
<li>200 - with <code><a href="../../../../jakarta/ws/rs/core/HttpHeaders.html#CONTENT_TYPE">"Content-Type"</a></code> header of "text/event-stream": This is normal
operation. <code>onEvent</code> is invoked for each event. <code>onComplete</code> is invoked when there are no more
events. <code>onError</code> is invoked only if an unrecoverable error occurs during processing.</li>
<li>200 - with unsupported or missing <code><a href="../../../../jakarta/ws/rs/core/HttpHeaders.html#CONTENT_TYPE">"Content-Type"</a></code> header: This is an
error condition. <code>onError</code> is invoked.</li>
<li>204 - This indicates that server has no events to send. Only <code>onComplete</code> is invoked.</li>
<li>503 - with <code><a href="../../../../jakarta/ws/rs/core/HttpHeaders.html#RETRY_AFTER">"Retry-After"</a></code> header set to a valid value: This indicates
that the server is unavailable, but that the client should reconnect later. No consumers are invoked unless the client
event source is closed, prior to reconnecting (resulting in <code>onComplete</code> invocation). After the specified
delay, the client should automatically attempt to reconnect which will result in a new response.</li>
<li>503 - with invalid or missing <code><a href="../../../../jakarta/ws/rs/core/HttpHeaders.html#RETRY_AFTER">"Retry-After"</a></code> header: This is an error
condition. <code>onError</code> is invoked.</li>
<li>Any other status code: This is an error condition. <code>onError</code> is invoked.</li>
</ul>
<p>
In the case of an error condition response, the <code>Throwable</code> passed to the <code>onError</code> consumer
<i>should</i> be a WebApplicationException containing the invalid <code>Response</code> object.</div>
<dl>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>2.1</dd>
</dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== NESTED CLASS SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="nested.class.summary">
<!-- -->
</a>
<h3>Nested Class Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Nested Class Summary table, listing nested classes, and an explanation">
<caption><span>Nested Classes</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Interface and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static class&nbsp;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.Builder.html" title="class in jakarta.ws.rs.sse">SseEventSource.Builder</a></span></code>
<div class="block">JAX-RS <a href="../../../../jakarta/ws/rs/sse/SseEventSource.html" title="interface in jakarta.ws.rs.sse"><code>SseEventSource</code></a> builder class.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t5" class="tableTab"><span><a href="javascript:show(16);">Default Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code>default void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#close--">close</a></span>()</code>
<div class="block">Close this event source.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#close-long-java.util.concurrent.TimeUnit-">close</a></span>(long&nbsp;timeout,
java.util.concurrent.TimeUnit&nbsp;unit)</code>
<div class="block">Close this event source and wait for the internal event processing task to complete for up to the specified amount of
wait time.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#isOpen--">isOpen</a></span>()</code>
<div class="block">Check if this event source instance has already been <a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#open--"><code>opened</code></a>.</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#open--">open</a></span>()</code>
<div class="block">Open the connection to the supplied SSE underlying <a href="../../../../jakarta/ws/rs/client/WebTarget.html" title="interface in jakarta.ws.rs.client"><code>web target</code></a> and start processing incoming
<a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>events</code></a>.</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#register-java.util.function.Consumer-">register</a></span>(java.util.function.Consumer&lt;<a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse">InboundSseEvent</a>&gt;&nbsp;onEvent)</code>
<div class="block">Register a <a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>InboundSseEvent</code></a> consumer.</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#register-java.util.function.Consumer-java.util.function.Consumer-">register</a></span>(java.util.function.Consumer&lt;<a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse">InboundSseEvent</a>&gt;&nbsp;onEvent,
java.util.function.Consumer&lt;java.lang.Throwable&gt;&nbsp;onError)</code>
<div class="block">Register <a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>InboundSseEvent</code></a> and <code>Throwable</code> consumers.</div>
</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#register-java.util.function.Consumer-java.util.function.Consumer-java.lang.Runnable-">register</a></span>(java.util.function.Consumer&lt;<a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse">InboundSseEvent</a>&gt;&nbsp;onEvent,
java.util.function.Consumer&lt;java.lang.Throwable&gt;&nbsp;onError,
java.lang.Runnable&nbsp;onComplete)</code>
<div class="block">Register <a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>InboundSseEvent</code></a> and <code>Throwable</code> consumers and onComplete callback.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code>static <a href="../../../../jakarta/ws/rs/sse/SseEventSource.Builder.html" title="class in jakarta.ws.rs.sse">SseEventSource.Builder</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#target-jakarta.ws.rs.client.WebTarget-">target</a></span>(<a href="../../../../jakarta/ws/rs/client/WebTarget.html" title="interface in jakarta.ws.rs.client">WebTarget</a>&nbsp;endpoint)</code>
<div class="block">Create a new <a href="../../../../jakarta/ws/rs/sse/SseEventSource.Builder.html" title="class in jakarta.ws.rs.sse"><code>event source builder</code></a> that provides convenient way how to configure and
fine-tune various aspects of a newly prepared event source instance.</div>
</td>
</tr>
</table>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="register-java.util.function.Consumer-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>register</h4>
<pre>void&nbsp;register(java.util.function.Consumer&lt;<a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse">InboundSseEvent</a>&gt;&nbsp;onEvent)</pre>
<div class="block">Register a <a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>InboundSseEvent</code></a> consumer.
<p>
Given consumer is invoked once per each received event.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>onEvent</code> - event consumer.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.IllegalArgumentException</code> - when the provided parameter is <code>null</code>.</dd>
</dl>
</li>
</ul>
<a name="register-java.util.function.Consumer-java.util.function.Consumer-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>register</h4>
<pre>void&nbsp;register(java.util.function.Consumer&lt;<a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse">InboundSseEvent</a>&gt;&nbsp;onEvent,
java.util.function.Consumer&lt;java.lang.Throwable&gt;&nbsp;onError)</pre>
<div class="block">Register <a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>InboundSseEvent</code></a> and <code>Throwable</code> consumers.
<p>
Event consumer is invoked once per each received event, <code>Throwable</code> consumer is invoked invoked upon a
unrecoverable error encountered by a <a href="../../../../jakarta/ws/rs/sse/SseEventSource.html" title="interface in jakarta.ws.rs.sse"><code>SseEventSource</code></a>.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>onEvent</code> - event consumer.</dd>
<dd><code>onError</code> - error consumer.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.IllegalArgumentException</code> - when the any of the provided parameters is <code>null</code>.</dd>
</dl>
</li>
</ul>
<a name="register-java.util.function.Consumer-java.util.function.Consumer-java.lang.Runnable-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>register</h4>
<pre>void&nbsp;register(java.util.function.Consumer&lt;<a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse">InboundSseEvent</a>&gt;&nbsp;onEvent,
java.util.function.Consumer&lt;java.lang.Throwable&gt;&nbsp;onError,
java.lang.Runnable&nbsp;onComplete)</pre>
<div class="block">Register <a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>InboundSseEvent</code></a> and <code>Throwable</code> consumers and onComplete callback.
<p>
Event consumer is invoked once per each received event, <code>Throwable</code> consumer is invoked invoked upon a
unrecoverable error encountered by a <a href="../../../../jakarta/ws/rs/sse/SseEventSource.html" title="interface in jakarta.ws.rs.sse"><code>SseEventSource</code></a>, onComplete callback is invoked after a successful
connection and when there are no further events to be received. Note that the onComplete callback will not be
invoked if the onError callback has been invoked.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>onEvent</code> - event consumer.</dd>
<dd><code>onError</code> - error consumer.</dd>
<dd><code>onComplete</code> - onComplete handler.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.IllegalArgumentException</code> - when the any of the provided parameters is <code>null</code>.</dd>
</dl>
</li>
</ul>
<a name="target-jakarta.ws.rs.client.WebTarget-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>target</h4>
<pre>static&nbsp;<a href="../../../../jakarta/ws/rs/sse/SseEventSource.Builder.html" title="class in jakarta.ws.rs.sse">SseEventSource.Builder</a>&nbsp;target(<a href="../../../../jakarta/ws/rs/client/WebTarget.html" title="interface in jakarta.ws.rs.client">WebTarget</a>&nbsp;endpoint)</pre>
<div class="block">Create a new <a href="../../../../jakarta/ws/rs/sse/SseEventSource.Builder.html" title="class in jakarta.ws.rs.sse"><code>event source builder</code></a> that provides convenient way how to configure and
fine-tune various aspects of a newly prepared event source instance.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>endpoint</code> - SSE streaming endpoint. Must not be <code>null</code>.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a builder of a new event source instance pointing at the specified SSE streaming endpoint.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.NullPointerException</code> - in case the supplied web target is <code>null</code>.</dd>
</dl>
</li>
</ul>
<a name="open--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>open</h4>
<pre>void&nbsp;open()</pre>
<div class="block">Open the connection to the supplied SSE underlying <a href="../../../../jakarta/ws/rs/client/WebTarget.html" title="interface in jakarta.ws.rs.client"><code>web target</code></a> and start processing incoming
<a href="../../../../jakarta/ws/rs/sse/InboundSseEvent.html" title="interface in jakarta.ws.rs.sse"><code>events</code></a>.</div>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.IllegalStateException</code> - in case the event source has already been opened earlier.</dd>
</dl>
</li>
</ul>
<a name="isOpen--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isOpen</h4>
<pre>boolean&nbsp;isOpen()</pre>
<div class="block">Check if this event source instance has already been <a href="../../../../jakarta/ws/rs/sse/SseEventSource.html#open--"><code>opened</code></a>.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if this event source is open, <code>false</code> otherwise.</dd>
</dl>
</li>
</ul>
<a name="close--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>close</h4>
<pre>default&nbsp;void&nbsp;close()</pre>
<div class="block">Close this event source.
<p>
The method will wait up to 5 seconds for the internal event processing tasks to complete.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code>close</code>&nbsp;in interface&nbsp;<code>java.lang.AutoCloseable</code></dd>
</dl>
</li>
</ul>
<a name="close-long-java.util.concurrent.TimeUnit-">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>close</h4>
<pre>boolean&nbsp;close(long&nbsp;timeout,
java.util.concurrent.TimeUnit&nbsp;unit)</pre>
<div class="block">Close this event source and wait for the internal event processing task to complete for up to the specified amount of
wait time.
<p>
The method blocks until the event processing task has completed execution after a shutdown request, or until the
timeout occurs, or the current thread is interrupted, whichever happens first.
<p>
In case the waiting for the event processing task has been interrupted, this method restores the
<code>interrupt</code> flag on the thread before returning <code>false</code>.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>timeout</code> - the maximum time to wait.</dd>
<dd><code>unit</code> - the time unit of the timeout argument.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if this executor terminated and <code>false</code> if the timeout elapsed before termination or the
termination was interrupted.</dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../jakarta/ws/rs/sse/SseEventSink.html" title="interface in jakarta.ws.rs.sse"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../jakarta/ws/rs/sse/SseEventSource.Builder.html" title="class in jakarta.ws.rs.sse"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?jakarta/ws/rs/sse/SseEventSource.html" target="_top">Frames</a></li>
<li><a href="SseEventSource.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li><a href="#nested.class.summary">Nested</a>&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</body>
</html>