chillerlan-QRCode-Data-Kanji.html 43 KB

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