| <!DOCTYPE HTML> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (17) on Thu Sep 15 14:13:16 CDT 2022 --> |
| <title>RemoteEndpoint (Eclipse Jetty API Doc - v11.0.12)</title> |
| <meta name="viewport" content="width=device-width, initial-scale=1"> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <meta name="dc.created" content="2022-09-15"> |
| <meta name="description" content="declaration: package: org.eclipse.jetty.websocket.api, interface: RemoteEndpoint"> |
| <meta name="generator" content="javadoc/ClassWriterImpl"> |
| <link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../../script-dir/jquery-ui.min.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../../jquery-ui.overrides.css" title="Style"> |
| <script type="text/javascript" src="../../../../../script.js"></script> |
| <script type="text/javascript" src="../../../../../script-dir/jquery-3.5.1.min.js"></script> |
| <script type="text/javascript" src="../../../../../script-dir/jquery-ui.min.js"></script> |
| </head> |
| <body class="class-declaration-page"> |
| <script type="text/javascript">var evenRowColor = "even-row-color"; |
| var oddRowColor = "odd-row-color"; |
| var tableTab = "table-tab"; |
| var activeTableTab = "active-table-tab"; |
| var pathtoroot = "../../../../../"; |
| loadScripts(document, 'script');</script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <div class="flex-box"> |
| <header role="banner" class="flex-header"> |
| <nav role="navigation"> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="top-nav" id="navbar-top"> |
| <div class="skip-nav"><a href="#skip-navbar-top" title="Skip navigation links">Skip navigation links</a></div> |
| <ul id="navbar-top-firstrow" class="nav-list" title="Navigation"> |
| <li><a href="../../../../../index.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="nav-bar-cell1-rev">Class</li> |
| <li><a href="class-use/RemoteEndpoint.html">Use</a></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#class">Help</a></li> |
| </ul> |
| </div> |
| <div class="sub-nav"> |
| <div> |
| <ul class="sub-nav-list"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method-summary">Method</a></li> |
| </ul> |
| <ul class="sub-nav-list"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method-detail">Method</a></li> |
| </ul> |
| </div> |
| <div class="nav-list-search"><label for="search-input">SEARCH:</label> |
| <input type="text" id="search-input" value="search" disabled="disabled"> |
| <input type="reset" id="reset-button" value="reset" disabled="disabled"> |
| </div> |
| </div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <span class="skip-nav" id="skip-navbar-top"></span></nav> |
| </header> |
| <div class="flex-content"> |
| <main role="main"> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="sub-title"><span class="package-label-in-type">Package</span> <a href="package-summary.html">org.eclipse.jetty.websocket.api</a></div> |
| <h1 title="Interface RemoteEndpoint" class="title">Interface RemoteEndpoint</h1> |
| </div> |
| <section class="class-description" id="class-description"> |
| <dl class="notes"> |
| <dt>All Known Implementing Classes:</dt> |
| <dd><code><a href="../common/JettyWebSocketRemoteEndpoint.html" title="class in org.eclipse.jetty.websocket.common">JettyWebSocketRemoteEndpoint</a></code></dd> |
| </dl> |
| <hr> |
| <div class="type-signature"><span class="modifiers">public interface </span><span class="element-name type-name-label">RemoteEndpoint</span></div> |
| </section> |
| <section class="summary"> |
| <ul class="summary-list"> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <li> |
| <section class="method-summary" id="method-summary"> |
| <h2>Method Summary</h2> |
| <div id="method-summary-table"> |
| <div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab3" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab3', 3)" class="table-tab">Abstract Methods</button></div> |
| <div id="method-summary-table.tabpanel" role="tabpanel"> |
| <div class="summary-table three-column-summary" aria-labelledby="method-summary-table-tab0"> |
| <div class="table-header col-first">Modifier and Type</div> |
| <div class="table-header col-second">Method</div> |
| <div class="table-header col-last">Description</div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#flush()" class="member-name-link">flush</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Flushes messages that may have been batched by the implementation.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="BatchMode.html" title="enum in org.eclipse.jetty.websocket.api">BatchMode</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getBatchMode()" class="member-name-link">getBatchMode</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>int</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getMaxOutgoingFrames()" class="member-name-link">getMaxOutgoingFrames</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Get the maximum number of data frames allowed to be waiting to be sent at any one time.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/net/SocketAddress.html" title="class or interface in java.net" class="external-link">SocketAddress</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getRemoteAddress()" class="member-name-link">getRemoteAddress</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Get the SocketAddress for the established connection.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendBytes(java.nio.ByteBuffer)" class="member-name-link">sendBytes</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> data)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Send a binary message, returning when all bytes of the message has been transmitted.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendBytes(java.nio.ByteBuffer,org.eclipse.jetty.websocket.api.WriteCallback)" class="member-name-link">sendBytes</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> data, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Initiates the asynchronous transmission of a binary message.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendPartialBytes(java.nio.ByteBuffer,boolean)" class="member-name-link">sendPartialBytes</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> fragment, |
| boolean isLast)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Send a binary message in pieces, blocking until all of the message has been transmitted.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendPartialBytes(java.nio.ByteBuffer,boolean,org.eclipse.jetty.websocket.api.WriteCallback)" class="member-name-link">sendPartialBytes</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> fragment, |
| boolean isLast, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Initiates the asynchronous transmission of a partial binary message.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendPartialString(java.lang.String,boolean)" class="member-name-link">sendPartialString</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> fragment, |
| boolean isLast)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Send a text message in pieces, blocking until all of the message has been transmitted.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendPartialString(java.lang.String,boolean,org.eclipse.jetty.websocket.api.WriteCallback)" class="member-name-link">sendPartialString</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> fragment, |
| boolean isLast, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Initiates the asynchronous transmission of a partial text message.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendPing(java.nio.ByteBuffer)" class="member-name-link">sendPing</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> applicationData)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Send a Ping message containing the given application data to the remote endpoint, blocking until all of the |
| message has been transmitted.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendPing(java.nio.ByteBuffer,org.eclipse.jetty.websocket.api.WriteCallback)" class="member-name-link">sendPing</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> applicationData, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Asynchronously send a Ping message containing the given application data to the remote endpoint.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendPong(java.nio.ByteBuffer)" class="member-name-link">sendPong</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> applicationData)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Allows the developer to send an unsolicited Pong message containing the given application data |
| in order to serve as a unidirectional heartbeat for the session, this will block until |
| all of the message has been transmitted.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendPong(java.nio.ByteBuffer,org.eclipse.jetty.websocket.api.WriteCallback)" class="member-name-link">sendPong</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> applicationData, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Allows the developer to asynchronously send an unsolicited Pong message containing the given application data |
| in order to serve as a unidirectional heartbeat for the session.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendString(java.lang.String)" class="member-name-link">sendString</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> text)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Send a text message, blocking until all bytes of the message has been transmitted.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sendString(java.lang.String,org.eclipse.jetty.websocket.api.WriteCallback)" class="member-name-link">sendString</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> text, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Initiates the asynchronous transmission of a text message.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#setBatchMode(org.eclipse.jetty.websocket.api.BatchMode)" class="member-name-link">setBatchMode</a><wbr>(<a href="BatchMode.html" title="enum in org.eclipse.jetty.websocket.api">BatchMode</a> mode)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Set the batch mode with which messages are sent.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#setMaxOutgoingFrames(int)" class="member-name-link">setMaxOutgoingFrames</a><wbr>(int maxOutgoingFrames)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> |
| <div class="block">Set the maximum number of data frames allowed to be waiting to be sent at any one time.</div> |
| </div> |
| </div> |
| </div> |
| </div> |
| </section> |
| </li> |
| </ul> |
| </section> |
| <section class="details"> |
| <ul class="details-list"> |
| <!-- ============ METHOD DETAIL ========== --> |
| <li> |
| <section class="method-details" id="method-detail"> |
| <h2>Method Details</h2> |
| <ul class="member-list"> |
| <li> |
| <section class="detail" id="sendBytes(java.nio.ByteBuffer)"> |
| <h3>sendBytes</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendBytes</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> data)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div> |
| <div class="block">Send a binary message, returning when all bytes of the message has been transmitted. |
| <p> |
| Note: this is a blocking call</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>data</code> - the message to be sent</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code> - if unable to send the bytes</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendBytes(java.nio.ByteBuffer,org.eclipse.jetty.websocket.api.WriteCallback)"> |
| <h3>sendBytes</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendBytes</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> data, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</span></div> |
| <div class="block">Initiates the asynchronous transmission of a binary message. This method returns before the message is transmitted. |
| Developers may provide a callback to be notified when the message has been transmitted or resulted in an error.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>data</code> - the data being sent</dd> |
| <dd><code>callback</code> - callback to notify of success or failure of the write operation</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendPartialBytes(java.nio.ByteBuffer,boolean)"> |
| <h3>sendPartialBytes</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendPartialBytes</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> fragment, |
| boolean isLast)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div> |
| <div class="block">Send a binary message in pieces, blocking until all of the message has been transmitted. |
| The runtime reads the message in order. Non-final pieces are |
| sent with isLast set to false. The final piece must be sent with isLast set to true.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>fragment</code> - the piece of the message being sent</dd> |
| <dd><code>isLast</code> - true if this is the last piece of the partial bytes</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code> - if unable to send the partial bytes</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendPartialBytes(java.nio.ByteBuffer,boolean,org.eclipse.jetty.websocket.api.WriteCallback)"> |
| <h3>sendPartialBytes</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendPartialBytes</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> fragment, |
| boolean isLast, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</span></div> |
| <div class="block">Initiates the asynchronous transmission of a partial binary message. This method returns before the message is |
| transmitted. |
| The runtime reads the message in order. Non-final pieces are sent with isLast |
| set to false. The final piece must be sent with isLast set to true. |
| Developers may provide a callback to be notified when the message has been transmitted or resulted in an error.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>fragment</code> - the data being sent</dd> |
| <dd><code>isLast</code> - true if this is the last piece of the partial bytes</dd> |
| <dd><code>callback</code> - callback to notify of success or failure of the write operation</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendString(java.lang.String)"> |
| <h3>sendString</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendString</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> text)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div> |
| <div class="block">Send a text message, blocking until all bytes of the message has been transmitted. |
| <p> |
| Note: this is a blocking call</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>text</code> - the message to be sent</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code> - if unable to send the text message</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendString(java.lang.String,org.eclipse.jetty.websocket.api.WriteCallback)"> |
| <h3>sendString</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendString</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> text, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</span></div> |
| <div class="block">Initiates the asynchronous transmission of a text message. This method may return before the message is |
| transmitted. Developers may provide a callback to |
| be notified when the message has been transmitted or resulted in an error.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>text</code> - the text being sent</dd> |
| <dd><code>callback</code> - callback to notify of success or failure of the write operation</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendPartialString(java.lang.String,boolean)"> |
| <h3>sendPartialString</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendPartialString</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> fragment, |
| boolean isLast)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div> |
| <div class="block">Send a text message in pieces, blocking until all of the message has been transmitted. The runtime reads the |
| message in order. Non-final pieces are sent |
| with isLast set to false. The final piece must be sent with isLast set to true.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>fragment</code> - the piece of the message being sent</dd> |
| <dd><code>isLast</code> - true if this is the last piece of the partial bytes</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code> - if unable to send the partial bytes</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendPartialString(java.lang.String,boolean,org.eclipse.jetty.websocket.api.WriteCallback)"> |
| <h3>sendPartialString</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendPartialString</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> fragment, |
| boolean isLast, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div> |
| <div class="block">Initiates the asynchronous transmission of a partial text message. |
| This method may return before the message is transmitted. |
| The runtime reads the message in order. Non-final pieces are sent with isLast |
| set to false. The final piece must be sent with isLast set to true. |
| Developers may provide a callback to be notified when the message has been transmitted or resulted in an error.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>fragment</code> - the text being sent</dd> |
| <dd><code>isLast</code> - true if this is the last piece of the partial bytes</dd> |
| <dd><code>callback</code> - callback to notify of success or failure of the write operation</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code> - this never throws IOException, it was a mistake to have this in the signature.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendPing(java.nio.ByteBuffer)"> |
| <h3>sendPing</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendPing</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> applicationData)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div> |
| <div class="block">Send a Ping message containing the given application data to the remote endpoint, blocking until all of the |
| message has been transmitted. |
| The corresponding Pong message may be picked up using the MessageHandler.Pong handler.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>applicationData</code> - the data to be carried in the ping request</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code> - if unable to send the ping</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendPing(java.nio.ByteBuffer,org.eclipse.jetty.websocket.api.WriteCallback)"> |
| <h3>sendPing</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendPing</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> applicationData, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</span></div> |
| <div class="block">Asynchronously send a Ping message containing the given application data to the remote endpoint. |
| The corresponding Pong message may be picked up using the MessageHandler.Pong handler.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>applicationData</code> - the data to be carried in the ping request</dd> |
| <dd><code>callback</code> - callback to notify of success or failure of the write operation</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendPong(java.nio.ByteBuffer)"> |
| <h3>sendPong</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendPong</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> applicationData)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div> |
| <div class="block">Allows the developer to send an unsolicited Pong message containing the given application data |
| in order to serve as a unidirectional heartbeat for the session, this will block until |
| all of the message has been transmitted.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>applicationData</code> - the application data to be carried in the pong response.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code> - if unable to send the pong</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="sendPong(java.nio.ByteBuffer,org.eclipse.jetty.websocket.api.WriteCallback)"> |
| <h3>sendPong</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">sendPong</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a> applicationData, |
| <a href="WriteCallback.html" title="interface in org.eclipse.jetty.websocket.api">WriteCallback</a> callback)</span></div> |
| <div class="block">Allows the developer to asynchronously send an unsolicited Pong message containing the given application data |
| in order to serve as a unidirectional heartbeat for the session.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>applicationData</code> - the application data to be carried in the pong response.</dd> |
| <dd><code>callback</code> - callback to notify of success or failure of the write operation</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getBatchMode()"> |
| <h3>getBatchMode</h3> |
| <div class="member-signature"><span class="return-type"><a href="BatchMode.html" title="enum in org.eclipse.jetty.websocket.api">BatchMode</a></span> <span class="element-name">getBatchMode</span>()</div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>the batch mode with which messages are sent.</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="see-list"> |
| <li><a href="#flush()"><code>flush()</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="setBatchMode(org.eclipse.jetty.websocket.api.BatchMode)"> |
| <h3>setBatchMode</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">setBatchMode</span><wbr><span class="parameters">(<a href="BatchMode.html" title="enum in org.eclipse.jetty.websocket.api">BatchMode</a> mode)</span></div> |
| <div class="block">Set the batch mode with which messages are sent.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>mode</code> - the batch mode to use</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="see-list"> |
| <li><a href="#flush()"><code>flush()</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMaxOutgoingFrames()"> |
| <h3>getMaxOutgoingFrames</h3> |
| <div class="member-signature"><span class="return-type">int</span> <span class="element-name">getMaxOutgoingFrames</span>()</div> |
| <div class="block">Get the maximum number of data frames allowed to be waiting to be sent at any one time. |
| The default value is -1, this indicates there is no limit on how many frames can be |
| queued to be sent by the implementation. If the limit is exceeded, subsequent frames |
| sent are failed with a <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/channels/WritePendingException.html" title="class or interface in java.nio.channels" class="external-link"><code>WritePendingException</code></a> but |
| the connection is not failed and will remain open.</div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>the max number of frames.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="setMaxOutgoingFrames(int)"> |
| <h3>setMaxOutgoingFrames</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">setMaxOutgoingFrames</span><wbr><span class="parameters">(int maxOutgoingFrames)</span></div> |
| <div class="block">Set the maximum number of data frames allowed to be waiting to be sent at any one time. |
| The default value is -1, this indicates there is no limit on how many frames can be |
| queued to be sent by the implementation. If the limit is exceeded, subsequent frames |
| sent are failed with a <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/channels/WritePendingException.html" title="class or interface in java.nio.channels" class="external-link"><code>WritePendingException</code></a> but |
| the connection is not failed and will remain open.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>maxOutgoingFrames</code> - the max number of frames.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getRemoteAddress()"> |
| <h3>getRemoteAddress</h3> |
| <div class="member-signature"><span class="return-type"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/net/SocketAddress.html" title="class or interface in java.net" class="external-link">SocketAddress</a></span> <span class="element-name">getRemoteAddress</span>()</div> |
| <div class="block">Get the SocketAddress for the established connection.</div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>the SocketAddress for the established connection.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="flush()"> |
| <h3>flush</h3> |
| <div class="member-signature"><span class="return-type">void</span> <span class="element-name">flush</span>() |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div> |
| <div class="block">Flushes messages that may have been batched by the implementation.</div> |
| <dl class="notes"> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code> - if the flush fails</dd> |
| </dl> |
| </section> |
| </li> |
| </ul> |
| </section> |
| </li> |
| </ul> |
| </section> |
| <!-- ========= END OF CLASS DATA ========= --> |
| </main> |
| <footer role="contentinfo"> |
| <hr> |
| <p class="legal-copy"><small>Copyright © 1995–2022 <a href="https://webtide.com">Webtide</a>. All rights reserved.</small></p> |
| </footer> |
| </div> |
| </div> |
| </body> |
| </html> |