chillerlan-QRCode-Output-QRString.html 63 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334
  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-output.html">Output</a></li>
  89. </ul>
  90. <article class="phpdocumentor-element -class">
  91. <h2 class="phpdocumentor-content__title">
  92. QRString
  93. <span class="phpdocumentor-element__extends">
  94. extends <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html"><abbr title="\chillerlan\QRCode\Output\QROutputAbstract">QROutputAbstract</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/Output/QRString.php"><a href="files/src-output-qrstring.html"><abbr title="src/Output/QRString.php">QRString.php</abbr></a></abbr>
  105. :
  106. <span class="phpdocumentor-element-found-in__line">21</span>
  107. </aside>
  108. <p class="phpdocumentor-summary">Converts the matrix data into string types</p>
  109. <h3 id="toc">
  110. Table of Contents
  111. <a href="#toc" class="headerlink"><i class="fas fa-link"></i></a>
  112. </h3>
  113. <dl class="phpdocumentor-table-of-contents">
  114. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  115. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_length">$length</a>
  116. <span>
  117. &nbsp;: int </span>
  118. </dt>
  119. <dd>the side length of the QR image (modules * scale)</dd>
  120. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  121. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_matrix">$matrix</a>
  122. <span>
  123. &nbsp;: <a href="classes/chillerlan-QRCode-Data-QRMatrix.html"><abbr title="\chillerlan\QRCode\Data\QRMatrix">QRMatrix</abbr></a> </span>
  124. </dt>
  125. <dd>the (filled) data matrix object</dd>
  126. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  127. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_moduleCount">$moduleCount</a>
  128. <span>
  129. &nbsp;: int </span>
  130. </dt>
  131. <dd>the current size of the QR matrix</dd>
  132. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  133. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_moduleValues">$moduleValues</a>
  134. <span>
  135. &nbsp;: array&lt;string|int, mixed&gt; </span>
  136. </dt>
  137. <dd>an (optional) array of color values for the several QR matrix parts</dd>
  138. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  139. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_options">$options</a>
  140. <span>
  141. &nbsp;: <abbr title="\chillerlan\Settings\SettingsContainerInterface">SettingsContainerInterface</abbr> </span>
  142. </dt>
  143. <dd></dd>
  144. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  145. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_scale">$scale</a>
  146. <span>
  147. &nbsp;: int </span>
  148. </dt>
  149. <dd>the current scaling for a QR pixel</dd>
  150. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  151. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method___construct">__construct()</a>
  152. <span>
  153. &nbsp;: mixed </span>
  154. </dt>
  155. <dd>QROutputAbstract constructor.</dd>
  156. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  157. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_dump">dump()</a>
  158. <span>
  159. &nbsp;: string </span>
  160. </dt>
  161. <dd></dd>
  162. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  163. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_moduleValueIsValid">moduleValueIsValid()</a>
  164. <span>
  165. &nbsp;: bool </span>
  166. </dt>
  167. <dd></dd>
  168. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  169. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_collectModules">collectModules()</a>
  170. <span>
  171. &nbsp;: array&lt;string|int, mixed&gt; </span>
  172. </dt>
  173. <dd>collects the modules per QRMatrix::M_* type and runs a $transform function on each module and
  174. returns an array with the transformed modules</dd>
  175. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  176. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_getDefaultModuleValue">getDefaultModuleValue()</a>
  177. <span>
  178. &nbsp;: mixed|null </span>
  179. </dt>
  180. <dd>Returns a default value for either dark or light modules</dd>
  181. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  182. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_getModuleValue">getModuleValue()</a>
  183. <span>
  184. &nbsp;: mixed|null </span>
  185. </dt>
  186. <dd>Returns the prepared value for the given $M_TYPE</dd>
  187. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  188. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_getModuleValueAt">getModuleValueAt()</a>
  189. <span>
  190. &nbsp;: mixed|null </span>
  191. </dt>
  192. <dd>Returns the prepared module value at the given coordinate [$x, $y] (convenience)</dd>
  193. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  194. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_json">json()</a>
  195. <span>
  196. &nbsp;: string </span>
  197. </dt>
  198. <dd>JSON output</dd>
  199. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  200. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_prepareModuleValue">prepareModuleValue()</a>
  201. <span>
  202. &nbsp;: mixed|null </span>
  203. </dt>
  204. <dd>Prepares the value for the given input ()</dd>
  205. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  206. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_saveToFile">saveToFile()</a>
  207. <span>
  208. &nbsp;: void </span>
  209. </dt>
  210. <dd>Saves the qr $data to a $file. If $file is null, nothing happens.</dd>
  211. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  212. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_setMatrixDimensions">setMatrixDimensions()</a>
  213. <span>
  214. &nbsp;: void </span>
  215. </dt>
  216. <dd>Sets/updates the matrix dimensions</dd>
  217. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  218. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_setModuleValues">setModuleValues()</a>
  219. <span>
  220. &nbsp;: void </span>
  221. </dt>
  222. <dd>Sets the initial module values</dd>
  223. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  224. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_text">text()</a>
  225. <span>
  226. &nbsp;: string </span>
  227. </dt>
  228. <dd>string output</dd>
  229. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  230. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_toBase64DataURI">toBase64DataURI()</a>
  231. <span>
  232. &nbsp;: string </span>
  233. </dt>
  234. <dd>Returns a base64 data URI for the given string and mime type</dd>
  235. </dl>
  236. <section class="phpdocumentor-properties">
  237. <h3 class="phpdocumentor-elements__header" id="properties">
  238. Properties
  239. <a href="classes/chillerlan-QRCode-Output-QRString.html#properties" class="headerlink"><i class="fas fa-link"></i></a>
  240. </h3>
  241. <article
  242. class="
  243. phpdocumentor-element
  244. -property
  245. -protected
  246. "
  247. >
  248. <h4 class="phpdocumentor-element__name" id="property_length">
  249. $length
  250. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_length" class="headerlink"><i class="fas fa-link"></i></a>
  251. <span class="phpdocumentor-element__modifiers">
  252. </span>
  253. </h4>
  254. <aside class="phpdocumentor-element-found-in">
  255. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  256. :
  257. <span class="phpdocumentor-element-found-in__line">40</span>
  258. </aside>
  259. <p class="phpdocumentor-summary">the side length of the QR image (modules * scale)</p>
  260. <code class="phpdocumentor-code phpdocumentor-signature ">
  261. <span class="phpdocumentor-signature__visibility">protected</span>
  262. <span class="phpdocumentor-signature__type">int</span>
  263. <span class="phpdocumentor-signature__name">$length</span>
  264. </code>
  265. <section class="phpdocumentor-description"></section>
  266. </article>
  267. <article
  268. class="
  269. phpdocumentor-element
  270. -property
  271. -protected
  272. "
  273. >
  274. <h4 class="phpdocumentor-element__name" id="property_matrix">
  275. $matrix
  276. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_matrix" class="headerlink"><i class="fas fa-link"></i></a>
  277. <span class="phpdocumentor-element__modifiers">
  278. </span>
  279. </h4>
  280. <aside class="phpdocumentor-element-found-in">
  281. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  282. :
  283. <span class="phpdocumentor-element-found-in__line">50</span>
  284. </aside>
  285. <p class="phpdocumentor-summary">the (filled) data matrix object</p>
  286. <code class="phpdocumentor-code phpdocumentor-signature ">
  287. <span class="phpdocumentor-signature__visibility">protected</span>
  288. <span class="phpdocumentor-signature__type"><a href="classes/chillerlan-QRCode-Data-QRMatrix.html"><abbr title="\chillerlan\QRCode\Data\QRMatrix">QRMatrix</abbr></a></span>
  289. <span class="phpdocumentor-signature__name">$matrix</span>
  290. </code>
  291. <section class="phpdocumentor-description"></section>
  292. </article>
  293. <article
  294. class="
  295. phpdocumentor-element
  296. -property
  297. -protected
  298. "
  299. >
  300. <h4 class="phpdocumentor-element__name" id="property_moduleCount">
  301. $moduleCount
  302. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_moduleCount" class="headerlink"><i class="fas fa-link"></i></a>
  303. <span class="phpdocumentor-element__modifiers">
  304. </span>
  305. </h4>
  306. <aside class="phpdocumentor-element-found-in">
  307. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  308. :
  309. <span class="phpdocumentor-element-found-in__line">28</span>
  310. </aside>
  311. <p class="phpdocumentor-summary">the current size of the QR matrix</p>
  312. <code class="phpdocumentor-code phpdocumentor-signature ">
  313. <span class="phpdocumentor-signature__visibility">protected</span>
  314. <span class="phpdocumentor-signature__type">int</span>
  315. <span class="phpdocumentor-signature__name">$moduleCount</span>
  316. </code>
  317. <section class="phpdocumentor-description"></section>
  318. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  319. Tags
  320. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  321. </h5>
  322. <dl class="phpdocumentor-tag-list">
  323. <dt class="phpdocumentor-tag-list__entry">
  324. <span class="phpdocumentor-tag__name">see</span>
  325. </dt>
  326. <dd class="phpdocumentor-tag-list__definition">
  327. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Data-QRMatrix.html#method_getSize"><abbr title="\chillerlan\QRCode\Data\QRMatrix::getSize()">QRMatrix::getSize()</abbr></a></span>
  328. </dd>
  329. </dl>
  330. </article>
  331. <article
  332. class="
  333. phpdocumentor-element
  334. -property
  335. -protected
  336. "
  337. >
  338. <h4 class="phpdocumentor-element__name" id="property_moduleValues">
  339. $moduleValues
  340. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_moduleValues" class="headerlink"><i class="fas fa-link"></i></a>
  341. <span class="phpdocumentor-element__modifiers">
  342. </span>
  343. </h4>
  344. <aside class="phpdocumentor-element-found-in">
  345. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  346. :
  347. <span class="phpdocumentor-element-found-in__line">45</span>
  348. </aside>
  349. <p class="phpdocumentor-summary">an (optional) array of color values for the several QR matrix parts</p>
  350. <code class="phpdocumentor-code phpdocumentor-signature ">
  351. <span class="phpdocumentor-signature__visibility">protected</span>
  352. <span class="phpdocumentor-signature__type">array&lt;string|int, mixed&gt;</span>
  353. <span class="phpdocumentor-signature__name">$moduleValues</span>
  354. </code>
  355. <section class="phpdocumentor-description"></section>
  356. </article>
  357. <article
  358. class="
  359. phpdocumentor-element
  360. -property
  361. -protected
  362. "
  363. >
  364. <h4 class="phpdocumentor-element__name" id="property_options">
  365. $options
  366. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_options" class="headerlink"><i class="fas fa-link"></i></a>
  367. <span class="phpdocumentor-element__modifiers">
  368. </span>
  369. </h4>
  370. <aside class="phpdocumentor-element-found-in">
  371. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  372. :
  373. <span class="phpdocumentor-element-found-in__line">55</span>
  374. </aside>
  375. <code class="phpdocumentor-code phpdocumentor-signature ">
  376. <span class="phpdocumentor-signature__visibility">protected</span>
  377. <span class="phpdocumentor-signature__type"><abbr title="\chillerlan\Settings\SettingsContainerInterface">SettingsContainerInterface</abbr></span>
  378. <span class="phpdocumentor-signature__name">$options</span>
  379. </code>
  380. </article>
  381. <article
  382. class="
  383. phpdocumentor-element
  384. -property
  385. -protected
  386. "
  387. >
  388. <h4 class="phpdocumentor-element__name" id="property_scale">
  389. $scale
  390. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_scale" class="headerlink"><i class="fas fa-link"></i></a>
  391. <span class="phpdocumentor-element__modifiers">
  392. </span>
  393. </h4>
  394. <aside class="phpdocumentor-element-found-in">
  395. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  396. :
  397. <span class="phpdocumentor-element-found-in__line">35</span>
  398. </aside>
  399. <p class="phpdocumentor-summary">the current scaling for a QR pixel</p>
  400. <code class="phpdocumentor-code phpdocumentor-signature ">
  401. <span class="phpdocumentor-signature__visibility">protected</span>
  402. <span class="phpdocumentor-signature__type">int</span>
  403. <span class="phpdocumentor-signature__name">$scale</span>
  404. </code>
  405. <section class="phpdocumentor-description"></section>
  406. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  407. Tags
  408. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  409. </h5>
  410. <dl class="phpdocumentor-tag-list">
  411. <dt class="phpdocumentor-tag-list__entry">
  412. <span class="phpdocumentor-tag__name">see</span>
  413. </dt>
  414. <dd class="phpdocumentor-tag-list__definition">
  415. <span class="phpdocumentor-tag-link"><abbr title="\chillerlan\QRCode\QROptions::$scale">QROptions::$scale</abbr></span>
  416. </dd>
  417. </dl>
  418. </article>
  419. </section>
  420. <section class="phpdocumentor-methods">
  421. <h3 class="phpdocumentor-elements__header" id="methods">
  422. Methods
  423. <a href="classes/chillerlan-QRCode-Output-QRString.html#methods" class="headerlink"><i class="fas fa-link"></i></a>
  424. </h3>
  425. <article
  426. class="phpdocumentor-element
  427. -method
  428. -public
  429. "
  430. >
  431. <h4 class="phpdocumentor-element__name" id="method___construct">
  432. __construct()
  433. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method___construct" class="headerlink"><i class="fas fa-link"></i></a>
  434. </h4>
  435. <aside class="phpdocumentor-element-found-in">
  436. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  437. :
  438. <span class="phpdocumentor-element-found-in__line">60</span>
  439. </aside>
  440. <p class="phpdocumentor-summary">QROutputAbstract constructor.</p>
  441. <code class="phpdocumentor-code phpdocumentor-signature ">
  442. <span class="phpdocumentor-signature__visibility">public</span>
  443. <span class="phpdocumentor-signature__name">__construct</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><abbr title="\chillerlan\Settings\SettingsContainerInterface">SettingsContainerInterface</abbr>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$options</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Data-QRMatrix.html"><abbr title="\chillerlan\QRCode\Data\QRMatrix">QRMatrix</abbr></a>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$matrix</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
  444. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  445. <dl class="phpdocumentor-argument-list">
  446. <dt class="phpdocumentor-argument-list__entry">
  447. <span class="phpdocumentor-signature__argument__name">$options</span>
  448. : <span class="phpdocumentor-signature__argument__return-type"><abbr title="\chillerlan\Settings\SettingsContainerInterface">SettingsContainerInterface</abbr></span>
  449. </dt>
  450. <dd class="phpdocumentor-argument-list__definition">
  451. <section class="phpdocumentor-description"></section>
  452. </dd>
  453. <dt class="phpdocumentor-argument-list__entry">
  454. <span class="phpdocumentor-signature__argument__name">$matrix</span>
  455. : <span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Data-QRMatrix.html"><abbr title="\chillerlan\QRCode\Data\QRMatrix">QRMatrix</abbr></a></span>
  456. </dt>
  457. <dd class="phpdocumentor-argument-list__definition">
  458. <section class="phpdocumentor-description"></section>
  459. </dd>
  460. </dl>
  461. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  462. <span class="phpdocumentor-signature__response_type">mixed</span>
  463. &mdash;
  464. </article>
  465. <article
  466. class="phpdocumentor-element
  467. -method
  468. -public
  469. "
  470. >
  471. <h4 class="phpdocumentor-element__name" id="method_dump">
  472. dump()
  473. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_dump" class="headerlink"><i class="fas fa-link"></i></a>
  474. </h4>
  475. <aside class="phpdocumentor-element-found-in">
  476. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRString.php"><a href="files/src-output-qrstring.html"><abbr title="src/Output/QRString.php">QRString.php</abbr></a></abbr>
  477. :
  478. <span class="phpdocumentor-element-found-in__line">47</span>
  479. </aside>
  480. <code class="phpdocumentor-code phpdocumentor-signature ">
  481. <span class="phpdocumentor-signature__visibility">public</span>
  482. <span class="phpdocumentor-signature__name">dump</span><span>(</span><span class="phpdocumentor-signature__argument"><span>[</span><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$file</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">null</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
  483. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  484. <dl class="phpdocumentor-argument-list">
  485. <dt class="phpdocumentor-argument-list__entry">
  486. <span class="phpdocumentor-signature__argument__name">$file</span>
  487. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  488. = <span class="phpdocumentor-signature__argument__default-value">null</span> </dt>
  489. <dd class="phpdocumentor-argument-list__definition">
  490. <section class="phpdocumentor-description"></section>
  491. </dd>
  492. </dl>
  493. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  494. Tags
  495. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  496. </h5>
  497. <dl class="phpdocumentor-tag-list">
  498. <dt class="phpdocumentor-tag-list__entry">
  499. <span class="phpdocumentor-tag__name">inheritDoc</span>
  500. </dt>
  501. <dd class="phpdocumentor-tag-list__definition">
  502. </dd>
  503. </dl>
  504. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  505. <span class="phpdocumentor-signature__response_type">string</span>
  506. &mdash;
  507. </article>
  508. <article
  509. class="phpdocumentor-element
  510. -method
  511. -public
  512. -static "
  513. >
  514. <h4 class="phpdocumentor-element__name" id="method_moduleValueIsValid">
  515. moduleValueIsValid()
  516. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_moduleValueIsValid" class="headerlink"><i class="fas fa-link"></i></a>
  517. </h4>
  518. <aside class="phpdocumentor-element-found-in">
  519. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRString.php"><a href="files/src-output-qrstring.html"><abbr title="src/Output/QRString.php">QRString.php</abbr></a></abbr>
  520. :
  521. <span class="phpdocumentor-element-found-in__line">26</span>
  522. </aside>
  523. <code class="phpdocumentor-code phpdocumentor-signature ">
  524. <span class="phpdocumentor-signature__visibility">public</span>
  525. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">moduleValueIsValid</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">mixed&nbsp;</span><span class="phpdocumentor-signature__argument__name">$value</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
  526. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  527. <dl class="phpdocumentor-argument-list">
  528. <dt class="phpdocumentor-argument-list__entry">
  529. <span class="phpdocumentor-signature__argument__name">$value</span>
  530. : <span class="phpdocumentor-signature__argument__return-type">mixed</span>
  531. </dt>
  532. <dd class="phpdocumentor-argument-list__definition">
  533. <section class="phpdocumentor-description"></section>
  534. </dd>
  535. </dl>
  536. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  537. Tags
  538. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  539. </h5>
  540. <dl class="phpdocumentor-tag-list">
  541. <dt class="phpdocumentor-tag-list__entry">
  542. <span class="phpdocumentor-tag__name">inheritDoc</span>
  543. </dt>
  544. <dd class="phpdocumentor-tag-list__definition">
  545. </dd>
  546. </dl>
  547. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  548. <span class="phpdocumentor-signature__response_type">bool</span>
  549. &mdash;
  550. </article>
  551. <article
  552. class="phpdocumentor-element
  553. -method
  554. -protected
  555. "
  556. >
  557. <h4 class="phpdocumentor-element__name" id="method_collectModules">
  558. collectModules()
  559. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_collectModules" class="headerlink"><i class="fas fa-link"></i></a>
  560. </h4>
  561. <aside class="phpdocumentor-element-found-in">
  562. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  563. :
  564. <span class="phpdocumentor-element-found-in__line">176</span>
  565. </aside>
  566. <p class="phpdocumentor-summary">collects the modules per QRMatrix::M_* type and runs a $transform function on each module and
  567. returns an array with the transformed modules</p>
  568. <code class="phpdocumentor-code phpdocumentor-signature ">
  569. <span class="phpdocumentor-signature__visibility">protected</span>
  570. <span class="phpdocumentor-signature__name">collectModules</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><abbr title="\Closure">Closure</abbr>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$transform</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span></code>
  571. <section class="phpdocumentor-description"><p>The transform callback is called with the following parameters:</p>
  572. <p>$x - current column
  573. $y - current row
  574. $M_TYPE - field value
  575. $M_TYPE_LAYER - (possibly modified) field value that acts as layer id</p>
  576. </section>
  577. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  578. <dl class="phpdocumentor-argument-list">
  579. <dt class="phpdocumentor-argument-list__entry">
  580. <span class="phpdocumentor-signature__argument__name">$transform</span>
  581. : <span class="phpdocumentor-signature__argument__return-type"><abbr title="\Closure">Closure</abbr></span>
  582. </dt>
  583. <dd class="phpdocumentor-argument-list__definition">
  584. <section class="phpdocumentor-description"></section>
  585. </dd>
  586. </dl>
  587. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  588. <span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span>
  589. &mdash;
  590. </article>
  591. <article
  592. class="phpdocumentor-element
  593. -method
  594. -protected
  595. "
  596. >
  597. <h4 class="phpdocumentor-element__name" id="method_getDefaultModuleValue">
  598. getDefaultModuleValue()
  599. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_getDefaultModuleValue" class="headerlink"><i class="fas fa-link"></i></a>
  600. </h4>
  601. <aside class="phpdocumentor-element-found-in">
  602. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRString.php"><a href="files/src-output-qrstring.html"><abbr title="src/Output/QRString.php">QRString.php</abbr></a></abbr>
  603. :
  604. <span class="phpdocumentor-element-found-in__line">40</span>
  605. </aside>
  606. <p class="phpdocumentor-summary">Returns a default value for either dark or light modules</p>
  607. <code class="phpdocumentor-code phpdocumentor-signature ">
  608. <span class="phpdocumentor-signature__visibility">protected</span>
  609. <span class="phpdocumentor-signature__name">getDefaultModuleValue</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">bool&nbsp;</span><span class="phpdocumentor-signature__argument__name">$isDark</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed|null</span></code>
  610. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  611. <dl class="phpdocumentor-argument-list">
  612. <dt class="phpdocumentor-argument-list__entry">
  613. <span class="phpdocumentor-signature__argument__name">$isDark</span>
  614. : <span class="phpdocumentor-signature__argument__return-type">bool</span>
  615. </dt>
  616. <dd class="phpdocumentor-argument-list__definition">
  617. <section class="phpdocumentor-description"></section>
  618. </dd>
  619. </dl>
  620. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  621. Tags
  622. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  623. </h5>
  624. <dl class="phpdocumentor-tag-list">
  625. <dt class="phpdocumentor-tag-list__entry">
  626. <span class="phpdocumentor-tag__name">inheritDoc</span>
  627. </dt>
  628. <dd class="phpdocumentor-tag-list__definition">
  629. </dd>
  630. </dl>
  631. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  632. <span class="phpdocumentor-signature__response_type">mixed|null</span>
  633. &mdash;
  634. <section class="phpdocumentor-description"><p>return value depends on the output class</p>
  635. </section>
  636. </article>
  637. <article
  638. class="phpdocumentor-element
  639. -method
  640. -protected
  641. "
  642. >
  643. <h4 class="phpdocumentor-element__name" id="method_getModuleValue">
  644. getModuleValue()
  645. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_getModuleValue" class="headerlink"><i class="fas fa-link"></i></a>
  646. </h4>
  647. <aside class="phpdocumentor-element-found-in">
  648. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  649. :
  650. <span class="phpdocumentor-element-found-in__line">100</span>
  651. </aside>
  652. <p class="phpdocumentor-summary">Returns the prepared value for the given $M_TYPE</p>
  653. <code class="phpdocumentor-code phpdocumentor-signature ">
  654. <span class="phpdocumentor-signature__visibility">protected</span>
  655. <span class="phpdocumentor-signature__name">getModuleValue</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$M_TYPE</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed|null</span></code>
  656. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  657. <dl class="phpdocumentor-argument-list">
  658. <dt class="phpdocumentor-argument-list__entry">
  659. <span class="phpdocumentor-signature__argument__name">$M_TYPE</span>
  660. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  661. </dt>
  662. <dd class="phpdocumentor-argument-list__definition">
  663. <section class="phpdocumentor-description"></section>
  664. </dd>
  665. </dl>
  666. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  667. Tags
  668. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  669. </h5>
  670. <dl class="phpdocumentor-tag-list">
  671. <dt class="phpdocumentor-tag-list__entry">
  672. <span class="phpdocumentor-tag__name">throws</span>
  673. </dt>
  674. <dd class="phpdocumentor-tag-list__definition">
  675. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Output-QRCodeOutputException.html"><abbr title="\chillerlan\QRCode\Output\QRCodeOutputException">QRCodeOutputException</abbr></a></span>
  676. </dd>
  677. </dl>
  678. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  679. <span class="phpdocumentor-signature__response_type">mixed|null</span>
  680. &mdash;
  681. <section class="phpdocumentor-description"><p>return value depends on the output class, null if $moduleValues[$M_TYPE] doesn't exist</p>
  682. </section>
  683. </article>
  684. <article
  685. class="phpdocumentor-element
  686. -method
  687. -protected
  688. "
  689. >
  690. <h4 class="phpdocumentor-element__name" id="method_getModuleValueAt">
  691. getModuleValueAt()
  692. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_getModuleValueAt" class="headerlink"><i class="fas fa-link"></i></a>
  693. </h4>
  694. <aside class="phpdocumentor-element-found-in">
  695. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  696. :
  697. <span class="phpdocumentor-element-found-in__line">115</span>
  698. </aside>
  699. <p class="phpdocumentor-summary">Returns the prepared module value at the given coordinate [$x, $y] (convenience)</p>
  700. <code class="phpdocumentor-code phpdocumentor-signature ">
  701. <span class="phpdocumentor-signature__visibility">protected</span>
  702. <span class="phpdocumentor-signature__name">getModuleValueAt</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$x</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">$y</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed|null</span></code>
  703. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  704. <dl class="phpdocumentor-argument-list">
  705. <dt class="phpdocumentor-argument-list__entry">
  706. <span class="phpdocumentor-signature__argument__name">$x</span>
  707. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  708. </dt>
  709. <dd class="phpdocumentor-argument-list__definition">
  710. <section class="phpdocumentor-description"></section>
  711. </dd>
  712. <dt class="phpdocumentor-argument-list__entry">
  713. <span class="phpdocumentor-signature__argument__name">$y</span>
  714. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  715. </dt>
  716. <dd class="phpdocumentor-argument-list__definition">
  717. <section class="phpdocumentor-description"></section>
  718. </dd>
  719. </dl>
  720. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  721. <span class="phpdocumentor-signature__response_type">mixed|null</span>
  722. &mdash;
  723. </article>
  724. <article
  725. class="phpdocumentor-element
  726. -method
  727. -protected
  728. "
  729. >
  730. <h4 class="phpdocumentor-element__name" id="method_json">
  731. json()
  732. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_json" class="headerlink"><i class="fas fa-link"></i></a>
  733. </h4>
  734. <aside class="phpdocumentor-element-found-in">
  735. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRString.php"><a href="files/src-output-qrstring.html"><abbr title="src/Output/QRString.php">QRString.php</abbr></a></abbr>
  736. :
  737. <span class="phpdocumentor-element-found-in__line">85</span>
  738. </aside>
  739. <p class="phpdocumentor-summary">JSON output</p>
  740. <code class="phpdocumentor-code phpdocumentor-signature ">
  741. <span class="phpdocumentor-signature__visibility">protected</span>
  742. <span class="phpdocumentor-signature__name">json</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
  743. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  744. <span class="phpdocumentor-signature__response_type">string</span>
  745. &mdash;
  746. </article>
  747. <article
  748. class="phpdocumentor-element
  749. -method
  750. -protected
  751. "
  752. >
  753. <h4 class="phpdocumentor-element__name" id="method_prepareModuleValue">
  754. prepareModuleValue()
  755. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_prepareModuleValue" class="headerlink"><i class="fas fa-link"></i></a>
  756. </h4>
  757. <aside class="phpdocumentor-element-found-in">
  758. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRString.php"><a href="files/src-output-qrstring.html"><abbr title="src/Output/QRString.php">QRString.php</abbr></a></abbr>
  759. :
  760. <span class="phpdocumentor-element-found-in__line">33</span>
  761. </aside>
  762. <p class="phpdocumentor-summary">Prepares the value for the given input ()</p>
  763. <code class="phpdocumentor-code phpdocumentor-signature ">
  764. <span class="phpdocumentor-signature__visibility">protected</span>
  765. <span class="phpdocumentor-signature__name">prepareModuleValue</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">mixed&nbsp;</span><span class="phpdocumentor-signature__argument__name">$value</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed|null</span></code>
  766. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  767. <dl class="phpdocumentor-argument-list">
  768. <dt class="phpdocumentor-argument-list__entry">
  769. <span class="phpdocumentor-signature__argument__name">$value</span>
  770. : <span class="phpdocumentor-signature__argument__return-type">mixed</span>
  771. </dt>
  772. <dd class="phpdocumentor-argument-list__definition">
  773. </dd>
  774. </dl>
  775. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  776. Tags
  777. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  778. </h5>
  779. <dl class="phpdocumentor-tag-list">
  780. <dt class="phpdocumentor-tag-list__entry">
  781. <span class="phpdocumentor-tag__name">inheritDoc</span>
  782. </dt>
  783. <dd class="phpdocumentor-tag-list__definition">
  784. </dd>
  785. </dl>
  786. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  787. <span class="phpdocumentor-signature__response_type">mixed|null</span>
  788. &mdash;
  789. <section class="phpdocumentor-description"><p>return value depends on the output class</p>
  790. </section>
  791. </article>
  792. <article
  793. class="phpdocumentor-element
  794. -method
  795. -protected
  796. "
  797. >
  798. <h4 class="phpdocumentor-element__name" id="method_saveToFile">
  799. saveToFile()
  800. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_saveToFile" class="headerlink"><i class="fas fa-link"></i></a>
  801. </h4>
  802. <aside class="phpdocumentor-element-found-in">
  803. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  804. :
  805. <span class="phpdocumentor-element-found-in__line">150</span>
  806. </aside>
  807. <p class="phpdocumentor-summary">Saves the qr $data to a $file. If $file is null, nothing happens.</p>
  808. <code class="phpdocumentor-code phpdocumentor-signature ">
  809. <span class="phpdocumentor-signature__visibility">protected</span>
  810. <span class="phpdocumentor-signature__name">saveToFile</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 class="phpdocumentor-signature__argument"><span>[</span><span>, </span><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$file</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">null</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  811. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  812. <dl class="phpdocumentor-argument-list">
  813. <dt class="phpdocumentor-argument-list__entry">
  814. <span class="phpdocumentor-signature__argument__name">$data</span>
  815. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  816. </dt>
  817. <dd class="phpdocumentor-argument-list__definition">
  818. <section class="phpdocumentor-description"></section>
  819. </dd>
  820. <dt class="phpdocumentor-argument-list__entry">
  821. <span class="phpdocumentor-signature__argument__name">$file</span>
  822. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  823. = <span class="phpdocumentor-signature__argument__default-value">null</span> </dt>
  824. <dd class="phpdocumentor-argument-list__definition">
  825. <section class="phpdocumentor-description"></section>
  826. </dd>
  827. </dl>
  828. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  829. Tags
  830. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  831. </h5>
  832. <dl class="phpdocumentor-tag-list">
  833. <dt class="phpdocumentor-tag-list__entry">
  834. <span class="phpdocumentor-tag__name">see</span>
  835. </dt>
  836. <dd class="phpdocumentor-tag-list__definition">
  837. <span class="phpdocumentor-tag-link"><abbr title="\chillerlan\QRCode\Output\file_put_contents()">file_put_contents()</abbr></span>
  838. </dd>
  839. <dt class="phpdocumentor-tag-list__entry">
  840. <span class="phpdocumentor-tag__name">see</span>
  841. </dt>
  842. <dd class="phpdocumentor-tag-list__definition">
  843. <span class="phpdocumentor-tag-link"><abbr title="\chillerlan\QRCode\QROptions::$cachefile">QROptions::$cachefile</abbr></span>
  844. </dd>
  845. <dt class="phpdocumentor-tag-list__entry">
  846. <span class="phpdocumentor-tag__name">throws</span>
  847. </dt>
  848. <dd class="phpdocumentor-tag-list__definition">
  849. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Output-QRCodeOutputException.html"><abbr title="\chillerlan\QRCode\Output\QRCodeOutputException">QRCodeOutputException</abbr></a></span>
  850. </dd>
  851. </dl>
  852. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  853. <span class="phpdocumentor-signature__response_type">void</span>
  854. &mdash;
  855. </article>
  856. <article
  857. class="phpdocumentor-element
  858. -method
  859. -protected
  860. "
  861. >
  862. <h4 class="phpdocumentor-element__name" id="method_setMatrixDimensions">
  863. setMatrixDimensions()
  864. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_setMatrixDimensions" class="headerlink"><i class="fas fa-link"></i></a>
  865. </h4>
  866. <aside class="phpdocumentor-element-found-in">
  867. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  868. :
  869. <span class="phpdocumentor-element-found-in__line">73</span>
  870. </aside>
  871. <p class="phpdocumentor-summary">Sets/updates the matrix dimensions</p>
  872. <code class="phpdocumentor-code phpdocumentor-signature ">
  873. <span class="phpdocumentor-signature__visibility">protected</span>
  874. <span class="phpdocumentor-signature__name">setMatrixDimensions</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  875. <section class="phpdocumentor-description"><p>Call this method if you modify the matrix from within your custom module in case the dimensions have been changed</p>
  876. </section>
  877. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  878. <span class="phpdocumentor-signature__response_type">void</span>
  879. &mdash;
  880. </article>
  881. <article
  882. class="phpdocumentor-element
  883. -method
  884. -protected
  885. "
  886. >
  887. <h4 class="phpdocumentor-element__name" id="method_setModuleValues">
  888. setModuleValues()
  889. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_setModuleValues" class="headerlink"><i class="fas fa-link"></i></a>
  890. </h4>
  891. <aside class="phpdocumentor-element-found-in">
  892. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  893. :
  894. <span class="phpdocumentor-element-found-in__line">82</span>
  895. </aside>
  896. <p class="phpdocumentor-summary">Sets the initial module values</p>
  897. <code class="phpdocumentor-code phpdocumentor-signature ">
  898. <span class="phpdocumentor-signature__visibility">protected</span>
  899. <span class="phpdocumentor-signature__name">setModuleValues</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  900. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  901. <span class="phpdocumentor-signature__response_type">void</span>
  902. &mdash;
  903. </article>
  904. <article
  905. class="phpdocumentor-element
  906. -method
  907. -protected
  908. "
  909. >
  910. <h4 class="phpdocumentor-element__name" id="method_text">
  911. text()
  912. <a href="classes/chillerlan-QRCode-Output-QRString.html#method_text" class="headerlink"><i class="fas fa-link"></i></a>
  913. </h4>
  914. <aside class="phpdocumentor-element-found-in">
  915. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRString.php"><a href="files/src-output-qrstring.html"><abbr title="src/Output/QRString.php">QRString.php</abbr></a></abbr>
  916. :
  917. <span class="phpdocumentor-element-found-in__line">66</span>
  918. </aside>
  919. <p class="phpdocumentor-summary">string output</p>
  920. <code class="phpdocumentor-code phpdocumentor-signature ">
  921. <span class="phpdocumentor-signature__visibility">protected</span>
  922. <span class="phpdocumentor-signature__name">text</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
  923. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  924. <span class="phpdocumentor-signature__response_type">string</span>
  925. &mdash;
  926. </article>
  927. <article
  928. class="phpdocumentor-element
  929. -method
  930. -protected
  931. "
  932. >
  933. <h4 class="phpdocumentor-element__name" id="method_toBase64DataURI">
  934. toBase64DataURI()
  935. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_toBase64DataURI" class="headerlink"><i class="fas fa-link"></i></a>
  936. </h4>
  937. <aside class="phpdocumentor-element-found-in">
  938. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  939. :
  940. <span class="phpdocumentor-element-found-in__line">138</span>
  941. </aside>
  942. <p class="phpdocumentor-summary">Returns a base64 data URI for the given string and mime type</p>
  943. <code class="phpdocumentor-code phpdocumentor-signature ">
  944. <span class="phpdocumentor-signature__visibility">protected</span>
  945. <span class="phpdocumentor-signature__name">toBase64DataURI</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 class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$mime</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
  946. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  947. <dl class="phpdocumentor-argument-list">
  948. <dt class="phpdocumentor-argument-list__entry">
  949. <span class="phpdocumentor-signature__argument__name">$data</span>
  950. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  951. </dt>
  952. <dd class="phpdocumentor-argument-list__definition">
  953. <section class="phpdocumentor-description"></section>
  954. </dd>
  955. <dt class="phpdocumentor-argument-list__entry">
  956. <span class="phpdocumentor-signature__argument__name">$mime</span>
  957. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  958. </dt>
  959. <dd class="phpdocumentor-argument-list__definition">
  960. <section class="phpdocumentor-description"></section>
  961. </dd>
  962. </dl>
  963. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  964. <span class="phpdocumentor-signature__response_type">string</span>
  965. &mdash;
  966. </article>
  967. </section>
  968. <script type="text/javascript">
  969. function loadExternalCodeSnippets(line) {
  970. Array.prototype.slice.call(document.querySelectorAll('pre[data-src]')).forEach((pre) => {
  971. var src = pre.getAttribute('data-src').replace( /\\/g, '/');
  972. var extension = (src.match(/\.(\w+)$/) || [, ''])[1];
  973. var language = 'php';
  974. var code = document.createElement('code');
  975. code.className = 'language-' + language;
  976. pre.textContent = '';
  977. pre.setAttribute('data-line', line)
  978. code.textContent = 'Loading…';
  979. pre.appendChild(code);
  980. var xhr = new XMLHttpRequest();
  981. xhr.open('GET', src, true);
  982. xhr.onreadystatechange = function () {
  983. if (xhr.readyState == 4) {
  984. if (xhr.status < 400 && xhr.responseText) {
  985. code.textContent = xhr.responseText;
  986. Prism.highlightElement(code);
  987. }
  988. else if (xhr.status >= 400) {
  989. code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
  990. }
  991. else {
  992. code.textContent = '✖ Error: File does not exist, is empty or trying to view from localhost';
  993. }
  994. }
  995. };
  996. xhr.send(null);
  997. });
  998. }
  999. var modals = document.querySelectorAll("[data-modal]");
  1000. modals.forEach(function (trigger) {
  1001. trigger.addEventListener("click", function (event) {
  1002. //event.preventDefault();
  1003. const modal = document.getElementById(trigger.dataset.modal);
  1004. modal.classList.add("phpdocumentor-modal__open");
  1005. loadExternalCodeSnippets(trigger.dataset.line)
  1006. const exits = modal.querySelectorAll("[data-exit-button]");
  1007. exits.forEach(function (exit) {
  1008. exit.addEventListener("click", function (event) {
  1009. event.preventDefault();
  1010. modal.classList.remove("phpdocumentor-modal__open");
  1011. });
  1012. });
  1013. });
  1014. });
  1015. </script>
  1016. </article>
  1017. <section data-search-results class="phpdocumentor-search-results phpdocumentor-search-results--hidden">
  1018. <section class="phpdocumentor-search-results__dialog">
  1019. <header class="phpdocumentor-search-results__header">
  1020. <h2 class="phpdocumentor-search-results__title">Search results</h2>
  1021. <button class="phpdocumentor-search-results__close"><i class="fas fa-times"></i></button>
  1022. </header>
  1023. <section class="phpdocumentor-search-results__body">
  1024. <ul class="phpdocumentor-search-results__entries"></ul>
  1025. </section>
  1026. </section>
  1027. </section>
  1028. </div>
  1029. </div>
  1030. <a href="classes/chillerlan-QRCode-Output-QRString.html#top" class="phpdocumentor-back-to-top"><i class="fas fa-chevron-circle-up"></i></a>
  1031. </main>
  1032. <script>
  1033. cssVars({});
  1034. </script>
  1035. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/prism.min.js"></script>
  1036. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/autoloader/prism-autoloader.min.js"></script>
  1037. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.min.js"></script>
  1038. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.min.js"></script>
  1039. </body>
  1040. </html>