|
| 1 | +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| 2 | +<!-- NewPage --> |
| 3 | +<html lang="en"> |
| 4 | +<head> |
| 5 | +<!-- Generated by javadoc (1.8.0_91) on Wed Jun 29 10:01:25 CEST 2016 --> |
| 6 | +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| 7 | +<title>AsyncPage (GCloud Java 0.2.4 API)</title> |
| 8 | +<meta name="date" content="2016-06-29"> |
| 9 | +<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style"> |
| 10 | +<script type="text/javascript" src="../../../script.js"></script> |
| 11 | +</head> |
| 12 | +<body> |
| 13 | +<script type="text/javascript"><!-- |
| 14 | + try { |
| 15 | + if (location.href.indexOf('is-external=true') == -1) { |
| 16 | + parent.document.title="AsyncPage (GCloud Java 0.2.4 API)"; |
| 17 | + } |
| 18 | + } |
| 19 | + catch(err) { |
| 20 | + } |
| 21 | +//--> |
| 22 | +var methods = {"i0":6}; |
| 23 | +var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"]}; |
| 24 | +var altColor = "altColor"; |
| 25 | +var rowColor = "rowColor"; |
| 26 | +var tableTab = "tableTab"; |
| 27 | +var activeTableTab = "activeTableTab"; |
| 28 | +</script> |
| 29 | +<noscript> |
| 30 | +<div>JavaScript is disabled on your browser.</div> |
| 31 | +</noscript> |
| 32 | +<!-- ========= START OF TOP NAVBAR ======= --> |
| 33 | +<div class="topNav"><a name="navbar.top"> |
| 34 | +<!-- --> |
| 35 | +</a> |
| 36 | +<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| 37 | +<a name="navbar.top.firstrow"> |
| 38 | +<!-- --> |
| 39 | +</a> |
| 40 | +<ul class="navList" title="Navigation"> |
| 41 | +<li><a href="../../../overview-summary.html">Overview</a></li> |
| 42 | +<li><a href="package-summary.html">Package</a></li> |
| 43 | +<li class="navBarCell1Rev">Class</li> |
| 44 | +<li><a href="class-use/AsyncPage.html">Use</a></li> |
| 45 | +<li><a href="package-tree.html">Tree</a></li> |
| 46 | +<li><a href="../../../deprecated-list.html">Deprecated</a></li> |
| 47 | +<li><a href="../../../index-all.html">Index</a></li> |
| 48 | +</ul> |
| 49 | +</div> |
| 50 | +<div class="subNav"> |
| 51 | +<ul class="navList"> |
| 52 | +<li>Prev Class</li> |
| 53 | +<li><a href="../../../com/google/cloud/AsyncPageImpl.html" title="class in com.google.cloud"><span class="typeNameLink">Next Class</span></a></li> |
| 54 | +</ul> |
| 55 | +<ul class="navList"> |
| 56 | +<li><a href="../../../index.html?com/google/cloud/AsyncPage.html" target="_top">Frames</a></li> |
| 57 | +<li><a href="AsyncPage.html" target="_top">No Frames</a></li> |
| 58 | +</ul> |
| 59 | +<ul class="navList" id="allclasses_navbar_top"> |
| 60 | +<li><a href="../../../allclasses-noframe.html">All Classes</a></li> |
| 61 | +</ul> |
| 62 | +<div> |
| 63 | +<script type="text/javascript"><!-- |
| 64 | + allClassesLink = document.getElementById("allclasses_navbar_top"); |
| 65 | + if(window==top) { |
| 66 | + allClassesLink.style.display = "block"; |
| 67 | + } |
| 68 | + else { |
| 69 | + allClassesLink.style.display = "none"; |
| 70 | + } |
| 71 | + //--> |
| 72 | +</script> |
| 73 | +</div> |
| 74 | +<div> |
| 75 | +<ul class="subNavList"> |
| 76 | +<li>Summary: </li> |
| 77 | +<li>Nested | </li> |
| 78 | +<li>Field | </li> |
| 79 | +<li>Constr | </li> |
| 80 | +<li><a href="#method.summary">Method</a></li> |
| 81 | +</ul> |
| 82 | +<ul class="subNavList"> |
| 83 | +<li>Detail: </li> |
| 84 | +<li>Field | </li> |
| 85 | +<li>Constr | </li> |
| 86 | +<li><a href="#method.detail">Method</a></li> |
| 87 | +</ul> |
| 88 | +</div> |
| 89 | +<a name="skip.navbar.top"> |
| 90 | +<!-- --> |
| 91 | +</a></div> |
| 92 | +<!-- ========= END OF TOP NAVBAR ========= --> |
| 93 | +<!-- ======== START OF CLASS DATA ======== --> |
| 94 | +<div class="header"> |
| 95 | +<div class="subTitle">com.google.cloud</div> |
| 96 | +<h2 title="Interface AsyncPage" class="title">Interface AsyncPage<T></h2> |
| 97 | +</div> |
| 98 | +<div class="contentContainer"> |
| 99 | +<div class="description"> |
| 100 | +<ul class="blockList"> |
| 101 | +<li class="blockList"> |
| 102 | +<dl> |
| 103 | +<dt><span class="paramLabel">Type Parameters:</span></dt> |
| 104 | +<dd><code>T</code> - the value type that the page holds</dd> |
| 105 | +</dl> |
| 106 | +<dl> |
| 107 | +<dt>All Superinterfaces:</dt> |
| 108 | +<dd><a href="../../../com/google/cloud/Page.html" title="interface in com.google.cloud">Page</a><T></dd> |
| 109 | +</dl> |
| 110 | +<dl> |
| 111 | +<dt>All Known Implementing Classes:</dt> |
| 112 | +<dd><a href="../../../com/google/cloud/AsyncPageImpl.html" title="class in com.google.cloud">AsyncPageImpl</a></dd> |
| 113 | +</dl> |
| 114 | +<hr> |
| 115 | +<br> |
| 116 | +<pre>public interface <span class="typeNameLabel">AsyncPage<T></span> |
| 117 | +extends <a href="../../../com/google/cloud/Page.html" title="interface in com.google.cloud">Page</a><T></pre> |
| 118 | +<div class="block">Interface for asynchronously consuming Google Cloud paginated results. |
| 119 | + |
| 120 | + <p>Use <code>AsyncPage</code> to iterate through all values (also in next pages): |
| 121 | + <pre> <code> |
| 122 | + AsyncPage<T> page = ...; // get an AsyncPage<T> instance |
| 123 | + Iterator<T> iterator = page.iterateAll(); |
| 124 | + while (iterator.hasNext()) { |
| 125 | + T value = iterator.next(); |
| 126 | + // do something with value |
| 127 | + }</code></pre> |
| 128 | + |
| 129 | + <p>Or handle pagination explicitly: |
| 130 | + <pre> <code> |
| 131 | + AsyncPage<T> page = ...; // get a AsyncPage<T> instance |
| 132 | + while (page != null) { |
| 133 | + for (T value : page.values()) { |
| 134 | + // do something with value |
| 135 | + } |
| 136 | + page = page.nextPageAsync().get(); |
| 137 | + }</code></pre></div> |
| 138 | +</li> |
| 139 | +</ul> |
| 140 | +</div> |
| 141 | +<div class="summary"> |
| 142 | +<ul class="blockList"> |
| 143 | +<li class="blockList"> |
| 144 | +<!-- ========== METHOD SUMMARY =========== --> |
| 145 | +<ul class="blockList"> |
| 146 | +<li class="blockList"><a name="method.summary"> |
| 147 | +<!-- --> |
| 148 | +</a> |
| 149 | +<h3>Method Summary</h3> |
| 150 | +<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> |
| 151 | +<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></caption> |
| 152 | +<tr> |
| 153 | +<th class="colFirst" scope="col">Modifier and Type</th> |
| 154 | +<th class="colLast" scope="col">Method and Description</th> |
| 155 | +</tr> |
| 156 | +<tr id="i0" class="altColor"> |
| 157 | +<td class="colFirst"><code><a href="http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/Future.html?is-external=true" title="class or interface in java.util.concurrent">Future</a><<a href="../../../com/google/cloud/AsyncPage.html" title="interface in com.google.cloud">AsyncPage</a><<a href="../../../com/google/cloud/AsyncPage.html" title="type parameter in AsyncPage">T</a>>></code></td> |
| 158 | +<td class="colLast"><code><span class="memberNameLink"><a href="../../../com/google/cloud/AsyncPage.html#nextPageAsync--">nextPageAsync</a></span>()</code> |
| 159 | +<div class="block">Returns a <a href="http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/Future.html?is-external=true" title="class or interface in java.util.concurrent"><code>Future</code></a> object for the next page.</div> |
| 160 | +</td> |
| 161 | +</tr> |
| 162 | +</table> |
| 163 | +<ul class="blockList"> |
| 164 | +<li class="blockList"><a name="methods.inherited.from.class.com.google.cloud.Page"> |
| 165 | +<!-- --> |
| 166 | +</a> |
| 167 | +<h3>Methods inherited from interface com.google.cloud.<a href="../../../com/google/cloud/Page.html" title="interface in com.google.cloud">Page</a></h3> |
| 168 | +<code><a href="../../../com/google/cloud/Page.html#iterateAll--">iterateAll</a>, <a href="../../../com/google/cloud/Page.html#nextPage--">nextPage</a>, <a href="../../../com/google/cloud/Page.html#nextPageCursor--">nextPageCursor</a>, <a href="../../../com/google/cloud/Page.html#values--">values</a></code></li> |
| 169 | +</ul> |
| 170 | +</li> |
| 171 | +</ul> |
| 172 | +</li> |
| 173 | +</ul> |
| 174 | +</div> |
| 175 | +<div class="details"> |
| 176 | +<ul class="blockList"> |
| 177 | +<li class="blockList"> |
| 178 | +<!-- ============ METHOD DETAIL ========== --> |
| 179 | +<ul class="blockList"> |
| 180 | +<li class="blockList"><a name="method.detail"> |
| 181 | +<!-- --> |
| 182 | +</a> |
| 183 | +<h3>Method Detail</h3> |
| 184 | +<a name="nextPageAsync--"> |
| 185 | +<!-- --> |
| 186 | +</a> |
| 187 | +<ul class="blockListLast"> |
| 188 | +<li class="blockList"> |
| 189 | +<h4>nextPageAsync</h4> |
| 190 | +<pre><a href="http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/Future.html?is-external=true" title="class or interface in java.util.concurrent">Future</a><<a href="../../../com/google/cloud/AsyncPage.html" title="interface in com.google.cloud">AsyncPage</a><<a href="../../../com/google/cloud/AsyncPage.html" title="type parameter in AsyncPage">T</a>>> nextPageAsync()</pre> |
| 191 | +<div class="block">Returns a <a href="http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/Future.html?is-external=true" title="class or interface in java.util.concurrent"><code>Future</code></a> object for the next page. <a href="http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/Future.html?is-external=true#get--" title="class or interface in java.util.concurrent"><code>Future.get()</code></a> returns <code>null</code> if |
| 192 | + the last page has been reached.</div> |
| 193 | +</li> |
| 194 | +</ul> |
| 195 | +</li> |
| 196 | +</ul> |
| 197 | +</li> |
| 198 | +</ul> |
| 199 | +</div> |
| 200 | +</div> |
| 201 | +<!-- ========= END OF CLASS DATA ========= --> |
| 202 | +<!-- ======= START OF BOTTOM NAVBAR ====== --> |
| 203 | +<div class="bottomNav"><a name="navbar.bottom"> |
| 204 | +<!-- --> |
| 205 | +</a> |
| 206 | +<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| 207 | +<a name="navbar.bottom.firstrow"> |
| 208 | +<!-- --> |
| 209 | +</a> |
| 210 | +<ul class="navList" title="Navigation"> |
| 211 | +<li><a href="../../../overview-summary.html">Overview</a></li> |
| 212 | +<li><a href="package-summary.html">Package</a></li> |
| 213 | +<li class="navBarCell1Rev">Class</li> |
| 214 | +<li><a href="class-use/AsyncPage.html">Use</a></li> |
| 215 | +<li><a href="package-tree.html">Tree</a></li> |
| 216 | +<li><a href="../../../deprecated-list.html">Deprecated</a></li> |
| 217 | +<li><a href="../../../index-all.html">Index</a></li> |
| 218 | +</ul> |
| 219 | +</div> |
| 220 | +<div class="subNav"> |
| 221 | +<ul class="navList"> |
| 222 | +<li>Prev Class</li> |
| 223 | +<li><a href="../../../com/google/cloud/AsyncPageImpl.html" title="class in com.google.cloud"><span class="typeNameLink">Next Class</span></a></li> |
| 224 | +</ul> |
| 225 | +<ul class="navList"> |
| 226 | +<li><a href="../../../index.html?com/google/cloud/AsyncPage.html" target="_top">Frames</a></li> |
| 227 | +<li><a href="AsyncPage.html" target="_top">No Frames</a></li> |
| 228 | +</ul> |
| 229 | +<ul class="navList" id="allclasses_navbar_bottom"> |
| 230 | +<li><a href="../../../allclasses-noframe.html">All Classes</a></li> |
| 231 | +</ul> |
| 232 | +<div> |
| 233 | +<script type="text/javascript"><!-- |
| 234 | + allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| 235 | + if(window==top) { |
| 236 | + allClassesLink.style.display = "block"; |
| 237 | + } |
| 238 | + else { |
| 239 | + allClassesLink.style.display = "none"; |
| 240 | + } |
| 241 | + //--> |
| 242 | +</script> |
| 243 | +</div> |
| 244 | +<div> |
| 245 | +<ul class="subNavList"> |
| 246 | +<li>Summary: </li> |
| 247 | +<li>Nested | </li> |
| 248 | +<li>Field | </li> |
| 249 | +<li>Constr | </li> |
| 250 | +<li><a href="#method.summary">Method</a></li> |
| 251 | +</ul> |
| 252 | +<ul class="subNavList"> |
| 253 | +<li>Detail: </li> |
| 254 | +<li>Field | </li> |
| 255 | +<li>Constr | </li> |
| 256 | +<li><a href="#method.detail">Method</a></li> |
| 257 | +</ul> |
| 258 | +</div> |
| 259 | +<a name="skip.navbar.bottom"> |
| 260 | +<!-- --> |
| 261 | +</a></div> |
| 262 | +<!-- ======== END OF BOTTOM NAVBAR ======= --> |
| 263 | +<p class="legalCopy"><small>Copyright © 2016 Google. All rights reserved.</small></p> |
| 264 | +</body> |
| 265 | +</html> |
0 commit comments