chillerlan-QRCode-Data-Number.html 43 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919
  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-qrcode.html">QRCode</a></li>
  88. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcode-data.html">Data</a></li>
  89. </ul>
  90. <article class="phpdocumentor-element -class">
  91. <h2 class="phpdocumentor-content__title">
  92. Number
  93. <span class="phpdocumentor-element__extends">
  94. extends <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html"><abbr title="\chillerlan\QRCode\Data\QRDataModeAbstract">QRDataModeAbstract</abbr></a>
  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="src/Data/Number.php"><a href="files/src-data-number.html"><abbr title="src/Data/Number.php">Number.php</abbr></a></abbr>
  105. :
  106. <span class="phpdocumentor-element-found-in__line">23</span>
  107. </aside>
  108. <p class="phpdocumentor-summary">Numeric mode: decimal digits 0 to 9</p>
  109. <section class="phpdocumentor-description"><p>ISO/IEC 18004:2000 Section 8.3.2
  110. ISO/IEC 18004:2000 Section 8.4.2</p>
  111. </section>
  112. <h3 id="toc">
  113. Table of Contents
  114. <a href="#toc" class="headerlink"><i class="fas fa-link"></i></a>
  115. </h3>
  116. <dl class="phpdocumentor-table-of-contents">
  117. <dt class="phpdocumentor-table-of-contents__entry -constant -public">
  118. <a href="classes/chillerlan-QRCode-Data-Number.html#constant_DATAMODE">DATAMODE</a>
  119. <span>
  120. &nbsp;= \chillerlan\QRCode\Common\Mode::NUMBER </span>
  121. </dt>
  122. <dd></dd>
  123. <dt class="phpdocumentor-table-of-contents__entry -constant -private">
  124. <a href="classes/chillerlan-QRCode-Data-Number.html#constant_NUMBER_TO_ORD">NUMBER_TO_ORD</a>
  125. <span>
  126. &nbsp;= [&#039;0&#039; =&gt; 0, &#039;1&#039; =&gt; 1, &#039;2&#039; =&gt; 2, &#039;3&#039; =&gt; 3, &#039;4&#039; =&gt; 4, &#039;5&#039; =&gt; 5, &#039;6&#039; =&gt; 6, &#039;7&#039; =&gt; 7, &#039;8&#039; =&gt; 8, &#039;9&#039; =&gt; 9] </span>
  127. </dt>
  128. <dd></dd>
  129. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  130. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#property_data">$data</a>
  131. <span>
  132. &nbsp;: string </span>
  133. </dt>
  134. <dd>The data to write</dd>
  135. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  136. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method___construct">__construct()</a>
  137. <span>
  138. &nbsp;: mixed </span>
  139. </dt>
  140. <dd>QRDataModeAbstract constructor.</dd>
  141. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  142. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_convertEncoding">convertEncoding()</a>
  143. <span>
  144. &nbsp;: string </span>
  145. </dt>
  146. <dd>encoding conversion helper</dd>
  147. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  148. <a href="classes/chillerlan-QRCode-Data-Number.html#method_decodeSegment">decodeSegment()</a>
  149. <span>
  150. &nbsp;: string </span>
  151. </dt>
  152. <dd></dd>
  153. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  154. <a href="classes/chillerlan-QRCode-Data-Number.html#method_getLengthInBits">getLengthInBits()</a>
  155. <span>
  156. &nbsp;: int </span>
  157. </dt>
  158. <dd></dd>
  159. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  160. <a href="classes/chillerlan-QRCode-Data-Number.html#method_validateString">validateString()</a>
  161. <span>
  162. &nbsp;: bool </span>
  163. </dt>
  164. <dd></dd>
  165. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  166. <a href="classes/chillerlan-QRCode-Data-Number.html#method_write">write()</a>
  167. <span>
  168. &nbsp;: <a href="classes/chillerlan-QRCode-Data-QRDataModeInterface.html"><abbr title="\chillerlan\QRCode\Data\QRDataModeInterface">QRDataModeInterface</abbr></a> </span>
  169. </dt>
  170. <dd></dd>
  171. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  172. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getCharCount">getCharCount()</a>
  173. <span>
  174. &nbsp;: int </span>
  175. </dt>
  176. <dd>returns the character count of the $data string</dd>
  177. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  178. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getLengthBits">getLengthBits()</a>
  179. <span>
  180. &nbsp;: int </span>
  181. </dt>
  182. <dd>shortcut</dd>
  183. <dt class="phpdocumentor-table-of-contents__entry -method -private">
  184. <a href="classes/chillerlan-QRCode-Data-Number.html#method_parseInt">parseInt()</a>
  185. <span>
  186. &nbsp;: int </span>
  187. </dt>
  188. <dd>get the code for the given numeric string</dd>
  189. </dl>
  190. <section class="phpdocumentor-constants">
  191. <h3 class="phpdocumentor-elements__header" id="constants">
  192. Constants
  193. <a href="classes/chillerlan-QRCode-Data-Number.html#constants" class="headerlink"><i class="fas fa-link"></i></a>
  194. </h3>
  195. <article class="phpdocumentor-element -constant -public ">
  196. <h4 class="phpdocumentor-element__name" id="constant_DATAMODE">
  197. DATAMODE
  198. <a href="classes/chillerlan-QRCode-Data-Number.html#constant_DATAMODE" class="headerlink"><i class="fas fa-link"></i></a>
  199. </h4>
  200. <aside class="phpdocumentor-element-found-in">
  201. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/Number.php"><a href="files/src-data-number.html"><abbr title="src/Data/Number.php">Number.php</abbr></a></abbr>
  202. :
  203. <span class="phpdocumentor-element-found-in__line">35</span>
  204. </aside>
  205. <code class="phpdocumentor-signature phpdocumentor-code ">
  206. <span class="phpdocumentor-signature__visibility">public</span>
  207. <span class="phpdocumentor-signature__type">mixed</span>
  208. <span class="phpdocumentor-signature__name">DATAMODE</span>
  209. = <span class="phpdocumentor-signature__default-value">\chillerlan\QRCode\Common\Mode::NUMBER</span>
  210. </code>
  211. <section class="phpdocumentor-description"></section>
  212. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  213. Tags
  214. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  215. </h5>
  216. <dl class="phpdocumentor-tag-list">
  217. <dt class="phpdocumentor-tag-list__entry">
  218. <span class="phpdocumentor-tag__name">inheritDoc</span>
  219. </dt>
  220. <dd class="phpdocumentor-tag-list__definition">
  221. </dd>
  222. </dl>
  223. </article>
  224. <article class="phpdocumentor-element -constant -private ">
  225. <h4 class="phpdocumentor-element__name" id="constant_NUMBER_TO_ORD">
  226. NUMBER_TO_ORD
  227. <a href="classes/chillerlan-QRCode-Data-Number.html#constant_NUMBER_TO_ORD" class="headerlink"><i class="fas fa-link"></i></a>
  228. </h4>
  229. <aside class="phpdocumentor-element-found-in">
  230. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/Number.php"><a href="files/src-data-number.html"><abbr title="src/Data/Number.php">Number.php</abbr></a></abbr>
  231. :
  232. <span class="phpdocumentor-element-found-in__line">28</span>
  233. </aside>
  234. <code class="phpdocumentor-signature phpdocumentor-code ">
  235. <span class="phpdocumentor-signature__visibility">private</span>
  236. <span class="phpdocumentor-signature__type">array&lt;string|int, int&gt;</span>
  237. <span class="phpdocumentor-signature__name">NUMBER_TO_ORD</span>
  238. = <span class="phpdocumentor-signature__default-value">[&#039;0&#039; =&gt; 0, &#039;1&#039; =&gt; 1, &#039;2&#039; =&gt; 2, &#039;3&#039; =&gt; 3, &#039;4&#039; =&gt; 4, &#039;5&#039; =&gt; 5, &#039;6&#039; =&gt; 6, &#039;7&#039; =&gt; 7, &#039;8&#039; =&gt; 8, &#039;9&#039; =&gt; 9]</span>
  239. </code>
  240. </article>
  241. </section>
  242. <section class="phpdocumentor-properties">
  243. <h3 class="phpdocumentor-elements__header" id="properties">
  244. Properties
  245. <a href="classes/chillerlan-QRCode-Data-Number.html#properties" class="headerlink"><i class="fas fa-link"></i></a>
  246. </h3>
  247. <article
  248. class="
  249. phpdocumentor-element
  250. -property
  251. -protected
  252. "
  253. >
  254. <h4 class="phpdocumentor-element__name" id="property_data">
  255. $data
  256. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#property_data" class="headerlink"><i class="fas fa-link"></i></a>
  257. <span class="phpdocumentor-element__modifiers">
  258. </span>
  259. </h4>
  260. <aside class="phpdocumentor-element-found-in">
  261. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/QRDataModeAbstract.php"><a href="files/src-data-qrdatamodeabstract.html"><abbr title="src/Data/QRDataModeAbstract.php">QRDataModeAbstract.php</abbr></a></abbr>
  262. :
  263. <span class="phpdocumentor-element-found-in__line">23</span>
  264. </aside>
  265. <p class="phpdocumentor-summary">The data to write</p>
  266. <code class="phpdocumentor-code phpdocumentor-signature ">
  267. <span class="phpdocumentor-signature__visibility">protected</span>
  268. <span class="phpdocumentor-signature__type">string</span>
  269. <span class="phpdocumentor-signature__name">$data</span>
  270. </code>
  271. <section class="phpdocumentor-description"></section>
  272. </article>
  273. </section>
  274. <section class="phpdocumentor-methods">
  275. <h3 class="phpdocumentor-elements__header" id="methods">
  276. Methods
  277. <a href="classes/chillerlan-QRCode-Data-Number.html#methods" class="headerlink"><i class="fas fa-link"></i></a>
  278. </h3>
  279. <article
  280. class="phpdocumentor-element
  281. -method
  282. -public
  283. "
  284. >
  285. <h4 class="phpdocumentor-element__name" id="method___construct">
  286. __construct()
  287. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method___construct" class="headerlink"><i class="fas fa-link"></i></a>
  288. </h4>
  289. <aside class="phpdocumentor-element-found-in">
  290. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/QRDataModeAbstract.php"><a href="files/src-data-qrdatamodeabstract.html"><abbr title="src/Data/QRDataModeAbstract.php">QRDataModeAbstract.php</abbr></a></abbr>
  291. :
  292. <span class="phpdocumentor-element-found-in__line">30</span>
  293. </aside>
  294. <p class="phpdocumentor-summary">QRDataModeAbstract constructor.</p>
  295. <code class="phpdocumentor-code phpdocumentor-signature ">
  296. <span class="phpdocumentor-signature__visibility">public</span>
  297. <span class="phpdocumentor-signature__name">__construct</span><span>(</span><span class="phpdocumentor-signature__argument"><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">mixed</span></code>
  298. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  299. <dl class="phpdocumentor-argument-list">
  300. <dt class="phpdocumentor-argument-list__entry">
  301. <span class="phpdocumentor-signature__argument__name">$data</span>
  302. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  303. </dt>
  304. <dd class="phpdocumentor-argument-list__definition">
  305. <section class="phpdocumentor-description"></section>
  306. </dd>
  307. </dl>
  308. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  309. Tags
  310. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  311. </h5>
  312. <dl class="phpdocumentor-tag-list">
  313. <dt class="phpdocumentor-tag-list__entry">
  314. <span class="phpdocumentor-tag__name">throws</span>
  315. </dt>
  316. <dd class="phpdocumentor-tag-list__definition">
  317. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Data-QRCodeDataException.html"><abbr title="\chillerlan\QRCode\Data\QRCodeDataException">QRCodeDataException</abbr></a></span>
  318. </dd>
  319. </dl>
  320. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  321. <span class="phpdocumentor-signature__response_type">mixed</span>
  322. &mdash;
  323. </article>
  324. <article
  325. class="phpdocumentor-element
  326. -method
  327. -public
  328. -static "
  329. >
  330. <h4 class="phpdocumentor-element__name" id="method_convertEncoding">
  331. convertEncoding()
  332. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_convertEncoding" class="headerlink"><i class="fas fa-link"></i></a>
  333. </h4>
  334. <aside class="phpdocumentor-element-found-in">
  335. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/QRDataModeAbstract.php"><a href="files/src-data-qrdatamodeabstract.html"><abbr title="src/Data/QRDataModeAbstract.php">QRDataModeAbstract.php</abbr></a></abbr>
  336. :
  337. <span class="phpdocumentor-element-found-in__line">50</span>
  338. </aside>
  339. <p class="phpdocumentor-summary">encoding conversion helper</p>
  340. <code class="phpdocumentor-code phpdocumentor-signature ">
  341. <span class="phpdocumentor-signature__visibility">public</span>
  342. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">convertEncoding</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$string</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
  343. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  344. <dl class="phpdocumentor-argument-list">
  345. <dt class="phpdocumentor-argument-list__entry">
  346. <span class="phpdocumentor-signature__argument__name">$string</span>
  347. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  348. </dt>
  349. <dd class="phpdocumentor-argument-list__definition">
  350. <section class="phpdocumentor-description"></section>
  351. </dd>
  352. </dl>
  353. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  354. Tags
  355. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  356. </h5>
  357. <dl class="phpdocumentor-tag-list">
  358. <dt class="phpdocumentor-tag-list__entry">
  359. <span class="phpdocumentor-tag__name">inheritDoc</span>
  360. </dt>
  361. <dd class="phpdocumentor-tag-list__definition">
  362. </dd>
  363. </dl>
  364. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  365. <span class="phpdocumentor-signature__response_type">string</span>
  366. &mdash;
  367. </article>
  368. <article
  369. class="phpdocumentor-element
  370. -method
  371. -public
  372. -static "
  373. >
  374. <h4 class="phpdocumentor-element__name" id="method_decodeSegment">
  375. decodeSegment()
  376. <a href="classes/chillerlan-QRCode-Data-Number.html#method_decodeSegment" class="headerlink"><i class="fas fa-link"></i></a>
  377. </h4>
  378. <aside class="phpdocumentor-element-found-in">
  379. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/Number.php"><a href="files/src-data-number.html"><abbr title="src/Data/Number.php">Number.php</abbr></a></abbr>
  380. :
  381. <span class="phpdocumentor-element-found-in__line">115</span>
  382. </aside>
  383. <code class="phpdocumentor-code phpdocumentor-signature ">
  384. <span class="phpdocumentor-signature__visibility">public</span>
  385. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">decodeSegment</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Common-BitBuffer.html"><abbr title="\chillerlan\QRCode\Common\BitBuffer">BitBuffer</abbr></a>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$bitBuffer</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">$versionNumber</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
  386. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  387. <dl class="phpdocumentor-argument-list">
  388. <dt class="phpdocumentor-argument-list__entry">
  389. <span class="phpdocumentor-signature__argument__name">$bitBuffer</span>
  390. : <span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Common-BitBuffer.html"><abbr title="\chillerlan\QRCode\Common\BitBuffer">BitBuffer</abbr></a></span>
  391. </dt>
  392. <dd class="phpdocumentor-argument-list__definition">
  393. <section class="phpdocumentor-description"></section>
  394. </dd>
  395. <dt class="phpdocumentor-argument-list__entry">
  396. <span class="phpdocumentor-signature__argument__name">$versionNumber</span>
  397. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  398. </dt>
  399. <dd class="phpdocumentor-argument-list__definition">
  400. <section class="phpdocumentor-description"></section>
  401. </dd>
  402. </dl>
  403. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  404. Tags
  405. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  406. </h5>
  407. <dl class="phpdocumentor-tag-list">
  408. <dt class="phpdocumentor-tag-list__entry">
  409. <span class="phpdocumentor-tag__name">inheritDoc</span>
  410. </dt>
  411. <dd class="phpdocumentor-tag-list__definition">
  412. </dd>
  413. <dt class="phpdocumentor-tag-list__entry">
  414. <span class="phpdocumentor-tag__name">throws</span>
  415. </dt>
  416. <dd class="phpdocumentor-tag-list__definition">
  417. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Data-QRCodeDataException.html"><abbr title="\chillerlan\QRCode\Data\QRCodeDataException">QRCodeDataException</abbr></a></span>
  418. </dd>
  419. </dl>
  420. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  421. <span class="phpdocumentor-signature__response_type">string</span>
  422. &mdash;
  423. </article>
  424. <article
  425. class="phpdocumentor-element
  426. -method
  427. -public
  428. "
  429. >
  430. <h4 class="phpdocumentor-element__name" id="method_getLengthInBits">
  431. getLengthInBits()
  432. <a href="classes/chillerlan-QRCode-Data-Number.html#method_getLengthInBits" class="headerlink"><i class="fas fa-link"></i></a>
  433. </h4>
  434. <aside class="phpdocumentor-element-found-in">
  435. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/Number.php"><a href="files/src-data-number.html"><abbr title="src/Data/Number.php">Number.php</abbr></a></abbr>
  436. :
  437. <span class="phpdocumentor-element-found-in__line">40</span>
  438. </aside>
  439. <code class="phpdocumentor-code phpdocumentor-signature ">
  440. <span class="phpdocumentor-signature__visibility">public</span>
  441. <span class="phpdocumentor-signature__name">getLengthInBits</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
  442. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  443. Tags
  444. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  445. </h5>
  446. <dl class="phpdocumentor-tag-list">
  447. <dt class="phpdocumentor-tag-list__entry">
  448. <span class="phpdocumentor-tag__name">inheritDoc</span>
  449. </dt>
  450. <dd class="phpdocumentor-tag-list__definition">
  451. </dd>
  452. </dl>
  453. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  454. <span class="phpdocumentor-signature__response_type">int</span>
  455. &mdash;
  456. </article>
  457. <article
  458. class="phpdocumentor-element
  459. -method
  460. -public
  461. -static "
  462. >
  463. <h4 class="phpdocumentor-element__name" id="method_validateString">
  464. validateString()
  465. <a href="classes/chillerlan-QRCode-Data-Number.html#method_validateString" class="headerlink"><i class="fas fa-link"></i></a>
  466. </h4>
  467. <aside class="phpdocumentor-element-found-in">
  468. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/Number.php"><a href="files/src-data-number.html"><abbr title="src/Data/Number.php">Number.php</abbr></a></abbr>
  469. :
  470. <span class="phpdocumentor-element-found-in__line">47</span>
  471. </aside>
  472. <code class="phpdocumentor-code phpdocumentor-signature ">
  473. <span class="phpdocumentor-signature__visibility">public</span>
  474. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">validateString</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$string</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
  475. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  476. <dl class="phpdocumentor-argument-list">
  477. <dt class="phpdocumentor-argument-list__entry">
  478. <span class="phpdocumentor-signature__argument__name">$string</span>
  479. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  480. </dt>
  481. <dd class="phpdocumentor-argument-list__definition">
  482. <section class="phpdocumentor-description"></section>
  483. </dd>
  484. </dl>
  485. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  486. Tags
  487. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  488. </h5>
  489. <dl class="phpdocumentor-tag-list">
  490. <dt class="phpdocumentor-tag-list__entry">
  491. <span class="phpdocumentor-tag__name">inheritDoc</span>
  492. </dt>
  493. <dd class="phpdocumentor-tag-list__definition">
  494. </dd>
  495. </dl>
  496. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  497. <span class="phpdocumentor-signature__response_type">bool</span>
  498. &mdash;
  499. </article>
  500. <article
  501. class="phpdocumentor-element
  502. -method
  503. -public
  504. "
  505. >
  506. <h4 class="phpdocumentor-element__name" id="method_write">
  507. write()
  508. <a href="classes/chillerlan-QRCode-Data-Number.html#method_write" class="headerlink"><i class="fas fa-link"></i></a>
  509. </h4>
  510. <aside class="phpdocumentor-element-found-in">
  511. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/Number.php"><a href="files/src-data-number.html"><abbr title="src/Data/Number.php">Number.php</abbr></a></abbr>
  512. :
  513. <span class="phpdocumentor-element-found-in__line">65</span>
  514. </aside>
  515. <code class="phpdocumentor-code phpdocumentor-signature ">
  516. <span class="phpdocumentor-signature__visibility">public</span>
  517. <span class="phpdocumentor-signature__name">write</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Common-BitBuffer.html"><abbr title="\chillerlan\QRCode\Common\BitBuffer">BitBuffer</abbr></a>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$bitBuffer</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">$versionNumber</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/chillerlan-QRCode-Data-QRDataModeInterface.html"><abbr title="\chillerlan\QRCode\Data\QRDataModeInterface">QRDataModeInterface</abbr></a></span></code>
  518. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  519. <dl class="phpdocumentor-argument-list">
  520. <dt class="phpdocumentor-argument-list__entry">
  521. <span class="phpdocumentor-signature__argument__name">$bitBuffer</span>
  522. : <span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Common-BitBuffer.html"><abbr title="\chillerlan\QRCode\Common\BitBuffer">BitBuffer</abbr></a></span>
  523. </dt>
  524. <dd class="phpdocumentor-argument-list__definition">
  525. <section class="phpdocumentor-description"></section>
  526. </dd>
  527. <dt class="phpdocumentor-argument-list__entry">
  528. <span class="phpdocumentor-signature__argument__name">$versionNumber</span>
  529. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  530. </dt>
  531. <dd class="phpdocumentor-argument-list__definition">
  532. <section class="phpdocumentor-description"></section>
  533. </dd>
  534. </dl>
  535. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  536. Tags
  537. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  538. </h5>
  539. <dl class="phpdocumentor-tag-list">
  540. <dt class="phpdocumentor-tag-list__entry">
  541. <span class="phpdocumentor-tag__name">inheritDoc</span>
  542. </dt>
  543. <dd class="phpdocumentor-tag-list__definition">
  544. </dd>
  545. </dl>
  546. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  547. <span class="phpdocumentor-signature__response_type"><a href="classes/chillerlan-QRCode-Data-QRDataModeInterface.html"><abbr title="\chillerlan\QRCode\Data\QRDataModeInterface">QRDataModeInterface</abbr></a></span>
  548. &mdash;
  549. </article>
  550. <article
  551. class="phpdocumentor-element
  552. -method
  553. -protected
  554. "
  555. >
  556. <h4 class="phpdocumentor-element__name" id="method_getCharCount">
  557. getCharCount()
  558. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getCharCount" class="headerlink"><i class="fas fa-link"></i></a>
  559. </h4>
  560. <aside class="phpdocumentor-element-found-in">
  561. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/QRDataModeAbstract.php"><a href="files/src-data-qrdatamodeabstract.html"><abbr title="src/Data/QRDataModeAbstract.php">QRDataModeAbstract.php</abbr></a></abbr>
  562. :
  563. <span class="phpdocumentor-element-found-in__line">43</span>
  564. </aside>
  565. <p class="phpdocumentor-summary">returns the character count of the $data string</p>
  566. <code class="phpdocumentor-code phpdocumentor-signature ">
  567. <span class="phpdocumentor-signature__visibility">protected</span>
  568. <span class="phpdocumentor-signature__name">getCharCount</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
  569. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  570. <span class="phpdocumentor-signature__response_type">int</span>
  571. &mdash;
  572. </article>
  573. <article
  574. class="phpdocumentor-element
  575. -method
  576. -protected
  577. -static "
  578. >
  579. <h4 class="phpdocumentor-element__name" id="method_getLengthBits">
  580. getLengthBits()
  581. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getLengthBits" class="headerlink"><i class="fas fa-link"></i></a>
  582. </h4>
  583. <aside class="phpdocumentor-element-found-in">
  584. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/QRDataModeAbstract.php"><a href="files/src-data-qrdatamodeabstract.html"><abbr title="src/Data/QRDataModeAbstract.php">QRDataModeAbstract.php</abbr></a></abbr>
  585. :
  586. <span class="phpdocumentor-element-found-in__line">57</span>
  587. </aside>
  588. <p class="phpdocumentor-summary">shortcut</p>
  589. <code class="phpdocumentor-code phpdocumentor-signature ">
  590. <span class="phpdocumentor-signature__visibility">protected</span>
  591. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">getLengthBits</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$versionNumber</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
  592. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  593. <dl class="phpdocumentor-argument-list">
  594. <dt class="phpdocumentor-argument-list__entry">
  595. <span class="phpdocumentor-signature__argument__name">$versionNumber</span>
  596. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  597. </dt>
  598. <dd class="phpdocumentor-argument-list__definition">
  599. <section class="phpdocumentor-description"></section>
  600. </dd>
  601. </dl>
  602. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  603. <span class="phpdocumentor-signature__response_type">int</span>
  604. &mdash;
  605. </article>
  606. <article
  607. class="phpdocumentor-element
  608. -method
  609. -private
  610. "
  611. >
  612. <h4 class="phpdocumentor-element__name" id="method_parseInt">
  613. parseInt()
  614. <a href="classes/chillerlan-QRCode-Data-Number.html#method_parseInt" class="headerlink"><i class="fas fa-link"></i></a>
  615. </h4>
  616. <aside class="phpdocumentor-element-found-in">
  617. <abbr class="phpdocumentor-element-found-in__file" title="src/Data/Number.php"><a href="files/src-data-number.html"><abbr title="src/Data/Number.php">Number.php</abbr></a></abbr>
  618. :
  619. <span class="phpdocumentor-element-found-in__line">100</span>
  620. </aside>
  621. <p class="phpdocumentor-summary">get the code for the given numeric string</p>
  622. <code class="phpdocumentor-code phpdocumentor-signature ">
  623. <span class="phpdocumentor-signature__visibility">private</span>
  624. <span class="phpdocumentor-signature__name">parseInt</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$string</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
  625. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  626. <dl class="phpdocumentor-argument-list">
  627. <dt class="phpdocumentor-argument-list__entry">
  628. <span class="phpdocumentor-signature__argument__name">$string</span>
  629. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  630. </dt>
  631. <dd class="phpdocumentor-argument-list__definition">
  632. <section class="phpdocumentor-description"></section>
  633. </dd>
  634. </dl>
  635. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  636. <span class="phpdocumentor-signature__response_type">int</span>
  637. &mdash;
  638. </article>
  639. </section>
  640. <script type="text/javascript">
  641. function loadExternalCodeSnippets(line) {
  642. Array.prototype.slice.call(document.querySelectorAll('pre[data-src]')).forEach((pre) => {
  643. var src = pre.getAttribute('data-src').replace( /\\/g, '/');
  644. var extension = (src.match(/\.(\w+)$/) || [, ''])[1];
  645. var language = 'php';
  646. var code = document.createElement('code');
  647. code.className = 'language-' + language;
  648. pre.textContent = '';
  649. pre.setAttribute('data-line', line)
  650. code.textContent = 'Loading…';
  651. pre.appendChild(code);
  652. var xhr = new XMLHttpRequest();
  653. xhr.open('GET', src, true);
  654. xhr.onreadystatechange = function () {
  655. if (xhr.readyState == 4) {
  656. if (xhr.status < 400 && xhr.responseText) {
  657. code.textContent = xhr.responseText;
  658. Prism.highlightElement(code);
  659. }
  660. else if (xhr.status >= 400) {
  661. code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
  662. }
  663. else {
  664. code.textContent = '✖ Error: File does not exist, is empty or trying to view from localhost';
  665. }
  666. }
  667. };
  668. xhr.send(null);
  669. });
  670. }
  671. var modals = document.querySelectorAll("[data-modal]");
  672. modals.forEach(function (trigger) {
  673. trigger.addEventListener("click", function (event) {
  674. //event.preventDefault();
  675. const modal = document.getElementById(trigger.dataset.modal);
  676. modal.classList.add("phpdocumentor-modal__open");
  677. loadExternalCodeSnippets(trigger.dataset.line)
  678. const exits = modal.querySelectorAll("[data-exit-button]");
  679. exits.forEach(function (exit) {
  680. exit.addEventListener("click", function (event) {
  681. event.preventDefault();
  682. modal.classList.remove("phpdocumentor-modal__open");
  683. });
  684. });
  685. });
  686. });
  687. </script>
  688. </article>
  689. <section data-search-results class="phpdocumentor-search-results phpdocumentor-search-results--hidden">
  690. <section class="phpdocumentor-search-results__dialog">
  691. <header class="phpdocumentor-search-results__header">
  692. <h2 class="phpdocumentor-search-results__title">Search results</h2>
  693. <button class="phpdocumentor-search-results__close"><i class="fas fa-times"></i></button>
  694. </header>
  695. <section class="phpdocumentor-search-results__body">
  696. <ul class="phpdocumentor-search-results__entries"></ul>
  697. </section>
  698. </section>
  699. </section>
  700. </div>
  701. </div>
  702. <a href="classes/chillerlan-QRCode-Data-Number.html#top" class="phpdocumentor-back-to-top"><i class="fas fa-chevron-circle-up"></i></a>
  703. </main>
  704. <script>
  705. cssVars({});
  706. </script>
  707. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/prism.min.js"></script>
  708. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/autoloader/prism-autoloader.min.js"></script>
  709. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.min.js"></script>
  710. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.min.js"></script>
  711. </body>
  712. </html>