chillerlan-QRCode-Data-QRDataModeAbstract.html 29 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641
  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=Open+Sans:wght@100;200;300;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/template.js"></script>
  22. <script src="js/search.js"></script>
  23. <script defer src="js/searchIndex.js"></script>
  24. </head>
  25. <body id="top">
  26. <header class="phpdocumentor-header phpdocumentor-section">
  27. <h1 class="phpdocumentor-title"><a href="" class="phpdocumentor-title__link">Documentation</a></h1>
  28. <input class="phpdocumentor-header__menu-button" type="checkbox" id="menu-button" name="menu-button" />
  29. <label class="phpdocumentor-header__menu-icon" for="menu-button">
  30. <i class="fas fa-bars"></i>
  31. </label>
  32. <section data-search-form class="phpdocumentor-search">
  33. <label>
  34. <span class="visually-hidden">Search for</span>
  35. <svg class="phpdocumentor-search__icon" width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
  36. <circle cx="7.5" cy="7.5" r="6.5" stroke="currentColor" stroke-width="2"/>
  37. <line x1="12.4892" y1="12.2727" x2="19.1559" y2="18.9393" stroke="currentColor" stroke-width="3"/>
  38. </svg>
  39. <input type="search" class="phpdocumentor-field phpdocumentor-search__field" placeholder="Loading .." disabled />
  40. </label>
  41. </section>
  42. <nav class="phpdocumentor-topnav">
  43. <ul class="phpdocumentor-topnav__menu">
  44. <li class="phpdocumentor-topnav__menu-item -menu">
  45. <a href="https://php-qrcode.readthedocs.io">
  46. <span>
  47. User Manual
  48. </span>
  49. </a>
  50. </li>
  51. <li class="phpdocumentor-topnav__menu-item -social">
  52. <a href="https://github.com/chillerlan/php-qrcode">
  53. <span>
  54. <i class="fab fa-github"></i>
  55. </span>
  56. </a>
  57. </li>
  58. </ul>
  59. </nav>
  60. </header>
  61. <main class="phpdocumentor">
  62. <div class="phpdocumentor-section">
  63. <input class="phpdocumentor-sidebar__menu-button" type="checkbox" id="sidebar-button" name="sidebar-button" />
  64. <label class="phpdocumentor-sidebar__menu-icon" for="sidebar-button">
  65. Menu
  66. </label>
  67. <aside class="phpdocumentor-column -three phpdocumentor-sidebar">
  68. <section class="phpdocumentor-sidebar__category">
  69. <h2 class="phpdocumentor-sidebar__category-header">Namespaces</h2>
  70. <h4 class="phpdocumentor-sidebar__root-namespace">
  71. <a href="namespaces/chillerlan.html" class="">chillerlan</a>
  72. </h4>
  73. <ul class="phpdocumentor-list">
  74. <li>
  75. <a href="namespaces/chillerlan-qrcode.html" class="">QRCode</a>
  76. </li>
  77. <li>
  78. <a href="namespaces/chillerlan-qrcodetest.html" class="">QRCodeTest</a>
  79. </li>
  80. </ul>
  81. <h4 class="phpdocumentor-sidebar__root-namespace">
  82. <a href="namespaces/output.html" class="">Output</a>
  83. </h4>
  84. </section>
  85. <section class="phpdocumentor-sidebar__category">
  86. <h2 class="phpdocumentor-sidebar__category-header">Packages</h2>
  87. <h4 class="phpdocumentor-sidebar__root-namespace">
  88. <a href="packages/Application.html" class="">Application</a>
  89. </h4>
  90. </section>
  91. <section class="phpdocumentor-sidebar__category">
  92. <h2 class="phpdocumentor-sidebar__category-header">Reports</h2>
  93. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/deprecated.html">Deprecated</a></h3>
  94. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/errors.html">Errors</a></h3>
  95. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/markers.html">Markers</a></h3>
  96. </section>
  97. <section class="phpdocumentor-sidebar__category">
  98. <h2 class="phpdocumentor-sidebar__category-header">Indices</h2>
  99. <h3 class="phpdocumentor-sidebar__root-package"><a href="indices/files.html">Files</a></h3>
  100. </section>
  101. </aside>
  102. <div class="phpdocumentor-column -nine phpdocumentor-content">
  103. <section>
  104. <ul class="phpdocumentor-breadcrumbs">
  105. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan.html">chillerlan</a></li>
  106. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcode.html">QRCode</a></li>
  107. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcode-data.html">Data</a></li>
  108. </ul>
  109. <article class="phpdocumentor-element -class">
  110. <h2 class="phpdocumentor-content__title">
  111. QRDataModeAbstract
  112. <div class="phpdocumentor-element__package">
  113. in package
  114. <ul class="phpdocumentor-breadcrumbs">
  115. <li class="phpdocumentor-breadcrumb"><a href="packages/Application.html">Application</a></li>
  116. </ul>
  117. </div>
  118. <span class="phpdocumentor-element__implements">
  119. implements
  120. <a href="classes/chillerlan-QRCode-Data-QRDataModeInterface.html"><abbr title="\chillerlan\QRCode\Data\QRDataModeInterface">QRDataModeInterface</abbr></a> </span>
  121. </h2>
  122. <div class="phpdocumentor-label-line">
  123. <div class="phpdocumentor-label phpdocumentor-label--success"><span>Abstract</span><span>Yes</span></div>
  124. </div>
  125. <aside class="phpdocumentor-element-found-in">
  126. <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>
  127. :
  128. <span class="phpdocumentor-element-found-in__line">18</span>
  129. </aside>
  130. <p class="phpdocumentor-summary">abstract methods for the several data modes</p>
  131. <h3 id="toc">
  132. Table of Contents
  133. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#toc" class="headerlink"><i class="fas fa-link"></i></a>
  134. </h3>
  135. <h4 id="toc-interfaces">
  136. Interfaces
  137. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#toc-interfaces" class="headerlink"><i class="fas fa-link"></i></a>
  138. </h4>
  139. <dl class="phpdocumentor-table-of-contents">
  140. <dt class="phpdocumentor-table-of-contents__entry -interface"><a href="classes/chillerlan-QRCode-Data-QRDataModeInterface.html"><abbr title="\chillerlan\QRCode\Data\QRDataModeInterface">QRDataModeInterface</abbr></a></dt><dd>Specifies the methods reqired for the data modules (Number, Alphanum, Byte and Kanji)</dd> </dl>
  141. <h4 id="toc-properties">
  142. Properties
  143. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#toc-properties" class="headerlink"><i class="fas fa-link"></i></a>
  144. </h4>
  145. <dl class="phpdocumentor-table-of-contents">
  146. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  147. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#property_data">$data</a>
  148. <span>
  149. &nbsp;: string </span>
  150. </dt>
  151. <dd>The data to write</dd>
  152. </dl>
  153. <h4 id="toc-methods">
  154. Methods
  155. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#toc-methods" class="headerlink"><i class="fas fa-link"></i></a>
  156. </h4>
  157. <dl class="phpdocumentor-table-of-contents">
  158. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  159. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method___construct">__construct()</a>
  160. <span>
  161. &nbsp;: mixed </span>
  162. </dt>
  163. <dd>QRDataModeAbstract constructor.</dd>
  164. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  165. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_convertEncoding">convertEncoding()</a>
  166. <span>
  167. &nbsp;: string </span>
  168. </dt>
  169. <dd>encoding conversion helper</dd>
  170. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  171. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getCharCount">getCharCount()</a>
  172. <span>
  173. &nbsp;: int </span>
  174. </dt>
  175. <dd>returns the character count of the $data string</dd>
  176. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  177. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getLengthBits">getLengthBits()</a>
  178. <span>
  179. &nbsp;: int </span>
  180. </dt>
  181. <dd>shortcut</dd>
  182. </dl>
  183. <section class="phpdocumentor-properties">
  184. <h3 class="phpdocumentor-elements__header" id="properties">
  185. Properties
  186. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#properties" class="headerlink"><i class="fas fa-link"></i></a>
  187. </h3>
  188. <article
  189. class="
  190. phpdocumentor-element
  191. -property
  192. -protected
  193. "
  194. >
  195. <h4 class="phpdocumentor-element__name" id="property_data">
  196. $data
  197. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#property_data" class="headerlink"><i class="fas fa-link"></i></a>
  198. <span class="phpdocumentor-element__modifiers">
  199. </span>
  200. </h4>
  201. <aside class="phpdocumentor-element-found-in">
  202. <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>
  203. :
  204. <span class="phpdocumentor-element-found-in__line">23</span>
  205. </aside>
  206. <p class="phpdocumentor-summary">The data to write</p>
  207. <code class="phpdocumentor-code phpdocumentor-signature ">
  208. <span class="phpdocumentor-signature__visibility">protected</span>
  209. <span class="phpdocumentor-signature__type">string</span>
  210. <span class="phpdocumentor-signature__name">$data</span>
  211. </code>
  212. </article>
  213. </section>
  214. <section class="phpdocumentor-methods">
  215. <h3 class="phpdocumentor-elements__header" id="methods">
  216. Methods
  217. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#methods" class="headerlink"><i class="fas fa-link"></i></a>
  218. </h3>
  219. <article
  220. class="phpdocumentor-element
  221. -method
  222. -public
  223. "
  224. >
  225. <h4 class="phpdocumentor-element__name" id="method___construct">
  226. __construct()
  227. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method___construct" 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/QRDataModeAbstract.php"><a href="files/src-data-qrdatamodeabstract.html"><abbr title="src/Data/QRDataModeAbstract.php">QRDataModeAbstract.php</abbr></a></abbr>
  231. :
  232. <span class="phpdocumentor-element-found-in__line">30</span>
  233. </aside>
  234. <p class="phpdocumentor-summary">QRDataModeAbstract constructor.</p>
  235. <code class="phpdocumentor-code phpdocumentor-signature ">
  236. <span class="phpdocumentor-signature__visibility">public</span>
  237. <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>
  238. <div class="phpdocumentor-label-line">
  239. </div>
  240. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  241. <dl class="phpdocumentor-argument-list">
  242. <dt class="phpdocumentor-argument-list__entry">
  243. <span class="phpdocumentor-signature__argument__name">$data</span>
  244. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  245. </dt>
  246. <dd class="phpdocumentor-argument-list__definition">
  247. </dd>
  248. </dl>
  249. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  250. Tags
  251. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method___construct#tags" class="headerlink"><i class="fas fa-link"></i></a>
  252. </h5>
  253. <dl class="phpdocumentor-tag-list">
  254. <dt class="phpdocumentor-tag-list__entry">
  255. <span class="phpdocumentor-tag__name">throws</span>
  256. </dt>
  257. <dd class="phpdocumentor-tag-list__definition">
  258. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Data-QRCodeDataException.html"><abbr title="\chillerlan\QRCode\Data\QRCodeDataException">QRCodeDataException</abbr></a></span>
  259. </dd>
  260. </dl>
  261. </article>
  262. <article
  263. class="phpdocumentor-element
  264. -method
  265. -public
  266. -static "
  267. >
  268. <h4 class="phpdocumentor-element__name" id="method_convertEncoding">
  269. convertEncoding()
  270. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_convertEncoding" class="headerlink"><i class="fas fa-link"></i></a>
  271. </h4>
  272. <aside class="phpdocumentor-element-found-in">
  273. <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>
  274. :
  275. <span class="phpdocumentor-element-found-in__line">50</span>
  276. </aside>
  277. <p class="phpdocumentor-summary">encoding conversion helper</p>
  278. <code class="phpdocumentor-code phpdocumentor-signature ">
  279. <span class="phpdocumentor-signature__visibility">public</span>
  280. <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>
  281. <div class="phpdocumentor-label-line">
  282. </div>
  283. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  284. <dl class="phpdocumentor-argument-list">
  285. <dt class="phpdocumentor-argument-list__entry">
  286. <span class="phpdocumentor-signature__argument__name">$string</span>
  287. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  288. </dt>
  289. <dd class="phpdocumentor-argument-list__definition">
  290. </dd>
  291. </dl>
  292. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  293. Tags
  294. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_convertEncoding#tags" class="headerlink"><i class="fas fa-link"></i></a>
  295. </h5>
  296. <dl class="phpdocumentor-tag-list">
  297. <dt class="phpdocumentor-tag-list__entry">
  298. <span class="phpdocumentor-tag__name">inheritDoc</span>
  299. </dt>
  300. <dd class="phpdocumentor-tag-list__definition">
  301. </dd>
  302. </dl>
  303. <section>
  304. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  305. <span class="phpdocumentor-signature__response_type">string</span>
  306. </section>
  307. </article>
  308. <article
  309. class="phpdocumentor-element
  310. -method
  311. -protected
  312. "
  313. >
  314. <h4 class="phpdocumentor-element__name" id="method_getCharCount">
  315. getCharCount()
  316. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getCharCount" class="headerlink"><i class="fas fa-link"></i></a>
  317. </h4>
  318. <aside class="phpdocumentor-element-found-in">
  319. <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>
  320. :
  321. <span class="phpdocumentor-element-found-in__line">43</span>
  322. </aside>
  323. <p class="phpdocumentor-summary">returns the character count of the $data string</p>
  324. <code class="phpdocumentor-code phpdocumentor-signature ">
  325. <span class="phpdocumentor-signature__visibility">protected</span>
  326. <span class="phpdocumentor-signature__name">getCharCount</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
  327. <div class="phpdocumentor-label-line">
  328. </div>
  329. <section>
  330. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  331. <span class="phpdocumentor-signature__response_type">int</span>
  332. </section>
  333. </article>
  334. <article
  335. class="phpdocumentor-element
  336. -method
  337. -protected
  338. -static "
  339. >
  340. <h4 class="phpdocumentor-element__name" id="method_getLengthBits">
  341. getLengthBits()
  342. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getLengthBits" class="headerlink"><i class="fas fa-link"></i></a>
  343. </h4>
  344. <aside class="phpdocumentor-element-found-in">
  345. <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>
  346. :
  347. <span class="phpdocumentor-element-found-in__line">57</span>
  348. </aside>
  349. <p class="phpdocumentor-summary">shortcut</p>
  350. <code class="phpdocumentor-code phpdocumentor-signature ">
  351. <span class="phpdocumentor-signature__visibility">protected</span>
  352. <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>
  353. <div class="phpdocumentor-label-line">
  354. </div>
  355. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  356. <dl class="phpdocumentor-argument-list">
  357. <dt class="phpdocumentor-argument-list__entry">
  358. <span class="phpdocumentor-signature__argument__name">$versionNumber</span>
  359. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  360. </dt>
  361. <dd class="phpdocumentor-argument-list__definition">
  362. </dd>
  363. </dl>
  364. <section>
  365. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  366. <span class="phpdocumentor-signature__response_type">int</span>
  367. </section>
  368. </article>
  369. </section>
  370. <div class="phpdocumentor-modal" id="source-view">
  371. <div class="phpdocumentor-modal-bg" data-exit-button></div>
  372. <div class="phpdocumentor-modal-container">
  373. <div class="phpdocumentor-modal-content">
  374. <pre style="max-height: 500px; overflow-y: scroll" data-src="files/src/Data/QRDataModeAbstract.php.txt" class="language-php line-numbers linkable-line-numbers"></pre>
  375. </div>
  376. <button data-exit-button class="phpdocumentor-modal__close">&times;</button>
  377. </div>
  378. </div>
  379. <script type="text/javascript">
  380. (function () {
  381. function loadExternalCodeSnippet(el, url, line) {
  382. Array.prototype.slice.call(el.querySelectorAll('pre[data-src]')).forEach((pre) => {
  383. const src = url || pre.getAttribute('data-src').replace(/\\/g, '/');
  384. const language = 'php';
  385. const code = document.createElement('code');
  386. code.className = 'language-' + language;
  387. pre.textContent = '';
  388. pre.setAttribute('data-line', line)
  389. code.textContent = 'Loading…';
  390. pre.appendChild(code);
  391. var xhr = new XMLHttpRequest();
  392. xhr.open('GET', src, true);
  393. xhr.onreadystatechange = function () {
  394. if (xhr.readyState !== 4) {
  395. return;
  396. }
  397. if (xhr.status < 400 && xhr.responseText) {
  398. code.textContent = xhr.responseText;
  399. Prism.highlightElement(code);
  400. return;
  401. }
  402. if (xhr.status === 404) {
  403. code.textContent = '✖ Error: File could not be found';
  404. return;
  405. }
  406. if (xhr.status >= 400) {
  407. code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
  408. return;
  409. }
  410. code.textContent = '✖ Error: An unknown error occurred';
  411. };
  412. xhr.send(null);
  413. });
  414. }
  415. const modalButtons = document.querySelectorAll("[data-modal]");
  416. const openedAsLocalFile = window.location.protocol === 'file:';
  417. if (modalButtons.length > 0 && openedAsLocalFile) {
  418. console.warn(
  419. 'Viewing the source code is unavailable because you are opening this page from the file:// scheme; ' +
  420. 'browsers block XHR requests when a page is opened this way'
  421. );
  422. }
  423. modalButtons.forEach(function (trigger) {
  424. if (openedAsLocalFile) {
  425. trigger.setAttribute("hidden", "hidden");
  426. }
  427. trigger.addEventListener("click", function (event) {
  428. event.preventDefault();
  429. const modal = document.getElementById(trigger.dataset.modal);
  430. if (!modal) {
  431. console.error(`Modal with id "${trigger.dataset.modal}" could not be found`);
  432. return;
  433. }
  434. modal.classList.add("phpdocumentor-modal__open");
  435. loadExternalCodeSnippet(modal, trigger.dataset.src || null, trigger.dataset.line)
  436. const exits = modal.querySelectorAll("[data-exit-button]");
  437. exits.forEach(function (exit) {
  438. exit.addEventListener("click", function (event) {
  439. event.preventDefault();
  440. modal.classList.remove("phpdocumentor-modal__open");
  441. });
  442. });
  443. });
  444. });
  445. })();
  446. </script>
  447. </article>
  448. </section>
  449. <section class="phpdocumentor-on-this-page__sidebar">
  450. <section class="phpdocumentor-on-this-page__content">
  451. <strong class="phpdocumentor-on-this-page__title">On this page</strong>
  452. <ul class="phpdocumentor-list -clean">
  453. <li class="phpdocumentor-on-this-page-section__title">Table Of Contents</li>
  454. <li>
  455. <ul class="phpdocumentor-list -clean">
  456. <li><a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#toc-properties">Properties</a></li>
  457. <li><a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#toc-methods">Methods</a></li>
  458. </ul>
  459. </li>
  460. <li class="phpdocumentor-on-this-page-section__title">Properties</li>
  461. <li>
  462. <ul class="phpdocumentor-list -clean">
  463. <li><a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#property_data">$data<a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html"></li>
  464. </ul>
  465. </li>
  466. <li class="phpdocumentor-on-this-page-section__title">Methods</li>
  467. <li>
  468. <ul class="phpdocumentor-list -clean">
  469. <li><a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method___construct">__construct()</a></li>
  470. <li><a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_convertEncoding">convertEncoding()</a></li>
  471. <li><a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getCharCount">getCharCount()</a></li>
  472. <li><a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#method_getLengthBits">getLengthBits()</a></li>
  473. </ul>
  474. </li>
  475. </ul>
  476. </section>
  477. </section>
  478. </div>
  479. <section data-search-results class="phpdocumentor-search-results phpdocumentor-search-results--hidden">
  480. <section class="phpdocumentor-search-results__dialog">
  481. <header class="phpdocumentor-search-results__header">
  482. <h2 class="phpdocumentor-search-results__title">Search results</h2>
  483. <button class="phpdocumentor-search-results__close"><i class="fas fa-times"></i></button>
  484. </header>
  485. <section class="phpdocumentor-search-results__body">
  486. <ul class="phpdocumentor-search-results__entries"></ul>
  487. </section>
  488. </section>
  489. </section>
  490. </div>
  491. <a href="classes/chillerlan-QRCode-Data-QRDataModeAbstract.html#top" class="phpdocumentor-back-to-top"><i class="fas fa-chevron-circle-up"></i></a>
  492. </main>
  493. <script>
  494. cssVars({});
  495. </script>
  496. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/prism.min.js"></script>
  497. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/autoloader/prism-autoloader.min.js"></script>
  498. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.min.js"></script>
  499. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.min.js"></script>
  500. </body>
  501. </html>