| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (1.8.0_191) on Wed May 29 12:25:11 CEST 2019 --> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <title>IoSession (Apache MINA 2.1.3 API Documentation)</title> |
| <meta name="date" content="2019-05-29"> |
| <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="IoSession (Apache MINA 2.1.3 API Documentation)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var methods = {"i0":38,"i1":38,"i2":6,"i3":6,"i4":6,"i5":38,"i6":6,"i7":6,"i8":6,"i9":6,"i10":6,"i11":6,"i12":6,"i13":6,"i14":6,"i15":6,"i16":6,"i17":6,"i18":6,"i19":6,"i20":6,"i21":6,"i22":6,"i23":6,"i24":6,"i25":6,"i26":6,"i27":6,"i28":6,"i29":6,"i30":6,"i31":6,"i32":6,"i33":6,"i34":6,"i35":6,"i36":6,"i37":6,"i38":6,"i39":6,"i40":6,"i41":6,"i42":6,"i43":6,"i44":6,"i45":6,"i46":6,"i47":6,"i48":6,"i49":6,"i50":6,"i51":6,"i52":6,"i53":6,"i54":6,"i55":6,"i56":6,"i57":6,"i58":6,"i59":6,"i60":38,"i61":6,"i62":6,"i63":6,"i64":6,"i65":6,"i66":6,"i67":6,"i68":6,"i69":6,"i70":6}; |
| var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"],32:["t6","Deprecated 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="class-use/IoSession.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">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../../org/apache/mina/core/session/IoEventType.html" title="enum in org.apache.mina.core.session"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../../../org/apache/mina/core/session/IoSessionAttributeMap.html" title="interface in org.apache.mina.core.session"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../../index.html?org/apache/mina/core/session/IoSession.html" target="_top">Frames</a></li> |
| <li><a href="IoSession.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../../allclasses-noframe.html">All 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: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li>Constr | </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">org.apache.mina.core.session</div> |
| <h2 title="Interface IoSession" class="title">Interface IoSession</h2> |
| </div> |
| <div class="contentContainer"> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt>All Known Subinterfaces:</dt> |
| <dd><a href="../../../../../org/apache/mina/transport/serial/SerialSession.html" title="interface in org.apache.mina.transport.serial">SerialSession</a></dd> |
| </dl> |
| <dl> |
| <dt>All Known Implementing Classes:</dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/AbstractIoSession.html" title="class in org.apache.mina.core.session">AbstractIoSession</a>, <a href="../../../../../org/apache/mina/transport/socket/apr/AprSession.html" title="class in org.apache.mina.transport.socket.apr">AprSession</a>, <a href="../../../../../org/apache/mina/core/session/DummySession.html" title="class in org.apache.mina.core.session">DummySession</a>, <a href="../../../../../org/apache/mina/transport/socket/nio/NioSession.html" title="class in org.apache.mina.transport.socket.nio">NioSession</a>, <a href="../../../../../org/apache/mina/filter/codec/ProtocolCodecSession.html" title="class in org.apache.mina.filter.codec">ProtocolCodecSession</a></dd> |
| </dl> |
| <hr> |
| <br> |
| <pre>public interface <span class="typeNameLabel">IoSession</span></pre> |
| <div class="block"><p> |
| A handle which represents connection between two end-points regardless of |
| transport types. |
| </p> |
| <p> |
| <a href="../../../../../org/apache/mina/core/session/IoSession.html" title="interface in org.apache.mina.core.session"><code>IoSession</code></a> provides user-defined attributes. User-defined attributes |
| are application-specific data which are associated with a session. |
| It often contains objects that represents the state of a higher-level protocol |
| and becomes a way to exchange data between filters and handlers. |
| </p> |
| <h3>Adjusting Transport Type Specific Properties</h3> |
| <p> |
| You can simply downcast the session to an appropriate subclass. |
| </p> |
| <h3>Thread Safety</h3> |
| <p> |
| <a href="../../../../../org/apache/mina/core/session/IoSession.html" title="interface in org.apache.mina.core.session"><code>IoSession</code></a> is thread-safe. But please note that performing |
| more than one <a href="../../../../../org/apache/mina/core/session/IoSession.html#write-java.lang.Object-"><code>write(Object)</code></a> calls at the same time will |
| cause the <a href="../../../../../org/apache/mina/core/filterchain/IoFilter.html#filterWrite-org.apache.mina.core.filterchain.IoFilter.NextFilter-org.apache.mina.core.session.IoSession-org.apache.mina.core.write.WriteRequest-"><code>IoFilter.filterWrite(IoFilter.NextFilter,IoSession,WriteRequest)</code></a> |
| to be executed simultaneously, and therefore you have to make sure the |
| <a href="../../../../../org/apache/mina/core/filterchain/IoFilter.html" title="interface in org.apache.mina.core.filterchain"><code>IoFilter</code></a> implementations you're using are thread-safe, too. |
| </p> |
| <h3>Equality of Sessions</h3> |
| TODO : The getId() method is totally wrong. We can't base |
| a method which is designed to create a unique ID on the hashCode method. |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang"><code>Object.equals(Object)</code></a> and <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang"><code>Object.hashCode()</code></a> shall not be overriden |
| to the default behavior that is defined in <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang"><code>Object</code></a>.</div> |
| <dl> |
| <dt><span class="simpleTagLabel">Author:</span></dt> |
| <dd><a href="http://mina.apache.org">Apache MINA Project</a></dd> |
| </dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ========== 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"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd"> </span></span><span id="t6" class="tableTab"><span><a href="javascript:show(32);">Deprecated Methods</a></span><span class="tabEnd"> </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><a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#close--">close</a></span>()</code> |
| <div class="block"><span class="deprecatedLabel">Deprecated.</span> |
| <div class="block"><span class="deprecationComment">use <a href="../../../../../org/apache/mina/core/session/IoSession.html#closeNow--"><code>closeNow()</code></a></span></div> |
| </div> |
| </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#close-boolean-">close</a></span>(boolean immediately)</code> |
| <div class="block"><span class="deprecatedLabel">Deprecated.</span> |
| <div class="block"><span class="deprecationComment">Use either the <a href="../../../../../org/apache/mina/core/session/IoSession.html#closeNow--"><code>closeNow()</code></a> or the <a href="../../../../../org/apache/mina/core/session/IoSession.html#closeOnFlush--"><code>closeOnFlush()</code></a> methods</span></div> |
| </div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#closeNow--">closeNow</a></span>()</code> |
| <div class="block">Closes this session immediately.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#closeOnFlush--">closeOnFlush</a></span>()</code> |
| <div class="block">Closes this session after all queued write requests are flushed.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#containsAttribute-java.lang.Object-">containsAttribute</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</code> </td> |
| </tr> |
| <tr id="i5" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getAttachment--">getAttachment</a></span>()</code> |
| <div class="block"><span class="deprecatedLabel">Deprecated.</span> |
| <div class="block"><span class="deprecationComment">Use <a href="../../../../../org/apache/mina/core/session/IoSession.html#getAttribute-java.lang.Object-"><code>getAttribute(Object)</code></a> instead.</span></div> |
| </div> |
| </td> |
| </tr> |
| <tr id="i6" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getAttribute-java.lang.Object-">getAttribute</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</code> |
| <div class="block">Returns the value of the user-defined attribute of this session.</div> |
| </td> |
| </tr> |
| <tr id="i7" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getAttribute-java.lang.Object-java.lang.Object-">getAttribute</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> defaultValue)</code> |
| <div class="block">Returns the value of user defined attribute associated with the |
| specified key.</div> |
| </td> |
| </tr> |
| <tr id="i8" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</a><<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getAttributeKeys--">getAttributeKeys</a></span>()</code> </td> |
| </tr> |
| <tr id="i9" class="rowColor"> |
| <td class="colFirst"><code>int</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getBothIdleCount--">getBothIdleCount</a></span>()</code> </td> |
| </tr> |
| <tr id="i10" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getCloseFuture--">getCloseFuture</a></span>()</code> </td> |
| </tr> |
| <tr id="i11" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/session/IoSessionConfig.html" title="interface in org.apache.mina.core.session">IoSessionConfig</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getConfig--">getConfig</a></span>()</code> </td> |
| </tr> |
| <tr id="i12" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getCreationTime--">getCreationTime</a></span>()</code> </td> |
| </tr> |
| <tr id="i13" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getCurrentWriteMessage--">getCurrentWriteMessage</a></span>()</code> |
| <div class="block">Returns the message which is being written by <a href="../../../../../org/apache/mina/core/service/IoService.html" title="interface in org.apache.mina.core.service"><code>IoService</code></a>.</div> |
| </td> |
| </tr> |
| <tr id="i14" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/write/WriteRequest.html" title="interface in org.apache.mina.core.write">WriteRequest</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getCurrentWriteRequest--">getCurrentWriteRequest</a></span>()</code> |
| <div class="block">Returns the <a href="../../../../../org/apache/mina/core/write/WriteRequest.html" title="interface in org.apache.mina.core.write"><code>WriteRequest</code></a> which is being processed by |
| <a href="../../../../../org/apache/mina/core/service/IoService.html" title="interface in org.apache.mina.core.service"><code>IoService</code></a>.</div> |
| </td> |
| </tr> |
| <tr id="i15" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/filterchain/IoFilterChain.html" title="interface in org.apache.mina.core.filterchain">IoFilterChain</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getFilterChain--">getFilterChain</a></span>()</code> </td> |
| </tr> |
| <tr id="i16" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/service/IoHandler.html" title="interface in org.apache.mina.core.service">IoHandler</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getHandler--">getHandler</a></span>()</code> </td> |
| </tr> |
| <tr id="i17" class="rowColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getId--">getId</a></span>()</code> </td> |
| </tr> |
| <tr id="i18" class="altColor"> |
| <td class="colFirst"><code>int</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getIdleCount-org.apache.mina.core.session.IdleStatus-">getIdleCount</a></span>(<a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session">IdleStatus</a> status)</code> </td> |
| </tr> |
| <tr id="i19" class="rowColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastBothIdleTime--">getLastBothIdleTime</a></span>()</code> </td> |
| </tr> |
| <tr id="i20" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastIdleTime-org.apache.mina.core.session.IdleStatus-">getLastIdleTime</a></span>(<a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session">IdleStatus</a> status)</code> </td> |
| </tr> |
| <tr id="i21" class="rowColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastIoTime--">getLastIoTime</a></span>()</code> </td> |
| </tr> |
| <tr id="i22" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastReaderIdleTime--">getLastReaderIdleTime</a></span>()</code> </td> |
| </tr> |
| <tr id="i23" class="rowColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastReadTime--">getLastReadTime</a></span>()</code> </td> |
| </tr> |
| <tr id="i24" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastWriterIdleTime--">getLastWriterIdleTime</a></span>()</code> </td> |
| </tr> |
| <tr id="i25" class="rowColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastWriteTime--">getLastWriteTime</a></span>()</code> </td> |
| </tr> |
| <tr id="i26" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net">SocketAddress</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLocalAddress--">getLocalAddress</a></span>()</code> </td> |
| </tr> |
| <tr id="i27" class="rowColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getReadBytes--">getReadBytes</a></span>()</code> </td> |
| </tr> |
| <tr id="i28" class="altColor"> |
| <td class="colFirst"><code>double</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getReadBytesThroughput--">getReadBytesThroughput</a></span>()</code> </td> |
| </tr> |
| <tr id="i29" class="rowColor"> |
| <td class="colFirst"><code>int</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getReaderIdleCount--">getReaderIdleCount</a></span>()</code> </td> |
| </tr> |
| <tr id="i30" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getReadMessages--">getReadMessages</a></span>()</code> </td> |
| </tr> |
| <tr id="i31" class="rowColor"> |
| <td class="colFirst"><code>double</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getReadMessagesThroughput--">getReadMessagesThroughput</a></span>()</code> </td> |
| </tr> |
| <tr id="i32" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net">SocketAddress</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getRemoteAddress--">getRemoteAddress</a></span>()</code> </td> |
| </tr> |
| <tr id="i33" class="rowColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getScheduledWriteBytes--">getScheduledWriteBytes</a></span>()</code> </td> |
| </tr> |
| <tr id="i34" class="altColor"> |
| <td class="colFirst"><code>int</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getScheduledWriteMessages--">getScheduledWriteMessages</a></span>()</code> </td> |
| </tr> |
| <tr id="i35" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/service/IoService.html" title="interface in org.apache.mina.core.service">IoService</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getService--">getService</a></span>()</code> </td> |
| </tr> |
| <tr id="i36" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net">SocketAddress</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getServiceAddress--">getServiceAddress</a></span>()</code> </td> |
| </tr> |
| <tr id="i37" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/service/TransportMetadata.html" title="interface in org.apache.mina.core.service">TransportMetadata</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getTransportMetadata--">getTransportMetadata</a></span>()</code> </td> |
| </tr> |
| <tr id="i38" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/write/WriteRequestQueue.html" title="interface in org.apache.mina.core.write">WriteRequestQueue</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getWriteRequestQueue--">getWriteRequestQueue</a></span>()</code> |
| <div class="block">Get the queue that contains the message waiting for being written.</div> |
| </td> |
| </tr> |
| <tr id="i39" class="rowColor"> |
| <td class="colFirst"><code>int</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getWriterIdleCount--">getWriterIdleCount</a></span>()</code> </td> |
| </tr> |
| <tr id="i40" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getWrittenBytes--">getWrittenBytes</a></span>()</code> </td> |
| </tr> |
| <tr id="i41" class="rowColor"> |
| <td class="colFirst"><code>double</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getWrittenBytesThroughput--">getWrittenBytesThroughput</a></span>()</code> </td> |
| </tr> |
| <tr id="i42" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getWrittenMessages--">getWrittenMessages</a></span>()</code> </td> |
| </tr> |
| <tr id="i43" class="rowColor"> |
| <td class="colFirst"><code>double</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#getWrittenMessagesThroughput--">getWrittenMessagesThroughput</a></span>()</code> </td> |
| </tr> |
| <tr id="i44" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isActive--">isActive</a></span>()</code> </td> |
| </tr> |
| <tr id="i45" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isBothIdle--">isBothIdle</a></span>()</code> </td> |
| </tr> |
| <tr id="i46" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isClosing--">isClosing</a></span>()</code> </td> |
| </tr> |
| <tr id="i47" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isConnected--">isConnected</a></span>()</code> </td> |
| </tr> |
| <tr id="i48" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isIdle-org.apache.mina.core.session.IdleStatus-">isIdle</a></span>(<a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session">IdleStatus</a> status)</code> </td> |
| </tr> |
| <tr id="i49" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isReaderIdle--">isReaderIdle</a></span>()</code> </td> |
| </tr> |
| <tr id="i50" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isReadSuspended--">isReadSuspended</a></span>()</code> |
| <div class="block">Is read operation is suspended for this session.</div> |
| </td> |
| </tr> |
| <tr id="i51" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isSecured--">isSecured</a></span>()</code> </td> |
| </tr> |
| <tr id="i52" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isWriterIdle--">isWriterIdle</a></span>()</code> </td> |
| </tr> |
| <tr id="i53" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#isWriteSuspended--">isWriteSuspended</a></span>()</code> |
| <div class="block">Is write operation is suspended for this session.</div> |
| </td> |
| </tr> |
| <tr id="i54" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/future/ReadFuture.html" title="interface in org.apache.mina.core.future">ReadFuture</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#read--">read</a></span>()</code> |
| <div class="block">TODO This javadoc is wrong.</div> |
| </td> |
| </tr> |
| <tr id="i55" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#removeAttribute-java.lang.Object-">removeAttribute</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</code> |
| <div class="block">Removes a user-defined attribute with the specified key.</div> |
| </td> |
| </tr> |
| <tr id="i56" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#removeAttribute-java.lang.Object-java.lang.Object-">removeAttribute</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value)</code> |
| <div class="block">Removes a user defined attribute with the specified key if the current |
| attribute value is equal to the specified value.</div> |
| </td> |
| </tr> |
| <tr id="i57" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#replaceAttribute-java.lang.Object-java.lang.Object-java.lang.Object-">replaceAttribute</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> oldValue, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> newValue)</code> |
| <div class="block">Replaces a user defined attribute with the specified key if the |
| value of the attribute is equals to the specified old value.</div> |
| </td> |
| </tr> |
| <tr id="i58" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#resumeRead--">resumeRead</a></span>()</code> |
| <div class="block">Resumes read operations for this session.</div> |
| </td> |
| </tr> |
| <tr id="i59" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#resumeWrite--">resumeWrite</a></span>()</code> |
| <div class="block">Resumes write operations for this session.</div> |
| </td> |
| </tr> |
| <tr id="i60" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#setAttachment-java.lang.Object-">setAttachment</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> attachment)</code> |
| <div class="block"><span class="deprecatedLabel">Deprecated.</span> |
| <div class="block"><span class="deprecationComment">Use <a href="../../../../../org/apache/mina/core/session/IoSession.html#setAttribute-java.lang.Object-java.lang.Object-"><code>setAttribute(Object, Object)</code></a> instead.</span></div> |
| </div> |
| </td> |
| </tr> |
| <tr id="i61" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#setAttribute-java.lang.Object-">setAttribute</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</code> |
| <div class="block">Sets a user defined attribute without a value.</div> |
| </td> |
| </tr> |
| <tr id="i62" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#setAttribute-java.lang.Object-java.lang.Object-">setAttribute</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value)</code> |
| <div class="block">Sets a user-defined attribute.</div> |
| </td> |
| </tr> |
| <tr id="i63" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#setAttributeIfAbsent-java.lang.Object-">setAttributeIfAbsent</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</code> |
| <div class="block">Sets a user defined attribute without a value if the attribute with |
| the specified key is not set yet.</div> |
| </td> |
| </tr> |
| <tr id="i64" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#setAttributeIfAbsent-java.lang.Object-java.lang.Object-">setAttributeIfAbsent</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value)</code> |
| <div class="block">Sets a user defined attribute if the attribute with the specified key |
| is not set yet.</div> |
| </td> |
| </tr> |
| <tr id="i65" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#setCurrentWriteRequest-org.apache.mina.core.write.WriteRequest-">setCurrentWriteRequest</a></span>(<a href="../../../../../org/apache/mina/core/write/WriteRequest.html" title="interface in org.apache.mina.core.write">WriteRequest</a> currentWriteRequest)</code> |
| <div class="block">Associate the current write request with the session</div> |
| </td> |
| </tr> |
| <tr id="i66" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#suspendRead--">suspendRead</a></span>()</code> |
| <div class="block">Suspends read operations for this session.</div> |
| </td> |
| </tr> |
| <tr id="i67" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#suspendWrite--">suspendWrite</a></span>()</code> |
| <div class="block">Suspends write operations for this session.</div> |
| </td> |
| </tr> |
| <tr id="i68" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#updateThroughput-long-boolean-">updateThroughput</a></span>(long currentTime, |
| boolean force)</code> |
| <div class="block">Update all statistical properties related with throughput assuming |
| the specified time is the current time.</div> |
| </td> |
| </tr> |
| <tr id="i69" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/future/WriteFuture.html" title="interface in org.apache.mina.core.future">WriteFuture</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#write-java.lang.Object-">write</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> message)</code> |
| <div class="block">Writes the specified <code>message</code> to remote peer.</div> |
| </td> |
| </tr> |
| <tr id="i70" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../../org/apache/mina/core/future/WriteFuture.html" title="interface in org.apache.mina.core.future">WriteFuture</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/mina/core/session/IoSession.html#write-java.lang.Object-java.net.SocketAddress-">write</a></span>(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> message, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net">SocketAddress</a> destination)</code> |
| <div class="block">(Optional) Writes the specified <tt>message</tt> to the specified <tt>destination</tt>.</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="getId--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getId</h4> |
| <pre>long getId()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a unique identifier for this session. Every session has its own |
| ID which is different from each other. |
| |
| TODO : The way it's implemented does not guarantee that the contract is |
| respected. It uses the HashCode() method which don't guarantee the key |
| unicity.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getService--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getService</h4> |
| <pre><a href="../../../../../org/apache/mina/core/service/IoService.html" title="interface in org.apache.mina.core.service">IoService</a> getService()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the <a href="../../../../../org/apache/mina/core/service/IoService.html" title="interface in org.apache.mina.core.service"><code>IoService</code></a> which provides I/O service to this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getHandler--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getHandler</h4> |
| <pre><a href="../../../../../org/apache/mina/core/service/IoHandler.html" title="interface in org.apache.mina.core.service">IoHandler</a> getHandler()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the <a href="../../../../../org/apache/mina/core/service/IoHandler.html" title="interface in org.apache.mina.core.service"><code>IoHandler</code></a> which handles this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getConfig--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getConfig</h4> |
| <pre><a href="../../../../../org/apache/mina/core/session/IoSessionConfig.html" title="interface in org.apache.mina.core.session">IoSessionConfig</a> getConfig()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the configuration of this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getFilterChain--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getFilterChain</h4> |
| <pre><a href="../../../../../org/apache/mina/core/filterchain/IoFilterChain.html" title="interface in org.apache.mina.core.filterchain">IoFilterChain</a> getFilterChain()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the filter chain that only affects this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getWriteRequestQueue--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getWriteRequestQueue</h4> |
| <pre><a href="../../../../../org/apache/mina/core/write/WriteRequestQueue.html" title="interface in org.apache.mina.core.write">WriteRequestQueue</a> getWriteRequestQueue()</pre> |
| <div class="block">Get the queue that contains the message waiting for being written. |
| As the reader might not be ready, it's frequent that the messages |
| aren't written completely, or that some older messages are waiting |
| to be written when a new message arrives. This queue is used to manage |
| the backlog of messages.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The queue containing the pending messages.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getTransportMetadata--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getTransportMetadata</h4> |
| <pre><a href="../../../../../org/apache/mina/core/service/TransportMetadata.html" title="interface in org.apache.mina.core.service">TransportMetadata</a> getTransportMetadata()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the <a href="../../../../../org/apache/mina/core/service/TransportMetadata.html" title="interface in org.apache.mina.core.service"><code>TransportMetadata</code></a> that this session runs on.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="read--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>read</h4> |
| <pre><a href="../../../../../org/apache/mina/core/future/ReadFuture.html" title="interface in org.apache.mina.core.future">ReadFuture</a> read()</pre> |
| <div class="block">TODO This javadoc is wrong. The return tag should be short.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a <a href="../../../../../org/apache/mina/core/future/ReadFuture.html" title="interface in org.apache.mina.core.future"><code>ReadFuture</code></a> which is notified when a new message is |
| received, the connection is closed or an exception is caught. This |
| operation is especially useful when you implement a client application. |
| TODO : Describe here how we enable this feature. |
| However, please note that this operation is disabled by default and |
| throw <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang"><code>IllegalStateException</code></a> because all received events must be |
| queued somewhere to support this operation, possibly leading to memory |
| leak. This means you have to keep calling <a href="../../../../../org/apache/mina/core/session/IoSession.html#read--"><code>read()</code></a> once you |
| enabled this operation. To enable this operation, please call |
| <a href="../../../../../org/apache/mina/core/session/IoSessionConfig.html#setUseReadOperation-boolean-"><code>IoSessionConfig.setUseReadOperation(boolean)</code></a> with <tt>true</tt>.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</a></code> - if |
| <a href="../../../../../org/apache/mina/core/session/IoSessionConfig.html#setUseReadOperation-boolean-"><code>useReadOperation</code></a> |
| option has not been enabled.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="write-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>write</h4> |
| <pre><a href="../../../../../org/apache/mina/core/future/WriteFuture.html" title="interface in org.apache.mina.core.future">WriteFuture</a> write(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> message)</pre> |
| <div class="block">Writes the specified <code>message</code> to remote peer. This |
| operation is asynchronous; <a href="../../../../../org/apache/mina/core/service/IoHandler.html#messageSent-org.apache.mina.core.session.IoSession-java.lang.Object-"><code>IoHandler.messageSent(IoSession,Object)</code></a> |
| will be invoked when the message is actually sent to remote peer. |
| You can also wait for the returned <a href="../../../../../org/apache/mina/core/future/WriteFuture.html" title="interface in org.apache.mina.core.future"><code>WriteFuture</code></a> if you want |
| to wait for the message actually written.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>message</code> - The message to write</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The associated WriteFuture</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="write-java.lang.Object-java.net.SocketAddress-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>write</h4> |
| <pre><a href="../../../../../org/apache/mina/core/future/WriteFuture.html" title="interface in org.apache.mina.core.future">WriteFuture</a> write(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> message, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net">SocketAddress</a> destination)</pre> |
| <div class="block">(Optional) Writes the specified <tt>message</tt> to the specified <tt>destination</tt>. |
| This operation is asynchronous; <a href="../../../../../org/apache/mina/core/service/IoHandler.html#messageSent-org.apache.mina.core.session.IoSession-java.lang.Object-"><code>IoHandler.messageSent(IoSession, Object)</code></a> |
| will be invoked when the message is actually sent to remote peer. You can |
| also wait for the returned <a href="../../../../../org/apache/mina/core/future/WriteFuture.html" title="interface in org.apache.mina.core.future"><code>WriteFuture</code></a> if you want to wait for |
| the message actually written. |
| <p> |
| When you implement a client that receives a broadcast message from a server |
| such as DHCP server, the client might need to send a response message for the |
| broadcast message the server sent. Because the remote address of the session |
| is not the address of the server in case of broadcasting, there should be a |
| way to specify the destination when you write the response message. |
| This interface provides <a href="../../../../../org/apache/mina/core/session/IoSession.html#write-java.lang.Object-java.net.SocketAddress-"><code>write(Object, SocketAddress)</code></a> method so you |
| can specify the destination.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>message</code> - The message to write</dd> |
| <dd><code>destination</code> - <tt>null</tt> if you want the message sent to the |
| default remote address</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The associated WriteFuture</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="close-boolean-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>close</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> |
| <a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a> close(boolean immediately)</pre> |
| <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">Use either the <a href="../../../../../org/apache/mina/core/session/IoSession.html#closeNow--"><code>closeNow()</code></a> or the <a href="../../../../../org/apache/mina/core/session/IoSession.html#closeOnFlush--"><code>closeOnFlush()</code></a> methods</span></div> |
| <div class="block">Closes this session immediately or after all queued write requests |
| are flushed. This operation is asynchronous. Wait for the returned |
| <a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future"><code>CloseFuture</code></a> if you want to wait for the session actually closed.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>immediately</code> - <code>true</code> to close this session immediately |
| . The pending write requests |
| will simply be discarded. |
| <code>false</code> to close this session after all queued |
| write requests are flushed.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The associated CloseFuture</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="closeNow--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>closeNow</h4> |
| <pre><a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a> closeNow()</pre> |
| <div class="block">Closes this session immediately. This operation is asynchronous, it |
| returns a <a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future"><code>CloseFuture</code></a>.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The <a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future"><code>CloseFuture</code></a> that can be use to wait for the completion of this operation</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="closeOnFlush--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>closeOnFlush</h4> |
| <pre><a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a> closeOnFlush()</pre> |
| <div class="block">Closes this session after all queued write requests are flushed. This operation |
| is asynchronous. Wait for the returned <a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future"><code>CloseFuture</code></a> if you want to wait |
| for the session actually closed.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The associated CloseFuture</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="close--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>close</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> |
| <a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a> close()</pre> |
| <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">use <a href="../../../../../org/apache/mina/core/session/IoSession.html#closeNow--"><code>closeNow()</code></a></span></div> |
| <div class="block">Closes this session after all queued write requests |
| are flushed. This operation is asynchronous. Wait for the returned |
| <a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future"><code>CloseFuture</code></a> if you want to wait for the session actually closed.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The associated CloseFuture</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getAttachment--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getAttachment</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> getAttachment()</pre> |
| <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">Use <a href="../../../../../org/apache/mina/core/session/IoSession.html#getAttribute-java.lang.Object-"><code>getAttribute(Object)</code></a> instead.</span></div> |
| <div class="block">Returns an attachment of this session. |
| This method is identical with <tt>getAttribute( "" )</tt>.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The attachment</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setAttachment-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setAttachment</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> setAttachment(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> attachment)</pre> |
| <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">Use <a href="../../../../../org/apache/mina/core/session/IoSession.html#setAttribute-java.lang.Object-java.lang.Object-"><code>setAttribute(Object, Object)</code></a> instead.</span></div> |
| <div class="block">Sets an attachment of this session. |
| This method is identical with <tt>setAttribute( "", attachment )</tt>.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>attachment</code> - The attachment</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>Old attachment. <tt>null</tt> if it is new.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getAttribute-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getAttribute</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> getAttribute(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</pre> |
| <div class="block">Returns the value of the user-defined attribute of this session.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - the key of the attribute</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>null</tt> if there is no attribute with the specified key</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getAttribute-java.lang.Object-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getAttribute</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> getAttribute(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> defaultValue)</pre> |
| <div class="block">Returns the value of user defined attribute associated with the |
| specified key. If there's no such attribute, the specified default |
| value is associated with the specified key, and the default value is |
| returned. This method is same with the following code except that the |
| operation is performed atomically. |
| <pre> |
| if (containsAttribute(key)) { |
| return getAttribute(key); |
| } else { |
| setAttribute(key, defaultValue); |
| return defaultValue; |
| } |
| </pre></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - the key of the attribute we want to retreive</dd> |
| <dd><code>defaultValue</code> - the default value of the attribute</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The retrieved attribute or <tt>null</tt> if not found</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setAttribute-java.lang.Object-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setAttribute</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> setAttribute(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value)</pre> |
| <div class="block">Sets a user-defined attribute.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - the key of the attribute</dd> |
| <dd><code>value</code> - the value of the attribute</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The old value of the attribute. <tt>null</tt> if it is new.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setAttribute-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setAttribute</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> setAttribute(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</pre> |
| <div class="block">Sets a user defined attribute without a value. This is useful when |
| you just want to put a 'mark' attribute. Its value is set to |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true#TRUE" title="class or interface in java.lang"><code>Boolean.TRUE</code></a>.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - the key of the attribute</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The old value of the attribute. <tt>null</tt> if it is new.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setAttributeIfAbsent-java.lang.Object-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setAttributeIfAbsent</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> setAttributeIfAbsent(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value)</pre> |
| <div class="block">Sets a user defined attribute if the attribute with the specified key |
| is not set yet. This method is same with the following code except |
| that the operation is performed atomically. |
| <pre> |
| if (containsAttribute(key)) { |
| return getAttribute(key); |
| } else { |
| return setAttribute(key, value); |
| } |
| </pre></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - The key of the attribute we want to set</dd> |
| <dd><code>value</code> - The value we want to set</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The old value of the attribute. <tt>null</tt> if not found.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setAttributeIfAbsent-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setAttributeIfAbsent</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> setAttributeIfAbsent(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</pre> |
| <div class="block">Sets a user defined attribute without a value if the attribute with |
| the specified key is not set yet. This is useful when you just want to |
| put a 'mark' attribute. Its value is set to <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true#TRUE" title="class or interface in java.lang"><code>Boolean.TRUE</code></a>. |
| This method is same with the following code except that the operation |
| is performed atomically. |
| <pre> |
| if (containsAttribute(key)) { |
| return getAttribute(key); // might not always be Boolean.TRUE. |
| } else { |
| return setAttribute(key); |
| } |
| </pre></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - The key of the attribute we want to set</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The old value of the attribute. <tt>null</tt> if not found.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="removeAttribute-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>removeAttribute</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> removeAttribute(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</pre> |
| <div class="block">Removes a user-defined attribute with the specified key.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - The key of the attribute we want to remove</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>The old value of the attribute. <tt>null</tt> if not found.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="removeAttribute-java.lang.Object-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>removeAttribute</h4> |
| <pre>boolean removeAttribute(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value)</pre> |
| <div class="block">Removes a user defined attribute with the specified key if the current |
| attribute value is equal to the specified value. This method is same |
| with the following code except that the operation is performed |
| atomically. |
| <pre> |
| if (containsAttribute(key) && getAttribute(key).equals(value)) { |
| removeAttribute(key); |
| return true; |
| } else { |
| return false; |
| } |
| </pre></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - The key we want to remove</dd> |
| <dd><code>value</code> - The value we want to remove</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if the removal was successful</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="replaceAttribute-java.lang.Object-java.lang.Object-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>replaceAttribute</h4> |
| <pre>boolean replaceAttribute(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> oldValue, |
| <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> newValue)</pre> |
| <div class="block">Replaces a user defined attribute with the specified key if the |
| value of the attribute is equals to the specified old value. |
| This method is same with the following code except that the operation |
| is performed atomically. |
| <pre> |
| if (containsAttribute(key) && getAttribute(key).equals(oldValue)) { |
| setAttribute(key, newValue); |
| return true; |
| } else { |
| return false; |
| } |
| </pre></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - The key we want to replace</dd> |
| <dd><code>oldValue</code> - The previous value</dd> |
| <dd><code>newValue</code> - The new value</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if the replacement was successful</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="containsAttribute-java.lang.Object-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>containsAttribute</h4> |
| <pre>boolean containsAttribute(<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> key)</pre> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>key</code> - The key of the attribute we are looking for in the session</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if this session contains the attribute with |
| the specified <tt>key</tt>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getAttributeKeys--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getAttributeKeys</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</a><<a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>> getAttributeKeys()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the set of keys of all user-defined attributes.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isConnected--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isConnected</h4> |
| <pre>boolean isConnected()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if this session is connected with remote peer.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isActive--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isActive</h4> |
| <pre>boolean isActive()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if this session is active.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isClosing--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isClosing</h4> |
| <pre>boolean isClosing()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if and only if this session is being closed |
| (but not disconnected yet) or is closed.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isSecured--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isSecured</h4> |
| <pre>boolean isSecured()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if the session has started and initialized a SslEngine, |
| <tt>false</tt> if the session is not yet secured (the handshake is not completed) |
| or if SSL is not set for this session, or if SSL is not even an option.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getCloseFuture--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCloseFuture</h4> |
| <pre><a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future">CloseFuture</a> getCloseFuture()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the <a href="../../../../../org/apache/mina/core/future/CloseFuture.html" title="interface in org.apache.mina.core.future"><code>CloseFuture</code></a> of this session. This method returns |
| the same instance whenever user calls it.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getRemoteAddress--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getRemoteAddress</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net">SocketAddress</a> getRemoteAddress()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the socket address of remote peer.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getLocalAddress--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getLocalAddress</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net">SocketAddress</a> getLocalAddress()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the socket address of local machine which is associated with this |
| session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getServiceAddress--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getServiceAddress</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net">SocketAddress</a> getServiceAddress()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the socket address of the <a href="../../../../../org/apache/mina/core/service/IoService.html" title="interface in org.apache.mina.core.service"><code>IoService</code></a> listens to to manage |
| this session. If this session is managed by <a href="../../../../../org/apache/mina/core/service/IoAcceptor.html" title="interface in org.apache.mina.core.service"><code>IoAcceptor</code></a>, it |
| returns the <a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/net/SocketAddress.html?is-external=true" title="class or interface in java.net"><code>SocketAddress</code></a> which is specified as a parameter of |
| <a href="../../../../../org/apache/mina/core/service/IoAcceptor.html#bind--"><code>IoAcceptor.bind()</code></a>. If this session is managed by |
| <a href="../../../../../org/apache/mina/core/service/IoConnector.html" title="interface in org.apache.mina.core.service"><code>IoConnector</code></a>, this method returns the same address with |
| that of <a href="../../../../../org/apache/mina/core/session/IoSession.html#getRemoteAddress--"><code>getRemoteAddress()</code></a>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setCurrentWriteRequest-org.apache.mina.core.write.WriteRequest-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setCurrentWriteRequest</h4> |
| <pre>void setCurrentWriteRequest(<a href="../../../../../org/apache/mina/core/write/WriteRequest.html" title="interface in org.apache.mina.core.write">WriteRequest</a> currentWriteRequest)</pre> |
| <div class="block">Associate the current write request with the session</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>currentWriteRequest</code> - the current write request to associate</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="suspendRead--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>suspendRead</h4> |
| <pre>void suspendRead()</pre> |
| <div class="block">Suspends read operations for this session.</div> |
| </li> |
| </ul> |
| <a name="suspendWrite--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>suspendWrite</h4> |
| <pre>void suspendWrite()</pre> |
| <div class="block">Suspends write operations for this session.</div> |
| </li> |
| </ul> |
| <a name="resumeRead--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>resumeRead</h4> |
| <pre>void resumeRead()</pre> |
| <div class="block">Resumes read operations for this session.</div> |
| </li> |
| </ul> |
| <a name="resumeWrite--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>resumeWrite</h4> |
| <pre>void resumeWrite()</pre> |
| <div class="block">Resumes write operations for this session.</div> |
| </li> |
| </ul> |
| <a name="isReadSuspended--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isReadSuspended</h4> |
| <pre>boolean isReadSuspended()</pre> |
| <div class="block">Is read operation is suspended for this session.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if suspended</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isWriteSuspended--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isWriteSuspended</h4> |
| <pre>boolean isWriteSuspended()</pre> |
| <div class="block">Is write operation is suspended for this session.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if suspended</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="updateThroughput-long-boolean-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>updateThroughput</h4> |
| <pre>void updateThroughput(long currentTime, |
| boolean force)</pre> |
| <div class="block">Update all statistical properties related with throughput assuming |
| the specified time is the current time. By default this method returns |
| silently without updating the throughput properties if they were |
| calculated already within last |
| <a href="../../../../../org/apache/mina/core/session/IoSessionConfig.html#getThroughputCalculationInterval--"><code>calculation interval</code></a>. |
| If, however, <tt>force</tt> is specified as <tt>true</tt>, this method |
| updates the throughput properties immediately.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>currentTime</code> - the current time in milliseconds</dd> |
| <dd><code>force</code> - Force the update if <tt>true</tt></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getReadBytes--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getReadBytes</h4> |
| <pre>long getReadBytes()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the total number of bytes which were read from this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getWrittenBytes--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getWrittenBytes</h4> |
| <pre>long getWrittenBytes()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the total number of bytes which were written to this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getReadMessages--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getReadMessages</h4> |
| <pre>long getReadMessages()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the total number of messages which were read and decoded from this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getWrittenMessages--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getWrittenMessages</h4> |
| <pre>long getWrittenMessages()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the total number of messages which were written and encoded by this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getReadBytesThroughput--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getReadBytesThroughput</h4> |
| <pre>double getReadBytesThroughput()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of read bytes per second.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getWrittenBytesThroughput--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getWrittenBytesThroughput</h4> |
| <pre>double getWrittenBytesThroughput()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of written bytes per second.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getReadMessagesThroughput--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getReadMessagesThroughput</h4> |
| <pre>double getReadMessagesThroughput()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of read messages per second.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getWrittenMessagesThroughput--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getWrittenMessagesThroughput</h4> |
| <pre>double getWrittenMessagesThroughput()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of written messages per second.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getScheduledWriteMessages--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getScheduledWriteMessages</h4> |
| <pre>int getScheduledWriteMessages()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of messages which are scheduled to be written to this session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getScheduledWriteBytes--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getScheduledWriteBytes</h4> |
| <pre>long getScheduledWriteBytes()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of bytes which are scheduled to be written to this |
| session.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getCurrentWriteMessage--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCurrentWriteMessage</h4> |
| <pre><a href="https://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> getCurrentWriteMessage()</pre> |
| <div class="block">Returns the message which is being written by <a href="../../../../../org/apache/mina/core/service/IoService.html" title="interface in org.apache.mina.core.service"><code>IoService</code></a>.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>null</tt> if and if only no message is being written</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getCurrentWriteRequest--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCurrentWriteRequest</h4> |
| <pre><a href="../../../../../org/apache/mina/core/write/WriteRequest.html" title="interface in org.apache.mina.core.write">WriteRequest</a> getCurrentWriteRequest()</pre> |
| <div class="block">Returns the <a href="../../../../../org/apache/mina/core/write/WriteRequest.html" title="interface in org.apache.mina.core.write"><code>WriteRequest</code></a> which is being processed by |
| <a href="../../../../../org/apache/mina/core/service/IoService.html" title="interface in org.apache.mina.core.service"><code>IoService</code></a>.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>null</tt> if and if only no message is being written</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getCreationTime--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCreationTime</h4> |
| <pre>long getCreationTime()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the session's creation time in milliseconds</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getLastIoTime--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getLastIoTime</h4> |
| <pre>long getLastIoTime()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the time in millis when I/O occurred lastly.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getLastReadTime--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getLastReadTime</h4> |
| <pre>long getLastReadTime()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the time in millis when read operation occurred lastly.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getLastWriteTime--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getLastWriteTime</h4> |
| <pre>long getLastWriteTime()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the time in millis when write operation occurred lastly.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isIdle-org.apache.mina.core.session.IdleStatus-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isIdle</h4> |
| <pre>boolean isIdle(<a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session">IdleStatus</a> status)</pre> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>status</code> - The researched idle status</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if this session is idle for the specified |
| <a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session"><code>IdleStatus</code></a>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isReaderIdle--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isReaderIdle</h4> |
| <pre>boolean isReaderIdle()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if this session is <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#READER_IDLE"><code>IdleStatus.READER_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#isIdle-org.apache.mina.core.session.IdleStatus-"><code>isIdle(IdleStatus)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isWriterIdle--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isWriterIdle</h4> |
| <pre>boolean isWriterIdle()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if this session is <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#WRITER_IDLE"><code>IdleStatus.WRITER_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#isIdle-org.apache.mina.core.session.IdleStatus-"><code>isIdle(IdleStatus)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="isBothIdle--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isBothIdle</h4> |
| <pre>boolean isBothIdle()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><tt>true</tt> if this session is <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#BOTH_IDLE"><code>IdleStatus.BOTH_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#isIdle-org.apache.mina.core.session.IdleStatus-"><code>isIdle(IdleStatus)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getIdleCount-org.apache.mina.core.session.IdleStatus-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getIdleCount</h4> |
| <pre>int getIdleCount(<a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session">IdleStatus</a> status)</pre> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>status</code> - The researched idle status</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of the fired continuous <tt>sessionIdle</tt> events |
| for the specified <a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session"><code>IdleStatus</code></a>. |
| <p> |
| If <tt>sessionIdle</tt> event is fired first after some time after I/O, |
| <tt>idleCount</tt> becomes <tt>1</tt>. <tt>idleCount</tt> resets to |
| <tt>0</tt> if any I/O occurs again, otherwise it increases to |
| <tt>2</tt> and so on if <tt>sessionIdle</tt> event is fired again without |
| any I/O between two (or more) <tt>sessionIdle</tt> events.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getReaderIdleCount--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getReaderIdleCount</h4> |
| <pre>int getReaderIdleCount()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of the fired continuous <tt>sessionIdle</tt> events |
| for <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#READER_IDLE"><code>IdleStatus.READER_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#getIdleCount-org.apache.mina.core.session.IdleStatus-"><code>getIdleCount(IdleStatus)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getWriterIdleCount--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getWriterIdleCount</h4> |
| <pre>int getWriterIdleCount()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of the fired continuous <tt>sessionIdle</tt> events |
| for <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#WRITER_IDLE"><code>IdleStatus.WRITER_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#getIdleCount-org.apache.mina.core.session.IdleStatus-"><code>getIdleCount(IdleStatus)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getBothIdleCount--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getBothIdleCount</h4> |
| <pre>int getBothIdleCount()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the number of the fired continuous <tt>sessionIdle</tt> events |
| for <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#BOTH_IDLE"><code>IdleStatus.BOTH_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#getIdleCount-org.apache.mina.core.session.IdleStatus-"><code>getIdleCount(IdleStatus)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getLastIdleTime-org.apache.mina.core.session.IdleStatus-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getLastIdleTime</h4> |
| <pre>long getLastIdleTime(<a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session">IdleStatus</a> status)</pre> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>status</code> - The researched idle status</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the time in milliseconds when the last <tt>sessionIdle</tt> event |
| is fired for the specified <a href="../../../../../org/apache/mina/core/session/IdleStatus.html" title="class in org.apache.mina.core.session"><code>IdleStatus</code></a>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getLastReaderIdleTime--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getLastReaderIdleTime</h4> |
| <pre>long getLastReaderIdleTime()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the time in milliseconds when the last <tt>sessionIdle</tt> event |
| is fired for <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#READER_IDLE"><code>IdleStatus.READER_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastIdleTime-org.apache.mina.core.session.IdleStatus-"><code>getLastIdleTime(IdleStatus)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getLastWriterIdleTime--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getLastWriterIdleTime</h4> |
| <pre>long getLastWriterIdleTime()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the time in milliseconds when the last <tt>sessionIdle</tt> event |
| is fired for <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#WRITER_IDLE"><code>IdleStatus.WRITER_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastIdleTime-org.apache.mina.core.session.IdleStatus-"><code>getLastIdleTime(IdleStatus)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getLastBothIdleTime--"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>getLastBothIdleTime</h4> |
| <pre>long getLastBothIdleTime()</pre> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the time in milliseconds when the last <tt>sessionIdle</tt> event |
| is fired for <a href="../../../../../org/apache/mina/core/session/IdleStatus.html#BOTH_IDLE"><code>IdleStatus.BOTH_IDLE</code></a>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/mina/core/session/IoSession.html#getLastIdleTime-org.apache.mina.core.session.IdleStatus-"><code>getLastIdleTime(IdleStatus)</code></a></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="class-use/IoSession.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">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../../org/apache/mina/core/session/IoEventType.html" title="enum in org.apache.mina.core.session"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../../../org/apache/mina/core/session/IoSessionAttributeMap.html" title="interface in org.apache.mina.core.session"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../../index.html?org/apache/mina/core/session/IoSession.html" target="_top">Frames</a></li> |
| <li><a href="IoSession.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../../allclasses-noframe.html">All 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: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| <p class="legalCopy"><small>Copyright © 2004–2019 <a href="https://mina.apache.org/">Apache MINA Project</a>. All rights reserved.</small></p> |
| </body> |
| </html> |