chillerlan-QRCodeTest-Data-ECITest.html 44 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>Documentation</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <base href="../">
  8. <link rel="icon" href="images/favicon.ico"/>
  9. <link rel="stylesheet" href="css/normalize.css">
  10. <link rel="stylesheet" href="css/base.css">
  11. <link rel="preconnect" href="https://fonts.gstatic.com">
  12. <link href="https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@400;600;700&display=swap" rel="stylesheet">
  13. <link href="https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@400;600;700&display=swap" rel="stylesheet">
  14. <link rel="stylesheet" href="css/template.css">
  15. <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.12.0/css/all.min.css" integrity="sha256-ybRkN9dBjhcS2qrW1z+hfCxq+1aBdwyQM5wlQoQVt/0=" crossorigin="anonymous" />
  16. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/themes/prism-okaidia.css">
  17. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.css">
  18. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.css">
  19. <script src="https://cdn.jsdelivr.net/npm/fuse.js@3.4.6"></script>
  20. <script src="https://cdn.jsdelivr.net/npm/css-vars-ponyfill@2"></script>
  21. <script src="js/search.js"></script>
  22. <script defer src="js/searchIndex.js"></script>
  23. </head>
  24. <body id="top">
  25. <header class="phpdocumentor-header phpdocumentor-section">
  26. <h1 class="phpdocumentor-title"><a href="" class="phpdocumentor-title__link">Documentation</a></h1>
  27. <input class="phpdocumentor-header__menu-button" type="checkbox" id="menu-button" name="menu-button" />
  28. <label class="phpdocumentor-header__menu-icon" for="menu-button">
  29. <i class="fas fa-bars"></i>
  30. </label>
  31. <section data-search-form class="phpdocumentor-search">
  32. <label>
  33. <span class="visually-hidden">Search for</span>
  34. <svg class="phpdocumentor-search__icon" width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
  35. <circle cx="7.5" cy="7.5" r="6.5" stroke="currentColor" stroke-width="2"/>
  36. <line x1="12.4892" y1="12.2727" x2="19.1559" y2="18.9393" stroke="currentColor" stroke-width="3"/>
  37. </svg>
  38. <input type="search" class="phpdocumentor-field phpdocumentor-search__field" placeholder="Loading .." disabled />
  39. </label>
  40. </section>
  41. <nav class="phpdocumentor-topnav">
  42. <ul class="phpdocumentor-topnav__menu">
  43. </ul>
  44. </nav>
  45. </header>
  46. <main class="phpdocumentor">
  47. <div class="phpdocumentor-section">
  48. <input class="phpdocumentor-sidebar__menu-button" type="checkbox" id="sidebar-button" name="sidebar-button" />
  49. <label class="phpdocumentor-sidebar__menu-icon" for="sidebar-button">
  50. Menu
  51. </label>
  52. <aside class="phpdocumentor-column -four phpdocumentor-sidebar">
  53. <section class="phpdocumentor-sidebar__category">
  54. <h2 class="phpdocumentor-sidebar__category-header">Namespaces</h2>
  55. <h4 class="phpdocumentor-sidebar__root-namespace">
  56. <a href="namespaces/chillerlan.html" class="">chillerlan</a>
  57. </h4>
  58. <ul class="phpdocumentor-list">
  59. <li>
  60. <a href="namespaces/chillerlan-qrcode.html" class="">QRCode</a>
  61. </li>
  62. <li>
  63. <a href="namespaces/chillerlan-qrcodetest.html" class="">QRCodeTest</a>
  64. </li>
  65. </ul>
  66. </section>
  67. <section class="phpdocumentor-sidebar__category">
  68. <h2 class="phpdocumentor-sidebar__category-header">Packages</h2>
  69. <h4 class="phpdocumentor-sidebar__root-namespace">
  70. <a href="packages/Application.html" class="">Application</a>
  71. </h4>
  72. </section>
  73. <section class="phpdocumentor-sidebar__category">
  74. <h2 class="phpdocumentor-sidebar__category-header">Reports</h2>
  75. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/deprecated.html">Deprecated</a></h3>
  76. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/errors.html">Errors</a></h3>
  77. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/markers.html">Markers</a></h3>
  78. </section>
  79. <section class="phpdocumentor-sidebar__category">
  80. <h2 class="phpdocumentor-sidebar__category-header">Indices</h2>
  81. <h3 class="phpdocumentor-sidebar__root-package"><a href="indices/files.html">Files</a></h3>
  82. </section>
  83. </aside>
  84. <div class="phpdocumentor-column -eight phpdocumentor-content">
  85. <ul class="phpdocumentor-breadcrumbs">
  86. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan.html">chillerlan</a></li>
  87. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcodetest.html">QRCodeTest</a></li>
  88. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcodetest-data.html">Data</a></li>
  89. </ul>
  90. <article class="phpdocumentor-element -class">
  91. <h2 class="phpdocumentor-content__title">
  92. ECITest
  93. <span class="phpdocumentor-element__extends">
  94. extends <abbr title="\PHPUnit\Framework\TestCase">TestCase</abbr>
  95. </span>
  96. <div class="phpdocumentor-element__package">
  97. in package
  98. <ul class="phpdocumentor-breadcrumbs">
  99. <li class="phpdocumentor-breadcrumb"><a href="packages/Application.html">Application</a></li>
  100. </ul>
  101. </div>
  102. </h2>
  103. <aside class="phpdocumentor-element-found-in">
  104. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  105. :
  106. <span class="phpdocumentor-element-found-in__line">21</span>
  107. </aside>
  108. <p class="phpdocumentor-summary">Tests the ECI class</p>
  109. <h3 id="toc">
  110. Table of Contents
  111. <a href="#toc" class="headerlink"><i class="fas fa-link"></i></a>
  112. </h3>
  113. <dl class="phpdocumentor-table-of-contents">
  114. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  115. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#property_QRData">$QRData</a>
  116. <span>
  117. &nbsp;: <a href="classes/chillerlan-QRCode-Data-QRData.html"><abbr title="\chillerlan\QRCode\Data\QRData">QRData</abbr></a> </span>
  118. </dt>
  119. <dd></dd>
  120. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  121. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#property_testdata">$testdata</a>
  122. <span>
  123. &nbsp;: string </span>
  124. </dt>
  125. <dd></dd>
  126. <dt class="phpdocumentor-table-of-contents__entry -property -private">
  127. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#property_testCharset">$testCharset</a>
  128. <span>
  129. &nbsp;: int </span>
  130. </dt>
  131. <dd></dd>
  132. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  133. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_eciCharsetIdProvider">eciCharsetIdProvider()</a>
  134. <span>
  135. &nbsp;: array&lt;string|int, mixed&gt; </span>
  136. </dt>
  137. <dd></dd>
  138. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  139. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testConvertUnknownEncoding">testConvertUnknownEncoding()</a>
  140. <span>
  141. &nbsp;: void </span>
  142. </dt>
  143. <dd>Tests detection of an unknown character set</dd>
  144. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  145. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testDataModeInstance">testDataModeInstance()</a>
  146. <span>
  147. &nbsp;: void </span>
  148. </dt>
  149. <dd></dd>
  150. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  151. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testDecodeECISegmentFollowedByInvalidModeException">testDecodeECISegmentFollowedByInvalidModeException()</a>
  152. <span>
  153. &nbsp;: void </span>
  154. </dt>
  155. <dd>Tests if and exception is thrown when the ECI segment is followed by a mode that is not 8-bit byte</dd>
  156. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  157. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testDecodeSegment">testDecodeSegment()</a>
  158. <span>
  159. &nbsp;: void </span>
  160. </dt>
  161. <dd></dd>
  162. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  163. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testInvalidDataException">testInvalidDataException()</a>
  164. <span>
  165. &nbsp;: void </span>
  166. </dt>
  167. <dd></dd>
  168. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  169. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testInvalidDataOnEmptyException">testInvalidDataOnEmptyException()</a>
  170. <span>
  171. &nbsp;: void </span>
  172. </dt>
  173. <dd>since the ECI class only accepts integer values,
  174. we&#039;ll use this test to check for the upper end of the accepted input range</dd>
  175. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  176. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testReadWrite">testReadWrite()</a>
  177. <span>
  178. &nbsp;: void </span>
  179. </dt>
  180. <dd></dd>
  181. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  182. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_unknownEncodingDataProvider">unknownEncodingDataProvider()</a>
  183. <span>
  184. &nbsp;: array&lt;string|int, mixed&gt; </span>
  185. </dt>
  186. <dd></dd>
  187. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  188. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_versionBreakpointProvider">versionBreakpointProvider()</a>
  189. <span>
  190. &nbsp;: array&lt;string|int, mixed&gt; </span>
  191. </dt>
  192. <dd>returns versions within the version breakpoints 1-9, 10-26 and 27-40</dd>
  193. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  194. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_setUp">setUp()</a>
  195. <span>
  196. &nbsp;: void </span>
  197. </dt>
  198. <dd></dd>
  199. <dt class="phpdocumentor-table-of-contents__entry -method -private">
  200. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_getDataSegments">getDataSegments()</a>
  201. <span>
  202. &nbsp;: array&lt;string|int, mixed&gt; </span>
  203. </dt>
  204. <dd></dd>
  205. </dl>
  206. <section class="phpdocumentor-properties">
  207. <h3 class="phpdocumentor-elements__header" id="properties">
  208. Properties
  209. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#properties" class="headerlink"><i class="fas fa-link"></i></a>
  210. </h3>
  211. <article
  212. class="
  213. phpdocumentor-element
  214. -property
  215. -protected
  216. "
  217. >
  218. <h4 class="phpdocumentor-element__name" id="property_QRData">
  219. $QRData
  220. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#property_QRData" class="headerlink"><i class="fas fa-link"></i></a>
  221. <span class="phpdocumentor-element__modifiers">
  222. </span>
  223. </h4>
  224. <aside class="phpdocumentor-element-found-in">
  225. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  226. :
  227. <span class="phpdocumentor-element-found-in__line">23</span>
  228. </aside>
  229. <code class="phpdocumentor-code phpdocumentor-signature ">
  230. <span class="phpdocumentor-signature__visibility">protected</span>
  231. <span class="phpdocumentor-signature__type"><a href="classes/chillerlan-QRCode-Data-QRData.html"><abbr title="\chillerlan\QRCode\Data\QRData">QRData</abbr></a></span>
  232. <span class="phpdocumentor-signature__name">$QRData</span>
  233. </code>
  234. <section class="phpdocumentor-description"></section>
  235. <section class="phpdocumentor-description"></section>
  236. </article>
  237. <article
  238. class="
  239. phpdocumentor-element
  240. -property
  241. -protected
  242. "
  243. >
  244. <h4 class="phpdocumentor-element__name" id="property_testdata">
  245. $testdata
  246. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#property_testdata" class="headerlink"><i class="fas fa-link"></i></a>
  247. <span class="phpdocumentor-element__modifiers">
  248. </span>
  249. </h4>
  250. <aside class="phpdocumentor-element-found-in">
  251. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  252. :
  253. <span class="phpdocumentor-element-found-in__line">24</span>
  254. </aside>
  255. <code class="phpdocumentor-code phpdocumentor-signature ">
  256. <span class="phpdocumentor-signature__visibility">protected</span>
  257. <span class="phpdocumentor-signature__type">string</span>
  258. <span class="phpdocumentor-signature__name">$testdata</span>
  259. = <span class="phpdocumentor-signature__default-value">&#039;无可奈何燃花作香&#039;</span></code>
  260. <section class="phpdocumentor-description"></section>
  261. <section class="phpdocumentor-description"></section>
  262. </article>
  263. <article
  264. class="
  265. phpdocumentor-element
  266. -property
  267. -private
  268. "
  269. >
  270. <h4 class="phpdocumentor-element__name" id="property_testCharset">
  271. $testCharset
  272. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#property_testCharset" class="headerlink"><i class="fas fa-link"></i></a>
  273. <span class="phpdocumentor-element__modifiers">
  274. </span>
  275. </h4>
  276. <aside class="phpdocumentor-element-found-in">
  277. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  278. :
  279. <span class="phpdocumentor-element-found-in__line">25</span>
  280. </aside>
  281. <code class="phpdocumentor-code phpdocumentor-signature ">
  282. <span class="phpdocumentor-signature__visibility">private</span>
  283. <span class="phpdocumentor-signature__type">int</span>
  284. <span class="phpdocumentor-signature__name">$testCharset</span>
  285. = <span class="phpdocumentor-signature__default-value">\chillerlan\QRCode\Common\ECICharset::GB18030</span></code>
  286. <section class="phpdocumentor-description"></section>
  287. <section class="phpdocumentor-description"></section>
  288. </article>
  289. </section>
  290. <section class="phpdocumentor-methods">
  291. <h3 class="phpdocumentor-elements__header" id="methods">
  292. Methods
  293. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#methods" class="headerlink"><i class="fas fa-link"></i></a>
  294. </h3>
  295. <article
  296. class="phpdocumentor-element
  297. -method
  298. -public
  299. -static "
  300. >
  301. <h4 class="phpdocumentor-element__name" id="method_eciCharsetIdProvider">
  302. eciCharsetIdProvider()
  303. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_eciCharsetIdProvider" class="headerlink"><i class="fas fa-link"></i></a>
  304. </h4>
  305. <aside class="phpdocumentor-element-found-in">
  306. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  307. :
  308. <span class="phpdocumentor-element-found-in__line">94</span>
  309. </aside>
  310. <code class="phpdocumentor-code phpdocumentor-signature ">
  311. <span class="phpdocumentor-signature__visibility">public</span>
  312. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">eciCharsetIdProvider</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span></code>
  313. <section class="phpdocumentor-description"></section>
  314. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  315. <span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span>
  316. &mdash;
  317. </article>
  318. <article
  319. class="phpdocumentor-element
  320. -method
  321. -public
  322. "
  323. >
  324. <h4 class="phpdocumentor-element__name" id="method_testConvertUnknownEncoding">
  325. testConvertUnknownEncoding()
  326. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testConvertUnknownEncoding" class="headerlink"><i class="fas fa-link"></i></a>
  327. </h4>
  328. <aside class="phpdocumentor-element-found-in">
  329. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  330. :
  331. <span class="phpdocumentor-element-found-in__line">148</span>
  332. </aside>
  333. <p class="phpdocumentor-summary">Tests detection of an unknown character set</p>
  334. <code class="phpdocumentor-code phpdocumentor-signature ">
  335. <span class="phpdocumentor-signature__visibility">public</span>
  336. <span class="phpdocumentor-signature__name">testConvertUnknownEncoding</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$id</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$data</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  337. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  338. <dl class="phpdocumentor-argument-list">
  339. <dt class="phpdocumentor-argument-list__entry">
  340. <span class="phpdocumentor-signature__argument__name">$id</span>
  341. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  342. </dt>
  343. <dd class="phpdocumentor-argument-list__definition">
  344. <section class="phpdocumentor-description"></section>
  345. </dd>
  346. <dt class="phpdocumentor-argument-list__entry">
  347. <span class="phpdocumentor-signature__argument__name">$data</span>
  348. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  349. </dt>
  350. <dd class="phpdocumentor-argument-list__definition">
  351. <section class="phpdocumentor-description"></section>
  352. </dd>
  353. </dl>
  354. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  355. Tags
  356. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  357. </h5>
  358. <dl class="phpdocumentor-tag-list">
  359. <dt class="phpdocumentor-tag-list__entry">
  360. <span class="phpdocumentor-tag__name">dataProvider</span>
  361. </dt>
  362. <dd class="phpdocumentor-tag-list__definition">
  363. <section class="phpdocumentor-description"><p>unknownEncodingDataProvider</p>
  364. </section>
  365. </dd>
  366. </dl>
  367. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  368. <span class="phpdocumentor-signature__response_type">void</span>
  369. &mdash;
  370. </article>
  371. <article
  372. class="phpdocumentor-element
  373. -method
  374. -public
  375. "
  376. >
  377. <h4 class="phpdocumentor-element__name" id="method_testDataModeInstance">
  378. testDataModeInstance()
  379. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testDataModeInstance" class="headerlink"><i class="fas fa-link"></i></a>
  380. </h4>
  381. <aside class="phpdocumentor-element-found-in">
  382. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  383. :
  384. <span class="phpdocumentor-element-found-in__line">39</span>
  385. </aside>
  386. <code class="phpdocumentor-code phpdocumentor-signature ">
  387. <span class="phpdocumentor-signature__visibility">public</span>
  388. <span class="phpdocumentor-signature__name">testDataModeInstance</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  389. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  390. Tags
  391. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  392. </h5>
  393. <dl class="phpdocumentor-tag-list">
  394. <dt class="phpdocumentor-tag-list__entry">
  395. <span class="phpdocumentor-tag__name">inheritDoc</span>
  396. </dt>
  397. <dd class="phpdocumentor-tag-list__definition">
  398. </dd>
  399. </dl>
  400. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  401. <span class="phpdocumentor-signature__response_type">void</span>
  402. &mdash;
  403. </article>
  404. <article
  405. class="phpdocumentor-element
  406. -method
  407. -public
  408. "
  409. >
  410. <h4 class="phpdocumentor-element__name" id="method_testDecodeECISegmentFollowedByInvalidModeException">
  411. testDecodeECISegmentFollowedByInvalidModeException()
  412. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testDecodeECISegmentFollowedByInvalidModeException" class="headerlink"><i class="fas fa-link"></i></a>
  413. </h4>
  414. <aside class="phpdocumentor-element-found-in">
  415. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  416. :
  417. <span class="phpdocumentor-element-found-in__line">120</span>
  418. </aside>
  419. <p class="phpdocumentor-summary">Tests if and exception is thrown when the ECI segment is followed by a mode that is not 8-bit byte</p>
  420. <code class="phpdocumentor-code phpdocumentor-signature ">
  421. <span class="phpdocumentor-signature__visibility">public</span>
  422. <span class="phpdocumentor-signature__name">testDecodeECISegmentFollowedByInvalidModeException</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  423. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  424. <span class="phpdocumentor-signature__response_type">void</span>
  425. &mdash;
  426. </article>
  427. <article
  428. class="phpdocumentor-element
  429. -method
  430. -public
  431. "
  432. >
  433. <h4 class="phpdocumentor-element__name" id="method_testDecodeSegment">
  434. testDecodeSegment()
  435. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testDecodeSegment" class="headerlink"><i class="fas fa-link"></i></a>
  436. </h4>
  437. <aside class="phpdocumentor-element-found-in">
  438. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  439. :
  440. <span class="phpdocumentor-element-found-in__line">56</span>
  441. </aside>
  442. <code class="phpdocumentor-code phpdocumentor-signature ">
  443. <span class="phpdocumentor-signature__visibility">public</span>
  444. <span class="phpdocumentor-signature__name">testDecodeSegment</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$version</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  445. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  446. <dl class="phpdocumentor-argument-list">
  447. <dt class="phpdocumentor-argument-list__entry">
  448. <span class="phpdocumentor-signature__argument__name">$version</span>
  449. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  450. </dt>
  451. <dd class="phpdocumentor-argument-list__definition">
  452. <section class="phpdocumentor-description"></section>
  453. </dd>
  454. </dl>
  455. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  456. Tags
  457. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  458. </h5>
  459. <dl class="phpdocumentor-tag-list">
  460. <dt class="phpdocumentor-tag-list__entry">
  461. <span class="phpdocumentor-tag__name">inheritDoc</span>
  462. </dt>
  463. <dd class="phpdocumentor-tag-list__definition">
  464. </dd>
  465. <dt class="phpdocumentor-tag-list__entry">
  466. <span class="phpdocumentor-tag__name">dataProvider</span>
  467. </dt>
  468. <dd class="phpdocumentor-tag-list__definition">
  469. <section class="phpdocumentor-description"><p>versionBreakpointProvider</p>
  470. </section>
  471. </dd>
  472. </dl>
  473. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  474. <span class="phpdocumentor-signature__response_type">void</span>
  475. &mdash;
  476. </article>
  477. <article
  478. class="phpdocumentor-element
  479. -method
  480. -public
  481. "
  482. >
  483. <h4 class="phpdocumentor-element__name" id="method_testInvalidDataException">
  484. testInvalidDataException()
  485. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testInvalidDataException" class="headerlink"><i class="fas fa-link"></i></a>
  486. </h4>
  487. <aside class="phpdocumentor-element-found-in">
  488. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  489. :
  490. <span class="phpdocumentor-element-found-in__line">74</span>
  491. </aside>
  492. <code class="phpdocumentor-code phpdocumentor-signature ">
  493. <span class="phpdocumentor-signature__visibility">public</span>
  494. <span class="phpdocumentor-signature__name">testInvalidDataException</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  495. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  496. Tags
  497. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  498. </h5>
  499. <dl class="phpdocumentor-tag-list">
  500. <dt class="phpdocumentor-tag-list__entry">
  501. <span class="phpdocumentor-tag__name">inheritDoc</span>
  502. </dt>
  503. <dd class="phpdocumentor-tag-list__definition">
  504. </dd>
  505. </dl>
  506. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  507. <span class="phpdocumentor-signature__response_type">void</span>
  508. &mdash;
  509. </article>
  510. <article
  511. class="phpdocumentor-element
  512. -method
  513. -public
  514. "
  515. >
  516. <h4 class="phpdocumentor-element__name" id="method_testInvalidDataOnEmptyException">
  517. testInvalidDataOnEmptyException()
  518. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testInvalidDataOnEmptyException" class="headerlink"><i class="fas fa-link"></i></a>
  519. </h4>
  520. <aside class="phpdocumentor-element-found-in">
  521. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  522. :
  523. <span class="phpdocumentor-element-found-in__line">87</span>
  524. </aside>
  525. <p class="phpdocumentor-summary">since the ECI class only accepts integer values,
  526. we&#039;ll use this test to check for the upper end of the accepted input range</p>
  527. <code class="phpdocumentor-code phpdocumentor-signature ">
  528. <span class="phpdocumentor-signature__visibility">public</span>
  529. <span class="phpdocumentor-signature__name">testInvalidDataOnEmptyException</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  530. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  531. Tags
  532. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  533. </h5>
  534. <dl class="phpdocumentor-tag-list">
  535. <dt class="phpdocumentor-tag-list__entry">
  536. <span class="phpdocumentor-tag__name">inheritDoc</span>
  537. </dt>
  538. <dd class="phpdocumentor-tag-list__definition">
  539. </dd>
  540. </dl>
  541. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  542. <span class="phpdocumentor-signature__response_type">void</span>
  543. &mdash;
  544. </article>
  545. <article
  546. class="phpdocumentor-element
  547. -method
  548. -public
  549. "
  550. >
  551. <h4 class="phpdocumentor-element__name" id="method_testReadWrite">
  552. testReadWrite()
  553. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_testReadWrite" class="headerlink"><i class="fas fa-link"></i></a>
  554. </h4>
  555. <aside class="phpdocumentor-element-found-in">
  556. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  557. :
  558. <span class="phpdocumentor-element-found-in__line">108</span>
  559. </aside>
  560. <code class="phpdocumentor-code phpdocumentor-signature ">
  561. <span class="phpdocumentor-signature__visibility">public</span>
  562. <span class="phpdocumentor-signature__name">testReadWrite</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$id</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$lengthInBits</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  563. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  564. <dl class="phpdocumentor-argument-list">
  565. <dt class="phpdocumentor-argument-list__entry">
  566. <span class="phpdocumentor-signature__argument__name">$id</span>
  567. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  568. </dt>
  569. <dd class="phpdocumentor-argument-list__definition">
  570. <section class="phpdocumentor-description"></section>
  571. </dd>
  572. <dt class="phpdocumentor-argument-list__entry">
  573. <span class="phpdocumentor-signature__argument__name">$lengthInBits</span>
  574. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  575. </dt>
  576. <dd class="phpdocumentor-argument-list__definition">
  577. <section class="phpdocumentor-description"></section>
  578. </dd>
  579. </dl>
  580. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  581. Tags
  582. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  583. </h5>
  584. <dl class="phpdocumentor-tag-list">
  585. <dt class="phpdocumentor-tag-list__entry">
  586. <span class="phpdocumentor-tag__name">dataProvider</span>
  587. </dt>
  588. <dd class="phpdocumentor-tag-list__definition">
  589. <section class="phpdocumentor-description"><p>eciCharsetIdProvider</p>
  590. </section>
  591. </dd>
  592. </dl>
  593. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  594. <span class="phpdocumentor-signature__response_type">void</span>
  595. &mdash;
  596. </article>
  597. <article
  598. class="phpdocumentor-element
  599. -method
  600. -public
  601. "
  602. >
  603. <h4 class="phpdocumentor-element__name" id="method_unknownEncodingDataProvider">
  604. unknownEncodingDataProvider()
  605. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_unknownEncodingDataProvider" class="headerlink"><i class="fas fa-link"></i></a>
  606. </h4>
  607. <aside class="phpdocumentor-element-found-in">
  608. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  609. :
  610. <span class="phpdocumentor-element-found-in__line">136</span>
  611. </aside>
  612. <code class="phpdocumentor-code phpdocumentor-signature ">
  613. <span class="phpdocumentor-signature__visibility">public</span>
  614. <span class="phpdocumentor-signature__name">unknownEncodingDataProvider</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span></code>
  615. <section class="phpdocumentor-description"></section>
  616. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  617. <span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span>
  618. &mdash;
  619. </article>
  620. <article
  621. class="phpdocumentor-element
  622. -method
  623. -public
  624. -static "
  625. >
  626. <h4 class="phpdocumentor-element__name" id="method_versionBreakpointProvider">
  627. versionBreakpointProvider()
  628. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_versionBreakpointProvider" class="headerlink"><i class="fas fa-link"></i></a>
  629. </h4>
  630. <aside class="phpdocumentor-element-found-in">
  631. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  632. :
  633. <span class="phpdocumentor-element-found-in__line">48</span>
  634. </aside>
  635. <p class="phpdocumentor-summary">returns versions within the version breakpoints 1-9, 10-26 and 27-40</p>
  636. <code class="phpdocumentor-code phpdocumentor-signature ">
  637. <span class="phpdocumentor-signature__visibility">public</span>
  638. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">versionBreakpointProvider</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span></code>
  639. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  640. <span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span>
  641. &mdash;
  642. </article>
  643. <article
  644. class="phpdocumentor-element
  645. -method
  646. -protected
  647. "
  648. >
  649. <h4 class="phpdocumentor-element__name" id="method_setUp">
  650. setUp()
  651. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_setUp" class="headerlink"><i class="fas fa-link"></i></a>
  652. </h4>
  653. <aside class="phpdocumentor-element-found-in">
  654. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  655. :
  656. <span class="phpdocumentor-element-found-in__line">27</span>
  657. </aside>
  658. <code class="phpdocumentor-code phpdocumentor-signature ">
  659. <span class="phpdocumentor-signature__visibility">protected</span>
  660. <span class="phpdocumentor-signature__name">setUp</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  661. <section class="phpdocumentor-description"></section>
  662. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  663. <span class="phpdocumentor-signature__response_type">void</span>
  664. &mdash;
  665. </article>
  666. <article
  667. class="phpdocumentor-element
  668. -method
  669. -private
  670. "
  671. >
  672. <h4 class="phpdocumentor-element__name" id="method_getDataSegments">
  673. getDataSegments()
  674. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#method_getDataSegments" class="headerlink"><i class="fas fa-link"></i></a>
  675. </h4>
  676. <aside class="phpdocumentor-element-found-in">
  677. <abbr class="phpdocumentor-element-found-in__file" title="tests/Data/ECITest.php"><a href="files/tests-data-ecitest.html"><abbr title="tests/Data/ECITest.php">ECITest.php</abbr></a></abbr>
  678. :
  679. <span class="phpdocumentor-element-found-in__line">31</span>
  680. </aside>
  681. <code class="phpdocumentor-code phpdocumentor-signature ">
  682. <span class="phpdocumentor-signature__visibility">private</span>
  683. <span class="phpdocumentor-signature__name">getDataSegments</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span></code>
  684. <section class="phpdocumentor-description"></section>
  685. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  686. <span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span>
  687. &mdash;
  688. </article>
  689. </section>
  690. <script type="text/javascript">
  691. function loadExternalCodeSnippets(line) {
  692. Array.prototype.slice.call(document.querySelectorAll('pre[data-src]')).forEach((pre) => {
  693. var src = pre.getAttribute('data-src').replace( /\\/g, '/');
  694. var extension = (src.match(/\.(\w+)$/) || [, ''])[1];
  695. var language = 'php';
  696. var code = document.createElement('code');
  697. code.className = 'language-' + language;
  698. pre.textContent = '';
  699. pre.setAttribute('data-line', line)
  700. code.textContent = 'Loading…';
  701. pre.appendChild(code);
  702. var xhr = new XMLHttpRequest();
  703. xhr.open('GET', src, true);
  704. xhr.onreadystatechange = function () {
  705. if (xhr.readyState == 4) {
  706. if (xhr.status < 400 && xhr.responseText) {
  707. code.textContent = xhr.responseText;
  708. Prism.highlightElement(code);
  709. }
  710. else if (xhr.status >= 400) {
  711. code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
  712. }
  713. else {
  714. code.textContent = '✖ Error: File does not exist, is empty or trying to view from localhost';
  715. }
  716. }
  717. };
  718. xhr.send(null);
  719. });
  720. }
  721. var modals = document.querySelectorAll("[data-modal]");
  722. modals.forEach(function (trigger) {
  723. trigger.addEventListener("click", function (event) {
  724. //event.preventDefault();
  725. const modal = document.getElementById(trigger.dataset.modal);
  726. modal.classList.add("phpdocumentor-modal__open");
  727. loadExternalCodeSnippets(trigger.dataset.line)
  728. const exits = modal.querySelectorAll("[data-exit-button]");
  729. exits.forEach(function (exit) {
  730. exit.addEventListener("click", function (event) {
  731. event.preventDefault();
  732. modal.classList.remove("phpdocumentor-modal__open");
  733. });
  734. });
  735. });
  736. });
  737. </script>
  738. </article>
  739. <section data-search-results class="phpdocumentor-search-results phpdocumentor-search-results--hidden">
  740. <section class="phpdocumentor-search-results__dialog">
  741. <header class="phpdocumentor-search-results__header">
  742. <h2 class="phpdocumentor-search-results__title">Search results</h2>
  743. <button class="phpdocumentor-search-results__close"><i class="fas fa-times"></i></button>
  744. </header>
  745. <section class="phpdocumentor-search-results__body">
  746. <ul class="phpdocumentor-search-results__entries"></ul>
  747. </section>
  748. </section>
  749. </section>
  750. </div>
  751. </div>
  752. <a href="classes/chillerlan-QRCodeTest-Data-ECITest.html#top" class="phpdocumentor-back-to-top"><i class="fas fa-chevron-circle-up"></i></a>
  753. </main>
  754. <script>
  755. cssVars({});
  756. </script>
  757. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/prism.min.js"></script>
  758. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/autoloader/prism-autoloader.min.js"></script>
  759. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.min.js"></script>
  760. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.min.js"></script>
  761. </body>
  762. </html>