| <!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 (version 1.7.0_80) on Wed Jun 07 15:10:48 EDT 2017 --> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <title>IteratingCallback (Jetty :: Project 9.2.22.v20170606 API)</title> |
| <meta name="date" content="2017-06-07"> |
| <link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style"> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="IteratingCallback (Jetty :: Project 9.2.22.v20170606 API)"; |
| } |
| //--> |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar_top"> |
| <!-- --> |
| </a><a href="#skip-navbar_top" title="Skip navigation links"></a><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/IteratingCallback.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 class="aboutLanguage"><em><script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-1149868-7']); _gaq.push(['_trackPageview']); (function() { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); </script></em></div> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../org/eclipse/jetty/util/IPAddressMap.html" title="class in org.eclipse.jetty.util"><span class="strong">Prev Class</span></a></li> |
| <li><a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html" title="enum in org.eclipse.jetty.util"><span class="strong">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/eclipse/jetty/util/IteratingCallback.html" target="_top">Frames</a></li> |
| <li><a href="IteratingCallback.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><a href="#nested_class_summary">Nested</a> | </li> |
| <li>Field | </li> |
| <li><a href="#constructor_summary">Constr</a> | </li> |
| <li><a href="#method_summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li><a href="#constructor_detail">Constr</a> | </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.eclipse.jetty.util</div> |
| <h2 title="Class IteratingCallback" class="title">Class IteratingCallback</h2> |
| </div> |
| <div class="contentContainer"> |
| <ul class="inheritance"> |
| <li><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li>org.eclipse.jetty.util.IteratingCallback</li> |
| </ul> |
| </li> |
| </ul> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt>All Implemented Interfaces:</dt> |
| <dd><a href="../../../../org/eclipse/jetty/util/Callback.html" title="interface in org.eclipse.jetty.util">Callback</a></dd> |
| </dl> |
| <dl> |
| <dt>Direct Known Subclasses:</dt> |
| <dd><a href="../../../../org/eclipse/jetty/proxy/AsyncMiddleManServlet.ProxyReader.html" title="class in org.eclipse.jetty.proxy">AsyncMiddleManServlet.ProxyReader</a>, <a href="../../../../org/eclipse/jetty/proxy/AsyncProxyServlet.StreamReader.html" title="class in org.eclipse.jetty.proxy">AsyncProxyServlet.StreamReader</a>, <a href="../../../../org/eclipse/jetty/util/IteratingNestedCallback.html" title="class in org.eclipse.jetty.util">IteratingNestedCallback</a></dd> |
| </dl> |
| <hr> |
| <br> |
| <pre>public abstract class <span class="strong">IteratingCallback</span> |
| extends <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> |
| implements <a href="../../../../org/eclipse/jetty/util/Callback.html" title="interface in org.eclipse.jetty.util">Callback</a></pre> |
| <div class="block">This specialized callback implements a pattern that allows |
| a large job to be broken into smaller tasks using iteration |
| rather than recursion. |
| <p/> |
| A typical example is the write of a large content to a socket, |
| divided in chunks. Chunk C1 is written by thread T1, which |
| also invokes the callback, which writes chunk C2, which invokes |
| the callback again, which writes chunk C3, and so forth. |
| <p/> |
| The problem with the example is that if the callback thread |
| is the same that performs the I/O operation, then the process |
| is recursive and may result in a stack overflow. |
| To avoid the stack overflow, a thread dispatch must be performed, |
| causing context switching and cache misses, affecting performance. |
| <p/> |
| To avoid this issue, this callback uses an AtomicReference to |
| record whether success callback has been called during the processing |
| of a sub task, and if so then the processing iterates rather than |
| recurring. |
| <p/> |
| Subclasses must implement method <a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#process()"><code>process()</code></a> where the sub |
| task is executed and a suitable <a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html" title="enum in org.eclipse.jetty.util"><code>IteratingCallback.Action</code></a> is |
| returned to this callback to indicate the overall progress of the job. |
| This callback is passed to the asynchronous execution of each sub |
| task and a call the <a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#succeeded()"><code>succeeded()</code></a> on this callback represents |
| the completion of the sub task.</div> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ======== NESTED CLASS SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="nested_class_summary"> |
| <!-- --> |
| </a> |
| <h3>Nested Class Summary</h3> |
| <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Nested Class Summary table, listing nested classes, and an explanation"> |
| <caption><span>Nested Classes</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Class and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>protected static class </code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html" title="enum in org.eclipse.jetty.util">IteratingCallback.Action</a></strong></code> |
| <div class="block">The indication of the overall progress of the overall job that |
| implementations of <a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#process()"><code>process()</code></a> must return.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a name="nested_classes_inherited_from_class_org.eclipse.jetty.util.Callback"> |
| <!-- --> |
| </a> |
| <h3>Nested classes/interfaces inherited from interface org.eclipse.jetty.util.<a href="../../../../org/eclipse/jetty/util/Callback.html" title="interface in org.eclipse.jetty.util">Callback</a></h3> |
| <code><a href="../../../../org/eclipse/jetty/util/Callback.Adapter.html" title="class in org.eclipse.jetty.util">Callback.Adapter</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor_summary"> |
| <!-- --> |
| </a> |
| <h3>Constructor Summary</h3> |
| <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier</th> |
| <th class="colLast" scope="col">Constructor and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>protected </code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#IteratingCallback()">IteratingCallback</a></strong>()</code> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>protected </code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#IteratingCallback(boolean)">IteratingCallback</a></strong>(boolean needReset)</code> </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method_summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> |
| <caption><span>Methods</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Method and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#close()">close</a></strong>()</code> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>protected void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#completed()">completed</a></strong>()</code> |
| <div class="block"><strong>Deprecated.</strong> |
| <div class="block"><i>Use <a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#onCompleteSuccess()"><code>onCompleteSuccess()</code></a> instead.</i></div> |
| </div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#failed(java.lang.Throwable)">failed</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</a> x)</code> |
| <div class="block">Invoked when the sub task fails.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#isClosed()">isClosed</a></strong>()</code> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#isFailed()">isFailed</a></strong>()</code> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#isSucceeded()">isSucceeded</a></strong>()</code> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#iterate()">iterate</a></strong>()</code> |
| <div class="block">This method must be invoked by applications to start the processing |
| of sub tasks.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>protected void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#onCompleteFailure(java.lang.Throwable)">onCompleteFailure</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</a> x)</code> |
| <div class="block">Invoked when the overall task has completed with a failure.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>protected void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#onCompleteSuccess()">onCompleteSuccess</a></strong>()</code> |
| <div class="block">Invoked when the overall task has completed successfully.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>protected abstract <a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html" title="enum in org.eclipse.jetty.util">IteratingCallback.Action</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#process()">process</a></strong>()</code> |
| <div class="block">Method called by <a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#iterate()"><code>iterate()</code></a> to process the sub task.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#reset()">reset</a></strong>()</code> |
| <div class="block">Resets this callback.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#succeeded()">succeeded</a></strong>()</code> |
| <div class="block">Invoked when the sub task succeeds.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#toString()">toString</a></strong>()</code> </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods_inherited_from_class_java.lang.Object"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> |
| <code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait(long,%20int)" title="class or interface in java.lang">wait</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor_detail"> |
| <!-- --> |
| </a> |
| <h3>Constructor Detail</h3> |
| <a name="IteratingCallback()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>IteratingCallback</h4> |
| <pre>protected IteratingCallback()</pre> |
| </li> |
| </ul> |
| <a name="IteratingCallback(boolean)"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>IteratingCallback</h4> |
| <pre>protected IteratingCallback(boolean needReset)</pre> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method_detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="process()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>process</h4> |
| <pre>protected abstract <a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html" title="enum in org.eclipse.jetty.util">IteratingCallback.Action</a> process() |
| throws <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang">Exception</a></pre> |
| <div class="block">Method called by <a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#iterate()"><code>iterate()</code></a> to process the sub task. |
| <p/> |
| Implementations must start the asynchronous execution of the sub task |
| (if any) and return an appropriate action: |
| <ul> |
| <li><a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html#IDLE"><code>IteratingCallback.Action.IDLE</code></a> when no sub tasks are available for execution |
| but the overall job is not completed yet</li> |
| <li><a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html#SCHEDULED"><code>IteratingCallback.Action.SCHEDULED</code></a> when the sub task asynchronous execution |
| has been started</li> |
| <li><a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html#SUCCEEDED"><code>IteratingCallback.Action.SUCCEEDED</code></a> when the overall job is completed</li> |
| </ul></div> |
| <dl><dt><span class="strong">Throws:</span></dt> |
| <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang">Exception</a></code> - if the sub task processing throws</dd></dl> |
| </li> |
| </ul> |
| <a name="completed()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>completed</h4> |
| <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> |
| protected void completed()</pre> |
| <div class="block"><span class="strong">Deprecated.</span> <i>Use <a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#onCompleteSuccess()"><code>onCompleteSuccess()</code></a> instead.</i></div> |
| </li> |
| </ul> |
| <a name="onCompleteSuccess()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onCompleteSuccess</h4> |
| <pre>protected void onCompleteSuccess()</pre> |
| <div class="block">Invoked when the overall task has completed successfully.</div> |
| <dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#onCompleteFailure(java.lang.Throwable)"><code>onCompleteFailure(Throwable)</code></a></dd></dl> |
| </li> |
| </ul> |
| <a name="onCompleteFailure(java.lang.Throwable)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onCompleteFailure</h4> |
| <pre>protected void onCompleteFailure(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</a> x)</pre> |
| <div class="block">Invoked when the overall task has completed with a failure.</div> |
| <dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#onCompleteSuccess()"><code>onCompleteSuccess()</code></a></dd></dl> |
| </li> |
| </ul> |
| <a name="iterate()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>iterate</h4> |
| <pre>public void iterate()</pre> |
| <div class="block">This method must be invoked by applications to start the processing |
| of sub tasks. It can be called at any time by any thread, and it's |
| contract is that when called, then the <a href="../../../../org/eclipse/jetty/util/IteratingCallback.html#process()"><code>process()</code></a> method will |
| be called during or soon after, either by the calling thread or by |
| another thread.</div> |
| </li> |
| </ul> |
| <a name="succeeded()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>succeeded</h4> |
| <pre>public void succeeded()</pre> |
| <div class="block">Invoked when the sub task succeeds. |
| Subclasses that override this method must always remember to call |
| <code>super.succeeded()</code>.</div> |
| <dl> |
| <dt><strong>Specified by:</strong></dt> |
| <dd><code><a href="../../../../org/eclipse/jetty/util/Callback.html#succeeded()">succeeded</a></code> in interface <code><a href="../../../../org/eclipse/jetty/util/Callback.html" title="interface in org.eclipse.jetty.util">Callback</a></code></dd> |
| <dt><span class="strong">See Also:</span></dt><dd><a href="../../../../org/eclipse/jetty/util/Callback.html#failed(java.lang.Throwable)"><code>Callback.failed(Throwable)</code></a></dd></dl> |
| </li> |
| </ul> |
| <a name="failed(java.lang.Throwable)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>failed</h4> |
| <pre>public void failed(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</a> x)</pre> |
| <div class="block">Invoked when the sub task fails. |
| Subclasses that override this method must always remember to call |
| <code>super.failed(Throwable)</code>.</div> |
| <dl> |
| <dt><strong>Specified by:</strong></dt> |
| <dd><code><a href="../../../../org/eclipse/jetty/util/Callback.html#failed(java.lang.Throwable)">failed</a></code> in interface <code><a href="../../../../org/eclipse/jetty/util/Callback.html" title="interface in org.eclipse.jetty.util">Callback</a></code></dd> |
| <dt><span class="strong">Parameters:</span></dt><dd><code>x</code> - the reason for the operation failure</dd></dl> |
| </li> |
| </ul> |
| <a name="close()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>close</h4> |
| <pre>public void close()</pre> |
| </li> |
| </ul> |
| <a name="isClosed()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isClosed</h4> |
| <pre>public boolean isClosed()</pre> |
| </li> |
| </ul> |
| <a name="isFailed()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isFailed</h4> |
| <pre>public boolean isFailed()</pre> |
| <dl><dt><span class="strong">Returns:</span></dt><dd>whether this callback has failed</dd></dl> |
| </li> |
| </ul> |
| <a name="isSucceeded()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isSucceeded</h4> |
| <pre>public boolean isSucceeded()</pre> |
| <dl><dt><span class="strong">Returns:</span></dt><dd>whether this callback has succeeded</dd></dl> |
| </li> |
| </ul> |
| <a name="reset()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>reset</h4> |
| <pre>public boolean reset()</pre> |
| <div class="block">Resets this callback. |
| <p/> |
| A callback can only be reset to IDLE from the |
| SUCCEEDED or FAILED states or if it is already IDLE.</div> |
| <dl><dt><span class="strong">Returns:</span></dt><dd>true if the reset was successful</dd></dl> |
| </li> |
| </ul> |
| <a name="toString()"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>toString</h4> |
| <pre>public <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString()</pre> |
| <dl> |
| <dt><strong>Overrides:</strong></dt> |
| <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</a></code> in class <code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></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><a href="#skip-navbar_bottom" title="Skip navigation links"></a><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/IteratingCallback.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 class="aboutLanguage"><em><script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-1149868-7']); _gaq.push(['_trackPageview']); (function() { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); </script></em></div> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../org/eclipse/jetty/util/IPAddressMap.html" title="class in org.eclipse.jetty.util"><span class="strong">Prev Class</span></a></li> |
| <li><a href="../../../../org/eclipse/jetty/util/IteratingCallback.Action.html" title="enum in org.eclipse.jetty.util"><span class="strong">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/eclipse/jetty/util/IteratingCallback.html" target="_top">Frames</a></li> |
| <li><a href="IteratingCallback.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><a href="#nested_class_summary">Nested</a> | </li> |
| <li>Field | </li> |
| <li><a href="#constructor_summary">Constr</a> | </li> |
| <li><a href="#method_summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li><a href="#constructor_detail">Constr</a> | </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 © 1995-2017 <a href="http://webtide.com">Webtide</a>. All Rights Reserved.</small></p> |
| </body> |
| </html> |