PageRenderTime 41ms CodeModel.GetById 1ms RepoModel.GetById 0ms app.codeStats 0ms

/docs/org/tractionas3/load/BytesTotalPrefetcher.html

http://tractionas3.googlecode.com/
HTML | 316 lines | 297 code | 10 blank | 9 comment | 0 complexity | 5a97b821aa3d98a14073ec1eac12283e MD5 | raw file
  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <html>
  3. <head>
  4. <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
  5. <link rel="stylesheet" href="../../../style.css" type="text/css" media="screen">
  6. <link rel="stylesheet" href="../../../print.css" type="text/css" media="print">
  7. <meta content="BytesTotalPrefetcher,org.tractionas3.load.BytesTotalPrefetcher,prefetchComplete,cancel,destruct,getByteWaste,getPrefetchedBytesTotal" name="keywords">
  8. <title>org.tractionas3.load.BytesTotalPrefetcher</title>
  9. </head>
  10. <body>
  11. <script type="text/javascript" language="javascript" src="../../../asdoc.js"></script><script type="text/javascript" language="javascript" src="../../../cookies.js"></script><script type="text/javascript" language="javascript">
  12. <!--
  13. asdocTitle = 'BytesTotalPrefetcher - TractionAS3 Framework Documentation';
  14. var baseRef = '../../../';
  15. window.onload = configPage;
  16. --></script>
  17. <table style="display:none" id="titleTable" cellspacing="0" cellpadding="0" class="titleTable">
  18. <tr>
  19. <td align="left" class="titleTableTitle">TractionAS3 Framework Documentation</td><td align="right" class="titleTableTopNav"><a onclick="loadClassListFrame('../../../all-classes.html')" href="../../../package-summary.html">All&nbsp;Packages</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../../all-classes.html')" href="../../../class-summary.html">All&nbsp;Classes</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../../index-list.html')" href="../../../all-index-A.html">Index</a>&nbsp;|&nbsp;<a href="../../../index.html?org/tractionas3/load/BytesTotalPrefetcher.html&amp;org/tractionas3/load/class-list.html" id="framesLink1">Frames</a><a onclick="parent.location=document.location" href="" style="display:none" id="noFramesLink1">No&nbsp;Frames</a></td><td rowspan="3" align="right" class="titleTableLogo"><img alt="Adobe Logo" title="Adobe Logo" class="logoImage" src="../../../images/logo.jpg"></td>
  20. </tr>
  21. <tr class="titleTableRow2">
  22. <td align="left" id="subTitle" class="titleTableSubTitle">Class&nbsp;BytesTotalPrefetcher</td><td align="right" id="subNav" class="titleTableSubNav"><a href="#propertySummary">Properties</a>&nbsp;| <a href="#methodSummary">Methods</a></td>
  23. </tr>
  24. <tr class="titleTableRow3">
  25. <td colspan="2">&nbsp;</td>
  26. </tr>
  27. </table>
  28. <script type="text/javascript" language="javascript">
  29. <!--
  30. if (!isEclipse() || window.name != ECLIPSE_FRAME_NAME) {titleBar_setSubTitle("Class BytesTotalPrefetcher"); titleBar_setSubNav(false,true,false,false,false,false,true,false,false,false,false,false,false,false);}
  31. --></script>
  32. <div class="MainContent">
  33. <table cellspacing="0" cellpadding="0" class="classHeaderTable">
  34. <tr>
  35. <td class="classHeaderTableLabel">Package</td><td><a onclick="javascript:loadClassListFrame('class-list.html')" href="package-detail.html">org.tractionas3.load</a></td>
  36. </tr>
  37. <tr>
  38. <td class="classHeaderTableLabel">Class</td><td class="classSignature">public class BytesTotalPrefetcher</td>
  39. </tr>
  40. <tr>
  41. <td class="classHeaderTableLabel">Inheritance</td><td class="inheritanceList">BytesTotalPrefetcher <img class="inheritArrow" alt="Inheritance" title="Inheritance" src="../../../images/inherit-arrow.gif"> <a href="../events/WeakEventDispatcher.html">WeakEventDispatcher</a> <img class="inheritArrow" alt="Inheritance" title="Inheritance" src="../../../images/inherit-arrow.gif"> <a href="../events/ClearableEventDispatcher.html">ClearableEventDispatcher</a> <img class="inheritArrow" alt="Inheritance" title="Inheritance" src="../../../images/inherit-arrow.gif"> flash.events.EventDispatcher</td>
  42. </tr>
  43. <tr>
  44. <td class="classHeaderTableLabel">Implements</td><td><a href="../core/interfaces/ICancelable.html">ICancelable</a>, <a href="../core/interfaces/ICoreInterface.html">ICoreInterface</a></td>
  45. </tr>
  46. </table>
  47. <p></p>
  48. BytesTotalPrefetcher is a class used to determine a files size before loading it.
  49. <p>
  50. Prefetching file size involves a second load process, which is immeadiately cancelled as soon as the file
  51. size is detected. Any loaded data (and reference to it) is discarded. The amount of time a prefetch takes is not determined by the connection speed, but rather
  52. the latency.
  53. </p>
  54. <p></p>
  55. <p>
  56. <span class="classHeaderTableLabel">See also</span>
  57. </p>
  58. <div class="seeAlso">
  59. <a href="../load/BytesTotalPrefetcher.html#byteWaste" target="">byteWaste</a>
  60. </div>
  61. <br>
  62. <hr>
  63. </div>
  64. <a name="propertySummary"></a>
  65. <div class="summarySection">
  66. <div class="summaryTableTitle">Public Properties</div>
  67. <table id="summaryTableProperty" class="summaryTable " cellpadding="3" cellspacing="0">
  68. <tr>
  69. <th>&nbsp;</th><th colspan="2">Property</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
  70. </tr>
  71. <tr class="">
  72. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#prefetchComplete">prefetchComplete</a> : Boolean<div class="summaryTableDescription">[read-only]
  73. Indicates whether the prefetch is complete.</div>
  74. </td><td class="summaryTableOwnerCol">BytesTotalPrefetcher</td>
  75. </tr>
  76. </table>
  77. </div>
  78. <a name="methodSummary"></a>
  79. <div class="summarySection">
  80. <div class="summaryTableTitle">Public Methods</div>
  81. <div class="showHideLinks">
  82. <div class="hideInheritedMethod" id="hideInheritedMethod">
  83. <a onclick="javascript:setInheritedVisible(false,'Method');" href="#methodSummary" class="showHideLink"><img src="../../../images/expanded.gif" class="showHideLinkImage"> Hide Inherited Public Methods</a>
  84. </div>
  85. <div class="showInheritedMethod" id="showInheritedMethod">
  86. <a onclick="javascript:setInheritedVisible(true,'Method');" href="#methodSummary" class="showHideLink"><img src="../../../images/collapsed.gif" class="showHideLinkImage"> Show Inherited Public Methods</a>
  87. </div>
  88. </div>
  89. <table id="summaryTableMethod" class="summaryTable " cellpadding="3" cellspacing="0">
  90. <tr>
  91. <th>&nbsp;</th><th colspan="2">Method</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
  92. </tr>
  93. <tr class="">
  94. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
  95. <div class="summarySignature">
  96. <a class="signatureLink" href="#BytesTotalPrefetcher()">BytesTotalPrefetcher</a>(request:URLRequest)</div>
  97. <div class="summaryTableDescription">
  98. BytesTotalPrefetcher Constructor
  99. </div>
  100. </td><td class="summaryTableOwnerCol">BytesTotalPrefetcher</td>
  101. </tr>
  102. <tr class="hideInheritedMethod">
  103. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
  104. <div class="summarySignature">
  105. <a class="signatureLink" href="../events/WeakEventDispatcher.html#addEventListener()">addEventListener</a>(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = true):void</div>
  106. <div class="summaryTableDescription">
  107. Registers an event listener object with an EventDispatcher object so that the listener receives notification of an event.</div>
  108. </td><td class="summaryTableOwnerCol"><a href="../events/WeakEventDispatcher.html">WeakEventDispatcher</a></td>
  109. </tr>
  110. <tr class="">
  111. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
  112. <div class="summarySignature">
  113. <a class="signatureLink" href="#cancel()">cancel</a>():void</div>
  114. <div class="summaryTableDescription">
  115. Cancels the prefetch.</div>
  116. </td><td class="summaryTableOwnerCol">BytesTotalPrefetcher</td>
  117. </tr>
  118. <tr class="">
  119. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
  120. <div class="summarySignature">
  121. <a class="signatureLink" href="#destruct()">destruct</a>(deepDestruct:Boolean = false):void</div>
  122. <div class="summaryTableDescription">
  123. Destructs implementing instance of specified properties.</div>
  124. </td><td class="summaryTableOwnerCol">BytesTotalPrefetcher</td>
  125. </tr>
  126. <tr class="hideInheritedMethod">
  127. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
  128. <div class="summarySignature">
  129. <a class="signatureLink" href="../events/WeakEventDispatcher.html#dispatchEvent()">dispatchEvent</a>(e:Event):Boolean</div>
  130. <div class="summaryTableDescription">
  131. Dispatches an event into the event flow, <i>only</i> if event property <code>hasEventListener</code> or <code>bubbles</code> are <code>true</code>.</div>
  132. </td><td class="summaryTableOwnerCol"><a href="../events/WeakEventDispatcher.html">WeakEventDispatcher</a></td>
  133. </tr>
  134. <tr class="">
  135. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
  136. <div class="summarySignature">
  137. <a class="signatureLink" href="#getByteWaste()">getByteWaste</a>():uint</div>
  138. <div class="summaryTableDescription">
  139. Returns the number of excess loaded bytes caused by the prefetch.</div>
  140. </td><td class="summaryTableOwnerCol">BytesTotalPrefetcher</td>
  141. </tr>
  142. <tr class="">
  143. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
  144. <div class="summarySignature">
  145. <a class="signatureLink" href="#getPrefetchedBytesTotal()">getPrefetchedBytesTotal</a>():uint</div>
  146. <div class="summaryTableDescription">
  147. Returns the prefetched file size of target file.</div>
  148. </td><td class="summaryTableOwnerCol">BytesTotalPrefetcher</td>
  149. </tr>
  150. <tr class="hideInheritedMethod">
  151. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
  152. <div class="summarySignature">
  153. <a class="signatureLink" href="../events/ClearableEventDispatcher.html#listDestructableProperties()">listDestructableProperties</a>():Array</div>
  154. <div class="summaryTableDescription">
  155. Specifies an array of strings representing properties that are to be
  156. nullified or reset upon destruction.</div>
  157. </td><td class="summaryTableOwnerCol"><a href="../events/ClearableEventDispatcher.html">ClearableEventDispatcher</a></td>
  158. </tr>
  159. <tr class="hideInheritedMethod">
  160. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
  161. <div class="summarySignature">
  162. <a class="signatureLink" href="../events/ClearableEventDispatcher.html#removeAllEventListeners()">removeAllEventListeners</a>():void</div>
  163. <div class="summaryTableDescription">
  164. Removes all event listeners from the IClearableEventDispatcher object.</div>
  165. </td><td class="summaryTableOwnerCol"><a href="../events/ClearableEventDispatcher.html">ClearableEventDispatcher</a></td>
  166. </tr>
  167. <tr class="hideInheritedMethod">
  168. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
  169. <div class="summarySignature">
  170. <a class="signatureLink" href="../events/ClearableEventDispatcher.html#removeEventListener()">removeEventListener</a>(type:String, listener:Function, useCapture:Boolean = false):void</div>
  171. <div class="summaryTableDescription">
  172. Removes a listener from the EventDispatcher object.</div>
  173. </td><td class="summaryTableOwnerCol"><a href="../events/ClearableEventDispatcher.html">ClearableEventDispatcher</a></td>
  174. </tr>
  175. <tr class="hideInheritedMethod">
  176. <td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
  177. <div class="summarySignature">
  178. <a class="signatureLink" href="../events/ClearableEventDispatcher.html#toString()">toString</a>():String</div>
  179. <div class="summaryTableDescription">
  180. Returns the string representation of the specified object.</div>
  181. </td><td class="summaryTableOwnerCol"><a href="../events/ClearableEventDispatcher.html">ClearableEventDispatcher</a></td>
  182. </tr>
  183. </table>
  184. </div>
  185. <script type="text/javascript" language="javascript">
  186. <!--
  187. showHideInherited();
  188. --></script>
  189. <div class="MainContent">
  190. <a name="propertyDetail"></a>
  191. <div class="detailSectionHeader">Property detail</div>
  192. <a name="prefetchComplete"></a>
  193. <table cellspacing="0" cellpadding="0" class="detailHeader">
  194. <tr>
  195. <td class="detailHeaderName">prefetchComplete</td><td class="detailHeaderType">property</td>
  196. </tr>
  197. </table>
  198. <div class="detailBody">
  199. <code>prefetchComplete:Boolean</code>&nbsp;&nbsp;[read-only]<p>
  200. Indicates whether the prefetch is complete.
  201. </p><span class="label">Implementation</span>
  202. <br>
  203. <code>&nbsp;&nbsp;&nbsp;&nbsp;public function get prefetchComplete():Boolean</code>
  204. <br>
  205. </div>
  206. <a name="constructorDetail"></a>
  207. <div class="detailSectionHeader">Constructor detail</div>
  208. <a name="BytesTotalPrefetcher()"></a>
  209. <table cellspacing="0" cellpadding="0" class="detailHeader">
  210. <tr>
  211. <td class="detailHeaderName">BytesTotalPrefetcher</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">constructor</td>
  212. </tr>
  213. </table>
  214. <div class="detailBody">
  215. <code>public function BytesTotalPrefetcher(request:URLRequest)</code><p>
  216. BytesTotalPrefetcher Constructor
  217. </p><span class="label">Parameters</span>
  218. <table border="0" cellspacing="0" cellpadding="0">
  219. <tr>
  220. <td width="20px"></td><td><code><span class="label">request</span>:URLRequest</code> &mdash; URLRequest defining the URL of the file to load.
  221. </td>
  222. </tr>
  223. </table>
  224. </div>
  225. <a name="methodDetail"></a>
  226. <div class="detailSectionHeader">Method detail</div>
  227. <a name="cancel()"></a>
  228. <table cellspacing="0" cellpadding="0" class="detailHeader">
  229. <tr>
  230. <td class="detailHeaderName">cancel</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td>
  231. </tr>
  232. </table>
  233. <div class="detailBody">
  234. <code>public function cancel():void</code><p>
  235. Cancels the prefetch.
  236. </p></div>
  237. <a name="destruct()"></a>
  238. <table cellspacing="0" cellpadding="0" class="detailHeader">
  239. <tr>
  240. <td class="detailHeaderName">destruct</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
  241. </tr>
  242. </table>
  243. <div class="detailBody">
  244. <code>public override function destruct(deepDestruct:Boolean = false):void</code><p>
  245. Destructs implementing instance of specified properties.
  246. <p />
  247. <b>Note:</b> You can override this method to remove unused references in your custom class.
  248. </p><span class="label">Parameters</span>
  249. <table border="0" cellspacing="0" cellpadding="0">
  250. <tr>
  251. <td width="20px"></td><td><code><span class="label">deepDestruct</span>:Boolean</code> (default = <code>false</code>)<code></code></td>
  252. </tr>
  253. </table>
  254. </div>
  255. <a name="getByteWaste()"></a>
  256. <table cellspacing="0" cellpadding="0" class="detailHeader">
  257. <tr>
  258. <td class="detailHeaderName">getByteWaste</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
  259. </tr>
  260. </table>
  261. <div class="detailBody">
  262. <code>public function getByteWaste():uint</code><p>
  263. Returns the number of excess loaded bytes caused by the prefetch.
  264. </p><p>
  265. Note that the file size is fetched as soon as any load progress is detected, no matter how small.
  266. This means that the amount of excess loaded bytes is in direct proportion to the connection speed
  267. between client and server. A slower connection will load less excess amount of data than a fast connection.
  268. </p>
  269. <p></p>
  270. <span class="label">Returns</span>
  271. <table border="0" cellspacing="0" cellpadding="0">
  272. <tr>
  273. <td width="20"></td><td><code>uint</code> &mdash; Excess loaded amount of data in bytes.
  274. </td>
  275. </tr>
  276. </table>
  277. </div>
  278. <a name="getPrefetchedBytesTotal()"></a>
  279. <table cellspacing="0" cellpadding="0" class="detailHeader">
  280. <tr>
  281. <td class="detailHeaderName">getPrefetchedBytesTotal</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
  282. </tr>
  283. </table>
  284. <div class="detailBody">
  285. <code>public function getPrefetchedBytesTotal():uint</code><p>
  286. Returns the prefetched file size of target file.
  287. </p><p></p>
  288. <span class="label">Returns</span>
  289. <table border="0" cellspacing="0" cellpadding="0">
  290. <tr>
  291. <td width="20"></td><td><code>uint</code> &mdash; File size in bytes.
  292. </td>
  293. </tr>
  294. </table>
  295. </div>
  296. <br>
  297. <br>
  298. <hr>
  299. <br>
  300. <p></p>
  301. <center class="copyright">
  302. </center>
  303. </div>
  304. </body>
  305. </html>
  306. <!-- -->