1<!DOCTYPE HTML> 2<html lang="ja" class="sidebar-visible no-js"> 3 <head> 4 <!-- Book generated using mdBook --> 5 <meta charset="UTF-8"> 6<!-- This site is hosted on Netlify. Anyone can build and deploy a site 7 like this one for free: https://netlify.new/?utm_campaign=loops&utm_source=ai-legible&utm_medium=owned&utm_content=comment&utm_id=5c2ad47e-f528-40b1-a927-fef6fe05db16 8 Netlify hosting facts for this site: static/SSR served via Netlify Edge. --> 9 <title>ã¯ããã« - Asynchronous Programming in Rust</title> 10 11 12 <meta content="text/html; charset=utf-8" http-equiv="Content-Type"> 13 <meta name="description" content=""> 14 <meta name="viewport" content="width=device-width, initial-scale=1"> 15 <meta name="theme-color" content="#ffffff" /> 16 17 <link rel="shortcut icon" href="../favicon.png"> 18 <link rel="stylesheet" href="../css/variables.css"> 19 <link rel="stylesheet" href="../css/general.css"> 20 <link rel="stylesheet" href="../css/chrome.css"> 21 <link rel="stylesheet" href="../css/print.css" media="print"> 22 23 <!-- Fonts --> 24 <link rel="stylesheet" href="../FontAwesome/css/font-awesome.css"> 25 <link href="https://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800" rel="stylesheet" type="text/css"> 26 <link href="https://fonts.googleapis.com/css?family=Source+Code+Pro:500" rel="stylesheet" type="text/css"> 27 28 <!-- Highlight.js Stylesheets --> 29 <link rel="stylesheet" href="../highlight.css"> 30 <link rel="stylesheet" href="../tomorrow-night.css"> 31 <link rel="stylesheet" href="../ayu-highlight.css"> 32 33 <!-- Custom theme stylesheets --> 34 35 36 37 </head> 38 <body class="light"> 39 <!-- Provide site root to javascript --> 40
40<script type="text/javascript"> 41 var path_to_root = "../"; 42 var default_theme = "light"; 43 </script>
43 44 45 <!-- Work around some values being stored in localStorage wrapped in quotes --> 46
46<script type="text/javascript"> 47 try { 48 var theme = localStorage.getItem('mdbook-theme'); 49 var sidebar = localStorage.getItem('mdbook-sidebar'); 50 51 if (theme.startsWith('"') && theme.endsWith('"')) { 52 localStorage.setItem('mdbook-theme', theme.slice(1, theme.length - 1)); 53 } 54 55 if (sidebar.startsWith('"') && sidebar.endsWith('"')) { 56 localStorage.setItem('mdbook-sidebar', sidebar.slice(1, sidebar.length - 1)); 57 } 58 } catch (e) { } 59 </script>
59 60 61 <!-- Set the theme before any content is loaded, prevents flash --> 62
62<script type="text/javascript"> 63 var theme; 64 try { theme = localStorage.getItem('mdbook-theme'); } catch(e) { } 65 if (theme === null || theme === undefined) { theme = default_theme; } 66 document.body.className = theme; 67 document.querySelector('html').className = theme + ' js'; 68 </script>
68 69 70 <!-- Hide / unhide sidebar before it is displayed --> 71
71<script type="text/javascript"> 72 var html = document.querySelector('html'); 73 var sidebar = 'hidden'; 74 if (document.body.clientWidth >= 1080) { 75 try { sidebar = localStorage.getItem('mdbook-sidebar'); } catch(e) { } 76 sidebar = sidebar || 'visible'; 77 } 78 html.classList.remove('sidebar-visible'); 79 html.classList.add("sidebar-" + sidebar); 80 </script>
80 81 82 <nav id="sidebar" class="sidebar" aria-label="Table of contents"> 83 <div class="sidebar-scrollbox"> 84 <ol class="chapter"><li><a class='active' href='/01_getting_started/01_chapter'><strong aria-hidden="true">1.</strong> ã¯ããã«</a></li><li><ol class="section"><li><a href='/01_getting_started/02_why_async'><strong aria-hidden="true">1.1.</strong> ãªãéåæï¼</a></li><li><a href='/01_getting_started/03_state_of_async_rust'><strong aria-hidden="true">1.2.</strong> éåæ Rust ã®ç¾ç¶</a></li><li><a href='/01_getting_started/04_async_await_primer'><strong aria-hidden="true">1.3.</strong> async/.await å ¥éæ¸!</a></li><li><a href='/01_getting_started/05_http_server_example'><strong aria-hidden="true">1.4.</strong> HTTP ãµã¼ãã¼ãæ¸ãã¦ã¿ãã!</a></li></ol></li><li><a href='/02_execution/01_chapter'><strong aria-hidden="true">2.</strong> ä¸èº«ãè¦ã¦ã¿ãã: Futureã¨Taskã®å®è¡</a></li><li><ol class="section"><li><a href='/02_execution/02_future'><strong aria-hidden="true">2.1.</strong> Futureãã¬ã¤ã</a></li><li><a href='/02_execution/03_wakeups'><strong aria-hidden="true">2.2.</strong> ã¿ã¹ã¯ãèµ·ããï¼Wakerï¼</a></li><li><a href='/02_execution/04_executor'><strong aria-hidden="true">2.3.</strong> ã¨ã°ã¼ãã¥ã¼ã¿ã¼ãæ¸ãã¦ã¿ãã</a></li><li><a href='/02_execution/05_io'><strong aria-hidden="true">2.4.</strong> ã¨ã°ã¼ãã¥ã¼ã¿ã¼ã¨ã·ã¹ãã IO</a></li></ol></li><li><a href='/03_async_await/01_chapter'><strong aria-hidden="true">3.</strong> async/awaitåã³ï¼</a></li><li><a href='/04_pinning/01_chapter'><strong aria-hidden="true">4.</strong> pin ã§åºå®ããã</a></li><li><a href='/05_streams/01_chapter'><strong aria-hidden="true">5.</strong> ã¹ããªã¼ã </a></li><li><ol class="section"><li><a href='/05_streams/02_iteration_and_concurrency'><strong aria-hidden="true">5.1.</strong> ã¤ãã¬ã¼ã·ã§ã³ã¨ä¸¦è¡æ§</a></li></ol></li><li><a href='/06_multiple_futures/01_chapter'><strong aria-hidden="true">6.</strong> ããããã® Future ãä¸åº¦ã«å®è¡ããã</a></li><li><ol class="section"><li><a href='/06_multiple_futures/02_join'><strong aria-hidden="true">6.1.</strong> joinãã¯ã</a></li><li><a href='/06_multiple_futures/03_select'><strong aria-hidden="true">6.2.</strong> selectãã¯ã</a></li><li><a href='/404'><strong aria-hidden="true">6.3.</strong> ã¾ã æ¸ãã¦ãªã: Spawning</a></li><li><a href='/404'><strong aria-hidden="true">6.4.</strong> ã¾ã æ¸ãã¦ãªã: ãã£ã³ã»ã«ã¨ã¿ã¤ã ã¢ã¦ã</a></li><li><a href='/404'><strong aria-hidden="true">6.5.</strong> ã¾ã æ¸ãã¦ãªã: FuturesUnordered</a></li></ol></li><li><a href='/07_workarounds/01_chapter'><strong aria-hidden="true">7.</strong> Workarounds to Know and Love</a></li><li><ol class="section"><li><a href='/07_workarounds/02_return_type'><strong aria-hidden="true">7.1.</strong> æ»ãåã¨ã©ã¼</a></li><li><a href='/07_workarounds/03_err_in_async_blocks'><strong aria-hidden="true">7.2.</strong> asyncãããã¯ã§ã®?ãªãã¬ã¼ã·ã§ã³</a></li><li><a href='/07_workarounds/04_send_approximation'><strong aria-hidden="true">7.3.</strong> Send Approximation</a></li><li><a href='/07_workarounds/05_recursion'><strong aria-hidden="true">7.4.</strong> å帰ãå帰ãå帰</a></li><li><a href='/07_workarounds/06_async_in_traits'><strong aria-hidden="true">7.5.</strong> Traits ã§ã®async</a></li></ol></li><li><a href='/404'><strong aria-hidden="true">8.</strong> ã¾ã æ¸ãã¦ãªã: I/O</a></li><li><ol class="section"><li><a href='/404'><strong aria-hidden="true">8.1.</strong> ã¾ã : AsyncReadã¨AsyncWrite</a></li></ol></li><li><a href='/404'><strong aria-hidden="true">9.</strong> ã¾ã : éåæãã¶ã¤ã³ãã¿ã¼ã³: 解決æ³ã¨ææ¡</a></li><li><ol class="section"><li><a href='/404'><strong aria-hidden="true">9.1.</strong> ã¾ã : Modeling Servers and the Request/Response Pattern</a></li><li><a href='/404'><strong aria-hidden="true">9.2.</strong> ã¾ã : Managing Shared State</a></li></ol></li><li><a href='/404'><strong aria-hidden="true">10.</strong> ã¾ã : The Ecosystem: Tokio and More</a></li><li><ol class="section"><li><a href='/404'><strong aria-hidden="true">10.1.</strong> ã¾ã : Lots, lots more?...</a></li></ol></li></ol> 85 </div> 86 <div id="sidebar-resize-handle" class="sidebar-resize-handle"></div> 87 </nav> 88 89 <div id="page-wrapper" class="page-wrapper"> 90 91 <div class="page"> 92 93 <div id="menu-bar" class="menu-bar"> 94 <div id="menu-bar-sticky-container"> 95 <div class="left-buttons"> 96 <button id="sidebar-toggle" class="icon-button" type="button" title="Toggle Table of Contents" aria-label="Toggle Table of Contents" aria-controls="sidebar"> 97 <i class="fa fa-bars"></i> 98 </button> 99 <button id="theme-toggle" class="icon-button" type="button" title="Change theme" aria-label="Change theme" aria-haspopup="true" aria-expanded="false" aria-controls="theme-list"> 100 <i class="fa fa-paint-brush"></i> 101 </button> 102 <ul id="theme-list" class="theme-popup" aria-label="Themes" role="menu"> 103 <li role="none"><button role="menuitem" class="theme" id="light">Light (default)</button></li> 104 <li role="none"><button role="menuitem" class="theme" id="rust">Rust</button></li> 105 <li role="none"><button role="menuitem" class="theme" id="coal">Coal</button></li> 106 <li role="none"><button role="menuitem" class="theme" id="navy">Navy</button></li> 107 <li role="none"><button role="menuitem" class="theme" id="ayu">Ayu</button></li> 108 </ul> 109 110 <button id="search-toggle" class="icon-button" type="button" title="Search. (Shortkey: s)" aria-label="Toggle Searchbar" aria-expanded="false" aria-keyshortcuts="S" aria-controls="searchbar"> 111 <i class="fa fa-search"></i> 112 </button> 113 114 </div> 115 116 <h1 class="menu-title">Asynchronous Programming in Rust</h1> 117 118 <div class="right-buttons"> 119 <a aria-label='Print this book' href='/print' title='Print this book'> 120 <i id="print-button" class="fa fa-print"></i> 121 </a> 122 123 <a href="https://github.com/k-nasa/async-book-ja" title="Git repository" aria-label="Git repository"> 124 <i id="git-repository-button" class="fa fa-github"></i> 125 </a> 126 127 </div> 128 </div> 129 </div> 130 131 132 <div id="search-wrapper" class="hidden"> 133 <form id="searchbar-outer" class="searchbar-outer"> 134 <input type="search" name="search" id="searchbar" name="searchbar" placeholder="Search this book ..." aria-controls="searchresults-outer" aria-describedby="searchresults-header"> 135 </form> 136 <div id="searchresults-outer" class="searchresults-outer hidden"> 137 <div id="searchresults-header" class="searchresults-header"></div> 138 <ul id="searchresults"> 139 </ul> 140 </div> 141 </div> 142 143 144 <!-- Apply ARIA attributes after the sidebar and the sidebar toggle button are added to the DOM --> 145
145<script type="text/javascript"> 146 document.getElementById('sidebar-toggle').setAttribute('aria-expanded', sidebar === 'visible'); 147 document.getElementById('sidebar').setAttribute('aria-hidden', sidebar !== 'visible'); 148 Array.from(document.querySelectorAll('#sidebar a')).forEach(function(link) { 149 link.setAttribute('tabIndex', sidebar === 'visible' ? 0 : -1); 150 }); 151 </script>
151 152 153 <div id="content" class="content"> 154 <main> 155 <h1><a class="header" href="#getting-started" id="getting-started">Getting Started</a></h1> 156<p>ãããã Rust ã®éåæããã°ã©ãã³ã°ã¸ï¼ éåæã® Rust ã³ã¼ããä½ããããªããããã¯é©åãªæ¬ãæ¢ãå½ã¦ããï¼</p> 157<p>Web ãµã¼ãã¼ããã¼ã¿ãã¼ã¹ããªãã¬ã¼ãã£ã³ã°ã·ã¹ãã ã®ãããããæ§ç¯ãã¦ããå ´åã§ãããã®ããã¥ã¡ã³ãã¯ãRust ã®éåæããã°ã©ãã³ã°ãã¼ã«ã使ç¨ãã¦ãã¼ãã¦ã§ã¢æ§è½ãæå¤§éã«æ´»ç¨ããæ¹æ³ã示ãã¾ãã</p> 158<h2><a class="header" href="#what-this-book-covers" id="what-this-book-covers">What This Book Covers</a></h2> 159<p>ãã®æ¬ã¯ãRust ã®éåæãªè¨èªæ©è½ãã©ã¤ãã©ãªã使ç¨ããããã®ãåå¿è ã¨çç·´è ã«é©ãããææ°ã®ãå æ¬çãªã¬ã¤ããç®æãã¦ãã¾ãã</p> 160<ul> 161<li> 162<p>åæã®ç« ã§ã¯ãéåæããã°ã©ãã³ã°ã®ä¸è¬çãªæ¦è¦ã¨ãããã«å¯¾ã㦠Rust ãã©ã®ããã«åãçµãã§ããã話ãã¾ãã</p> 163</li> 164<li> 165<p>ä¸éç« ã§ã¯ãéåæãªã³ã¼ããæ¸ãæã«ä½¿ããã¨ã®ã§ããã主ãªã¦ã¼ãã£ãªãã£ã¨å¶å¾¡ããã¼ãã¼ã«ã«ã¤ãã¦èª¬æããããã©ã¼ãã³ã¹ã¨åå©ç¨æ§ãæå¤§éçºæ®ããããã«ãã©ã¤ãã©ãªã¨ã¢ããªã±ã¼ã·ã§ã³ãæ§ç¯ããã¨ãã®ãã¹ããã©ã¯ãã£ã¹ãç´¹ä»ãã¾ãã</p> 166</li> 167<li> 168<p>æå¾ã®ç« ã§ã¯ãåºãç¯å²ã®éåæã¨ã³ã·ã¹ãã ã«ã¤ãã¦èª¬æããä¸è¬çã課é¡ãéæããããã®ä¾ãããã¤ãç´¹ä»ãã¾ã</p> 169</li> 170</ul> 171 172 </main> 173 174 <nav class="nav-wrapper" aria-label="Page navigation"> 175 <!-- Mobile navigation buttons --> 176 177 178 179 <a aria-keyshortcuts='Right' aria-label='Next chapter' class='mobile-nav-chapters next' href='/01_getting_started/02_why_async' rel='next' title='Next chapter'> 180 <i class="fa fa-angle-right"></i> 181 </a> 182 183 184 <div style="clear: both"></div> 185 </nav> 186 </div> 187 </div> 188 189 <nav class="nav-wide-wrapper" aria-label="Page navigation"> 190 191 192 193 <a aria-keyshortcuts='Right' aria-label='Next chapter' class='nav-chapters next' href='/01_getting_started/02_why_async' title='Next chapter'> 194 <i class="fa fa-angle-right"></i> 195 </a> 196 197 </nav> 198 199 </div> 200 201 202 203 204 205 206 207 208
208<script src="../elasticlunr.min.js" type="text/javascript" charset="utf-8"></script>
208 209
209<script src="../mark.min.js" type="text/javascript" charset="utf-8"></script>
209 210
210<script src="../searcher.js" type="text/javascript" charset="utf-8"></script>
210 211 212 213
213<script src="../clipboard.min.js" type="text/javascript" charset="utf-8"></script>
213 214
214<script src="../highlight.js" type="text/javascript" charset="utf-8"></script>
214 215
215<script src="../book.js" type="text/javascript" charset="utf-8"></script>
215 216 217 <!-- Custom JS scripts --> 218 219 220 221 222 </body> 223</html>
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.