1 | <!DOCTYPE html>
|
2 |
|
3 | <html lang="en">
|
4 | <head>
|
5 | <meta charset="utf-8">
|
6 | <meta name="viewport" content="width=device-width">
|
7 | <title>CrossBrowdy API documentation Namespace: CB_Arrays</title>
|
8 |
|
9 | |
10 |
|
11 |
|
12 | <link type="text/css" rel="stylesheet" href="styles/sunlight.default.css">
|
13 |
|
14 | <link type="text/css" rel="stylesheet" href="styles/site.cosmo.css">
|
15 |
|
16 | </head>
|
17 |
|
18 | <body style="min-width:800px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
19 |
|
20 | <div class="navbar navbar-default navbar-fixed-top ">
|
21 | <div class="container">
|
22 | <div class="navbar-header">
|
23 | <a class="navbar-brand" href="index.html">CrossBrowdy API documentation</a>
|
24 | <button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#topNavigation">
|
25 | <span class="icon-bar"></span>
|
26 | <span class="icon-bar"></span>
|
27 | <span class="icon-bar"></span>
|
28 | </button>
|
29 | </div>
|
30 | <div class="navbar-collapse collapse" id="topNavigation">
|
31 | <ul class="nav navbar-nav">
|
32 |
|
33 | <li class="dropdown">
|
34 | <a href="namespaces.list.html" class="dropdown-toggle" data-toggle="dropdown">Namespaces<b class="caret"></b></a>
|
35 | <ul class="dropdown-menu inline">
|
36 | <li><a href="CB_Arrays.html">CB_Arrays</a></li><li><a href="CB_AudioDetector.html">CB_AudioDetector</a></li><li><a href="CB_baseSymbols.html">CB_baseSymbols</a></li><li><a href="CB_Client.html">CB_Client</a></li><li><a href="CB_Collisions.html">CB_Collisions</a></li><li><a href="CB_Configuration.html">CB_Configuration</a></li><li><a href="CB_Configuration.CrossBase.html">CB_Configuration.CrossBase</a></li><li><a href="CB_Configuration.CrossBrowdy.html">CB_Configuration.CrossBrowdy</a></li><li><a href="CB_Controllers.html">CB_Controllers</a></li><li><a href="CB_Controllers_Proprietary.html">CB_Controllers_Proprietary</a></li><li><a href="CB_Controllers_Proprietary.WII.html">CB_Controllers_Proprietary.WII</a></li><li><a href="CB_Controllers_Proprietary.WII_U.html">CB_Controllers_Proprietary.WII_U</a></li><li><a href="CB_Device.html">CB_Device</a></li><li><a href="CB_Device.AmbientLight.html">CB_Device.AmbientLight</a></li><li><a href="CB_Device.Battery.html">CB_Device.Battery</a></li><li><a href="CB_Device.Location.html">CB_Device.Location</a></li><li><a href="CB_Device.Motion.html">CB_Device.Motion</a></li><li><a href="CB_Device.Orientation.html">CB_Device.Orientation</a></li><li><a href="CB_Device.Proximity.html">CB_Device.Proximity</a></li><li><a href="CB_Device.Vibration.html">CB_Device.Vibration</a></li><li><a href="CB_Elements.html">CB_Elements</a></li><li><a href="CB_Events.html">CB_Events</a></li><li><a href="CB_Keyboard.html">CB_Keyboard</a></li><li><a href="CB_Keyboard.chars.html">CB_Keyboard.chars</a></li><li><a href="CB_Keyboard.extended.html">CB_Keyboard.extended</a></li><li><a href="CB_Keyboard.keys.html">CB_Keyboard.keys</a></li><li><a href="CB_Modules.html">CB_Modules</a></li><li><a href="CB_Mouse.html">CB_Mouse</a></li><li><a href="CB_Mouse.CursorImage.html">CB_Mouse.CursorImage</a></li><li><a href="CB_Net.html">CB_Net</a></li><li><a href="CB_Net.Fetch.html">CB_Net.Fetch</a></li><li><a href="CB_Net.REST.html">CB_Net.REST</a></li><li><a href="CB_Net.Sockets.html">CB_Net.Sockets</a></li><li><a href="CB_Net.Sockets.SockJS.html">CB_Net.Sockets.SockJS</a></li><li><a href="CB_Net.XHR.html">CB_Net.XHR</a></li><li><a href="CB_Pointer.html">CB_Pointer</a></li><li><a href="CB_Screen.html">CB_Screen</a></li><li><a href="CB_Speaker.html">CB_Speaker</a></li><li><a href="CB_Touch.html">CB_Touch</a></li>
|
37 | </ul>
|
38 | </li>
|
39 |
|
40 | <li class="dropdown">
|
41 | <a href="classes.list.html" class="dropdown-toggle" data-toggle="dropdown">Classes<b class="caret"></b></a>
|
42 | <ul class="dropdown-menu inline">
|
43 | <li><a href="CB_AudioFile.html">CB_AudioFile</a></li><li><a href="CB_AudioFile_API.AAPI.html">CB_AudioFile_API.AAPI</a></li><li><a href="CB_AudioFile_API.ACMP.html">CB_AudioFile_API.ACMP</a></li><li><a href="CB_AudioFile_API.SM2.html">CB_AudioFile_API.SM2</a></li><li><a href="CB_AudioFile_API.WAAPI.html">CB_AudioFile_API.WAAPI</a></li><li><a href="CB_AudioFileCache.html">CB_AudioFileCache</a></li><li><a href="CB_AudioFileSprites.html">CB_AudioFileSprites</a></li><li><a href="CB_AudioFileSpritesPool.html">CB_AudioFileSpritesPool</a></li><li><a href="CB_Canvas.html">CB_Canvas</a></li><li><a href="CB_GraphicSprites.html">CB_GraphicSprites</a></li><li><a href="CB_GraphicSpritesScene.html">CB_GraphicSpritesScene</a></li>
|
44 | </ul>
|
45 | </li>
|
46 |
|
47 | <li class="dropdown">
|
48 | <a href="global.html" class="dropdown-toggle" data-toggle="dropdown">Global<b class="caret"></b></a>
|
49 | <ul class="dropdown-menu inline">
|
50 | <li><a href="global.html#CB_addCredits">CB_addCredits</a></li><li><a href="global.html#CB_BASE_NAME">CB_BASE_NAME</a></li><li><a href="global.html#CB_baseToBase">CB_baseToBase</a></li><li><a href="global.html#CB_baseToInt">CB_baseToInt</a></li><li><a href="global.html#CB_br2nl">CB_br2nl</a></li><li><a href="global.html#CB_brToNl">CB_brToNl</a></li><li><a href="global.html#CB_combineArraysOrObjects">CB_combineArraysOrObjects</a></li><li><a href="global.html#CB_combineAutomatically">CB_combineAutomatically</a></li><li><a href="global.html#CB_combineJSON">CB_combineJSON</a></li><li><a href="global.html#CB_combineURIParameters">CB_combineURIParameters</a></li><li><a href="global.html#CB_combineURLParameters">CB_combineURLParameters</a></li><li><a href="global.html#CB_console">CB_console</a></li><li><a href="global.html#CB_copyObject">CB_copyObject</a></li><li><a href="global.html#CB_countDecimalDigits">CB_countDecimalDigits</a></li><li><a href="global.html#CB_countDecimalPart">CB_countDecimalPart</a></li><li><a href="global.html#CB_countDecimals">CB_countDecimals</a></li><li><a href="global.html#CB_countIntegerDigits">CB_countIntegerDigits</a></li><li><a href="global.html#CB_countIntegerPart">CB_countIntegerPart</a></li><li><a href="global.html#CB_credits">CB_credits</a></li><li><a href="global.html#CB_CREDITS_DEFAULT">CB_CREDITS_DEFAULT</a></li><li><a href="global.html#CB_forceString">CB_forceString</a></li><li><a href="global.html#CB_forEach">CB_forEach</a></li><li><a href="global.html#CB_getBase64StringObject">CB_getBase64StringObject</a></li><li><a href="global.html#CB_getCookie">CB_getCookie</a></li><li><a href="global.html#CB_getDatum">CB_getDatum</a></li><li><a href="global.html#CB_getJSONPropertyValue">CB_getJSONPropertyValue</a></li><li><a href="global.html#CB_getLZStringObject">CB_getLZStringObject</a></li><li><a href="global.html#CB_getValueIndex">CB_getValueIndex</a></li><li><a href="global.html#CB_getValuePath">CB_getValuePath</a></li><li><a href="global.html#CB_includeJSFile">CB_includeJSFile</a></li><li><a href="global.html#CB_indexOf">CB_indexOf</a></li><li><a href="global.html#CB_init">CB_init</a></li><li><a href="global.html#CB_intToBase">CB_intToBase</a></li><li><a href="global.html#CB_isArray">CB_isArray</a></li><li><a href="global.html#CB_isEmail">CB_isEmail</a></li><li><a href="global.html#CB_isFileLocal">CB_isFileLocal</a></li><li><a href="global.html#CB_isString">CB_isString</a></li><li><a href="global.html#CB_lastIndexOf">CB_lastIndexOf</a></li><li><a href="global.html#CB_ltrim">CB_ltrim</a></li><li><a href="global.html#CB_NAME">CB_NAME</a></li><li><a href="global.html#CB_nl2br">CB_nl2br</a></li><li><a href="global.html#CB_nlToBr">CB_nlToBr</a></li><li><a href="global.html#CB_numberFormat">CB_numberFormat</a></li><li><a href="global.html#CB_numberOfDecimalDigits">CB_numberOfDecimalDigits</a></li><li><a href="global.html#CB_numberOfDecimals">CB_numberOfDecimals</a></li><li><a href="global.html#CB_numberOfIntegerDigits">CB_numberOfIntegerDigits</a></li><li><a href="global.html#CB_OPTIONS">CB_OPTIONS</a></li><li><a href="global.html#CB_parseJSON">CB_parseJSON</a></li><li><a href="global.html#CB_parseString">CB_parseString</a></li><li><a href="global.html#CB_regularExpressionString">CB_regularExpressionString</a></li><li><a href="global.html#CB_renderString">CB_renderString</a></li><li><a href="global.html#CB_replaceAll">CB_replaceAll</a></li><li><a href="global.html#CB_rtrim">CB_rtrim</a></li><li><a href="global.html#CB_scriptPath">CB_scriptPath</a></li><li><a href="global.html#CB_scriptPathCalculate">CB_scriptPathCalculate</a></li><li><a href="global.html#CB_setCookie">CB_setCookie</a></li><li><a href="global.html#CB_setDatum">CB_setDatum</a></li><li><a href="global.html#CB_sizeof">CB_sizeof</a></li><li><a href="global.html#CB_sizeOf">CB_sizeOf</a></li><li><a href="global.html#CB_stringifyJSON">CB_stringifyJSON</a></li><li><a href="global.html#CB_symmetricCall">CB_symmetricCall</a></li><li><a href="global.html#CB_symmetricCallClear">CB_symmetricCallClear</a></li><li><a href="global.html#CB_this">CB_this</a></li><li><a href="global.html#CB_trim">CB_trim</a></li><li><a href="global.html#CB_VERSION">CB_VERSION</a></li>
|
51 | </ul>
|
52 | </li>
|
53 |
|
54 | </ul>
|
55 |
|
56 | <div class="col-sm-3 col-md-3">
|
57 | <form class="navbar-form" role="search">
|
58 | <div class="input-group">
|
59 | <input type="text" class="form-control" placeholder="Search" name="q" id="search-input">
|
60 | <div class="input-group-btn">
|
61 | <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button>
|
62 | </div>
|
63 | </div>
|
64 | </form>
|
65 | </div>
|
66 |
|
67 | </div>
|
68 |
|
69 | </div>
|
70 | </div>
|
71 |
|
72 |
|
73 | <div class="container" id="toc-content" style="width:100%;">
|
74 | <div class="row" style="width:100%;">
|
75 |
|
76 |
|
77 | <div class="col-md-8" style="width:85%;">
|
78 |
|
79 | <div id="main">
|
80 |
|
81 |
|
82 |
|
83 | <h1 class="page-title">Namespace: CB_Arrays</h1>
|
84 |
|
85 | <section>
|
86 |
|
87 | <header>
|
88 |
|
89 | <h2>
|
90 | CB_Arrays
|
91 | </h2>
|
92 |
|
93 |
|
94 | </header>
|
95 |
|
96 |
|
97 | <article>
|
98 | <div class="container-overview">
|
99 |
|
100 |
|
101 | <div class="description"><p>Static class to manage arrays. It will return itself if it is tried to be instantiated.</p></div>
|
102 |
|
103 |
|
104 |
|
105 | <dl class="details">
|
106 |
|
107 |
|
108 |
|
109 |
|
110 |
|
111 |
|
112 |
|
113 |
|
114 |
|
115 |
|
116 |
|
117 |
|
118 |
|
119 |
|
120 |
|
121 |
|
122 |
|
123 |
|
124 |
|
125 |
|
126 |
|
127 |
|
128 |
|
129 |
|
130 |
|
131 |
|
132 |
|
133 |
|
134 |
|
135 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
136 | <dd class="tag-source">
|
137 | <ul class="dummy">
|
138 | <li>
|
139 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
140 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-22">line 22</a>
|
141 | </li>
|
142 | </ul>
|
143 | </dd>
|
144 |
|
145 |
|
146 |
|
147 |
|
148 |
|
149 |
|
150 |
|
151 | </dl>
|
152 |
|
153 |
|
154 |
|
155 |
|
156 | </div>
|
157 |
|
158 |
|
159 |
|
160 |
|
161 |
|
162 |
|
163 |
|
164 |
|
165 |
|
166 |
|
167 |
|
168 |
|
169 |
|
170 |
|
171 | <h3 class="subsection-title">Methods</h3>
|
172 |
|
173 | <dl>
|
174 |
|
175 | <hr>
|
176 | <dt>
|
177 | <h4 class="name" id=".bsort"><span class="type-signature"><static> </span>bsort<span class="signature">(array [, reversed])</span><span class="type-signature"> → {array}</span></h4>
|
178 |
|
179 |
|
180 | </dt>
|
181 | <dd>
|
182 |
|
183 |
|
184 | <div class="description">
|
185 | <p>Sorts an array using the <a href="https://en.wikipedia.org/wiki/Bubble_sort">bubble sort (sinking sort) method</a>. Internally, it uses the ">" operator for comparing values as they will be treated as numbers.</p>
|
186 | </div>
|
187 |
|
188 |
|
189 |
|
190 |
|
191 |
|
192 |
|
193 |
|
194 |
|
195 | <h5>Parameters:</h5>
|
196 |
|
197 |
|
198 | <table class="params table table-striped">
|
199 | <thead>
|
200 | <tr>
|
201 |
|
202 | <th style="width:12%; min-width:110px;">Name</th>
|
203 |
|
204 |
|
205 | <th style="width:12%; min-width:110px;">Type</th>
|
206 |
|
207 |
|
208 | <th style="width:12%; min-width:110px;">Argument</th>
|
209 |
|
210 |
|
211 |
|
212 | <th style="width:12%; min-width:110px;">Default</th>
|
213 |
|
214 |
|
215 | <th class="last" style="min-width:310px;">Description</th>
|
216 | </tr>
|
217 | </thead>
|
218 |
|
219 | <tbody>
|
220 |
|
221 |
|
222 | <tr>
|
223 |
|
224 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
225 |
|
226 |
|
227 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
228 |
|
229 |
|
230 | <span class="param-type">array</span>
|
231 |
|
232 |
|
233 |
|
234 |
|
235 | </td>
|
236 |
|
237 |
|
238 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
239 |
|
240 |
|
241 |
|
242 |
|
243 |
|
244 | </td>
|
245 |
|
246 |
|
247 |
|
248 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
249 |
|
250 | </td>
|
251 |
|
252 |
|
253 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The array whose elements we want to sort.</p></td>
|
254 | </tr>
|
255 |
|
256 |
|
257 |
|
258 | <tr>
|
259 |
|
260 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>reversed</code></td>
|
261 |
|
262 |
|
263 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
264 |
|
265 |
|
266 | <span class="param-type">boolean</span>
|
267 |
|
268 |
|
269 |
|
270 |
|
271 | </td>
|
272 |
|
273 |
|
274 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
275 |
|
276 | <optional><br>
|
277 |
|
278 |
|
279 |
|
280 |
|
281 |
|
282 | </td>
|
283 |
|
284 |
|
285 |
|
286 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
287 |
|
288 | false
|
289 |
|
290 | </td>
|
291 |
|
292 |
|
293 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether to sort in the reverse order or not.</p></td>
|
294 | </tr>
|
295 |
|
296 |
|
297 | </tbody>
|
298 | </table>
|
299 |
|
300 |
|
301 |
|
302 |
|
303 | <dl class="details">
|
304 |
|
305 |
|
306 |
|
307 |
|
308 |
|
309 |
|
310 |
|
311 |
|
312 |
|
313 |
|
314 |
|
315 |
|
316 |
|
317 |
|
318 |
|
319 |
|
320 |
|
321 |
|
322 |
|
323 |
|
324 |
|
325 |
|
326 |
|
327 |
|
328 |
|
329 |
|
330 |
|
331 |
|
332 |
|
333 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
334 | <dd class="tag-source">
|
335 | <ul class="dummy">
|
336 | <li>
|
337 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
338 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-400">line 400</a>
|
339 | </li>
|
340 | </ul>
|
341 | </dd>
|
342 |
|
343 |
|
344 |
|
345 |
|
346 |
|
347 |
|
348 |
|
349 | <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
|
350 | <dd class="tag-todo">
|
351 | <ul>
|
352 | <li>Think about accepting a comparing function (as the "sort" method).</li>
|
353 | </ul>
|
354 | </dd>
|
355 |
|
356 | </dl>
|
357 |
|
358 |
|
359 |
|
360 |
|
361 |
|
362 |
|
363 |
|
364 |
|
365 |
|
366 |
|
367 |
|
368 |
|
369 |
|
370 | <h5>Returns:</h5>
|
371 |
|
372 |
|
373 | <div class="param-desc">
|
374 | <p>Returns the array ordered. If another value which is not an array is given, it will be returned again.</p>
|
375 | </div>
|
376 |
|
377 |
|
378 |
|
379 | <dl>
|
380 | <dt>
|
381 | Type
|
382 | </dt>
|
383 | <dd>
|
384 |
|
385 | <span class="param-type">array</span>
|
386 |
|
387 |
|
388 |
|
389 | </dd>
|
390 | </dl>
|
391 |
|
392 |
|
393 |
|
394 |
|
395 |
|
396 | </dd>
|
397 |
|
398 |
|
399 |
|
400 | <hr>
|
401 | <dt>
|
402 | <h4 class="name" id=".combine"><span class="type-signature"><static> </span>combine<span class="signature">( [arrayOrObjectA] [, arrayOrObjectB], avoidDuplicatedValuesInArray [, modifyArrayOrObjectA])</span><span class="type-signature"> → {array|Object}</span></h4>
|
403 |
|
404 |
|
405 | </dt>
|
406 | <dd>
|
407 |
|
408 |
|
409 | <div class="description">
|
410 | <p>Returns a combined array or object from two arrays or objects. Using the following rules:<br> <br /><br> If they both are arrays (numeric indexes), it will keep all elements (attaching the elements of the second array after the elements of the first one).<br> <br /><br> Otherwise, if either of them is not an array (it should be an associative array which is an object in JavaScript), it will merge the elements (overwritting those whose index is the same and keeping the ones from the second array/object):</p>
|
411 | </div>
|
412 |
|
413 |
|
414 |
|
415 |
|
416 |
|
417 |
|
418 |
|
419 |
|
420 | <h5>Parameters:</h5>
|
421 |
|
422 |
|
423 | <table class="params table table-striped">
|
424 | <thead>
|
425 | <tr>
|
426 |
|
427 | <th style="width:12%; min-width:110px;">Name</th>
|
428 |
|
429 |
|
430 | <th style="width:12%; min-width:110px;">Type</th>
|
431 |
|
432 |
|
433 | <th style="width:12%; min-width:110px;">Argument</th>
|
434 |
|
435 |
|
436 |
|
437 | <th style="width:12%; min-width:110px;">Default</th>
|
438 |
|
439 |
|
440 | <th class="last" style="min-width:310px;">Description</th>
|
441 | </tr>
|
442 | </thead>
|
443 |
|
444 | <tbody>
|
445 |
|
446 |
|
447 | <tr>
|
448 |
|
449 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>arrayOrObjectA</code></td>
|
450 |
|
451 |
|
452 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
453 |
|
454 |
|
455 | <span class="param-type">array</span>
|
456 | |
|
457 |
|
458 | <span class="param-type">Object</span>
|
459 | |
|
460 |
|
461 | <span class="param-type">string</span>
|
462 | |
|
463 |
|
464 | <span class="param-type">null</span>
|
465 | |
|
466 |
|
467 | <span class="param-type">undefined</span>
|
468 |
|
469 |
|
470 |
|
471 |
|
472 | </td>
|
473 |
|
474 |
|
475 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
476 |
|
477 | <optional><br>
|
478 |
|
479 |
|
480 |
|
481 |
|
482 |
|
483 | </td>
|
484 |
|
485 |
|
486 |
|
487 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
488 |
|
489 | []|{}
|
490 |
|
491 | </td>
|
492 |
|
493 |
|
494 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>One of the arrays (numeric indexes) or associative arrays (object) that we want to combine. If a string is provided, it will try to convert it into a new object (the string should be a JSON-valid string). It can be optional if "arrayOrObjectB" is a valid value and neither null nor undefined. If not provided but the "arrayOrObjectB" is provided, it will be a new empty array if the "arrayOrObjectB" is an array or it will be an empty object otherwise.</p></td>
|
495 | </tr>
|
496 |
|
497 |
|
498 |
|
499 | <tr>
|
500 |
|
501 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>arrayOrObjectB</code></td>
|
502 |
|
503 |
|
504 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
505 |
|
506 |
|
507 | <span class="param-type">array</span>
|
508 | |
|
509 |
|
510 | <span class="param-type">Object</span>
|
511 | |
|
512 |
|
513 | <span class="param-type">string</span>
|
514 | |
|
515 |
|
516 | <span class="param-type">null</span>
|
517 | |
|
518 |
|
519 | <span class="param-type">undefined</span>
|
520 |
|
521 |
|
522 |
|
523 |
|
524 | </td>
|
525 |
|
526 |
|
527 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
528 |
|
529 | <optional><br>
|
530 |
|
531 |
|
532 |
|
533 |
|
534 |
|
535 | </td>
|
536 |
|
537 |
|
538 |
|
539 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
540 |
|
541 | []|{}
|
542 |
|
543 | </td>
|
544 |
|
545 |
|
546 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>One of the arrays (numeric indexes) or associative arrays (object) that we want to combine. If a string is provided, it will try to convert it into a new object (the string should be a JSON-valid string). It can be optional if "arrayOrObjectA" is a valid value and neither null nor undefined. If not provided but the "arrayOrObjectA" is provided, it will be a new empty array if the "arrayOrObjectA" is an array or it will be an empty object otherwise.</p></td>
|
547 | </tr>
|
548 |
|
549 |
|
550 |
|
551 | <tr>
|
552 |
|
553 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>avoidDuplicatedValuesInArray</code></td>
|
554 |
|
555 |
|
556 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
557 |
|
558 |
|
559 | <span class="param-type">boolean</span>
|
560 |
|
561 |
|
562 |
|
563 |
|
564 | </td>
|
565 |
|
566 |
|
567 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
568 |
|
569 |
|
570 |
|
571 |
|
572 |
|
573 | </td>
|
574 |
|
575 |
|
576 |
|
577 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
578 |
|
579 | </td>
|
580 |
|
581 |
|
582 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Tells whether to avoid or allow items with duplicated values in the returned array or not. Only applies when both arrays to combine are numeric arrays.</p></td>
|
583 | </tr>
|
584 |
|
585 |
|
586 |
|
587 | <tr>
|
588 |
|
589 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>modifyArrayOrObjectA</code></td>
|
590 |
|
591 |
|
592 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
593 |
|
594 |
|
595 | <span class="param-type">boolean</span>
|
596 |
|
597 |
|
598 |
|
599 |
|
600 | </td>
|
601 |
|
602 |
|
603 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
604 |
|
605 | <optional><br>
|
606 |
|
607 |
|
608 |
|
609 |
|
610 |
|
611 | </td>
|
612 |
|
613 |
|
614 |
|
615 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
616 |
|
617 | false
|
618 |
|
619 | </td>
|
620 |
|
621 |
|
622 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Parameter that will be used in the case that <a href="global.html#CB_combineJSON"><code>CB_combineJSON</code></a> or <a href="global.html#CB_combineArraysOrObjects"><code>CB_combineArraysOrObjects</code></a> is called. If set to true, it will modify the original "arrayOrObjectA" array or object.</p></td>
|
623 | </tr>
|
624 |
|
625 |
|
626 | </tbody>
|
627 | </table>
|
628 |
|
629 |
|
630 |
|
631 |
|
632 | <dl class="details">
|
633 |
|
634 |
|
635 |
|
636 |
|
637 |
|
638 |
|
639 |
|
640 |
|
641 |
|
642 |
|
643 |
|
644 |
|
645 |
|
646 |
|
647 |
|
648 |
|
649 |
|
650 |
|
651 |
|
652 |
|
653 |
|
654 |
|
655 |
|
656 |
|
657 |
|
658 |
|
659 |
|
660 |
|
661 |
|
662 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
663 | <dd class="tag-source">
|
664 | <ul class="dummy">
|
665 | <li>
|
666 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
667 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1007">line 1007</a>
|
668 | </li>
|
669 | </ul>
|
670 | </dd>
|
671 |
|
672 |
|
673 |
|
674 |
|
675 |
|
676 |
|
677 |
|
678 | </dl>
|
679 |
|
680 |
|
681 |
|
682 |
|
683 |
|
684 |
|
685 |
|
686 |
|
687 |
|
688 |
|
689 |
|
690 |
|
691 |
|
692 | <h5>Returns:</h5>
|
693 |
|
694 |
|
695 |
|
696 |
|
697 | <dl>
|
698 | <dt>
|
699 | Type
|
700 | </dt>
|
701 | <dd>
|
702 |
|
703 | <span class="param-type">array</span>
|
704 | |
|
705 |
|
706 | <span class="param-type">Object</span>
|
707 |
|
708 |
|
709 |
|
710 | </dd>
|
711 | </dl>
|
712 |
|
713 |
|
714 |
|
715 |
|
716 |
|
717 | </dd>
|
718 |
|
719 |
|
720 |
|
721 | <hr>
|
722 | <dt>
|
723 | <h4 class="name" id=".copy"><span class="type-signature"><static> </span>copy<span class="signature">(array)</span><span class="type-signature"> → {object}</span></h4>
|
724 |
|
725 |
|
726 | </dt>
|
727 | <dd>
|
728 |
|
729 |
|
730 | <div class="description">
|
731 | <p>Returns an array copied from the given one. It will also make a copy of the arrays found in the values (if any), calling itself recursively.</p>
|
732 | </div>
|
733 |
|
734 |
|
735 |
|
736 |
|
737 |
|
738 |
|
739 |
|
740 |
|
741 | <h5>Parameters:</h5>
|
742 |
|
743 |
|
744 | <table class="params table table-striped">
|
745 | <thead>
|
746 | <tr>
|
747 |
|
748 | <th style="width:12%; min-width:110px;">Name</th>
|
749 |
|
750 |
|
751 | <th style="width:12%; min-width:110px;">Type</th>
|
752 |
|
753 |
|
754 |
|
755 |
|
756 |
|
757 | <th class="last" style="min-width:310px;">Description</th>
|
758 | </tr>
|
759 | </thead>
|
760 |
|
761 | <tbody>
|
762 |
|
763 |
|
764 | <tr>
|
765 |
|
766 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
767 |
|
768 |
|
769 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
770 |
|
771 |
|
772 | <span class="param-type">array</span>
|
773 |
|
774 |
|
775 |
|
776 |
|
777 | </td>
|
778 |
|
779 |
|
780 |
|
781 |
|
782 |
|
783 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The array whose values we want to copy.</p></td>
|
784 | </tr>
|
785 |
|
786 |
|
787 | </tbody>
|
788 | </table>
|
789 |
|
790 |
|
791 |
|
792 |
|
793 | <dl class="details">
|
794 |
|
795 |
|
796 |
|
797 |
|
798 |
|
799 |
|
800 |
|
801 |
|
802 |
|
803 |
|
804 |
|
805 |
|
806 |
|
807 |
|
808 |
|
809 |
|
810 |
|
811 |
|
812 |
|
813 |
|
814 |
|
815 |
|
816 |
|
817 |
|
818 |
|
819 |
|
820 |
|
821 |
|
822 |
|
823 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
824 | <dd class="tag-source">
|
825 | <ul class="dummy">
|
826 | <li>
|
827 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
828 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-238">line 238</a>
|
829 | </li>
|
830 | </ul>
|
831 | </dd>
|
832 |
|
833 |
|
834 |
|
835 |
|
836 |
|
837 |
|
838 |
|
839 | </dl>
|
840 |
|
841 |
|
842 |
|
843 |
|
844 |
|
845 |
|
846 |
|
847 |
|
848 |
|
849 |
|
850 |
|
851 |
|
852 |
|
853 | <h5>Returns:</h5>
|
854 |
|
855 |
|
856 | <div class="param-desc">
|
857 | <p>Returns an array copied from the given one. Returns an empty array if the given "array" was not an array.</p>
|
858 | </div>
|
859 |
|
860 |
|
861 |
|
862 | <dl>
|
863 | <dt>
|
864 | Type
|
865 | </dt>
|
866 | <dd>
|
867 |
|
868 | <span class="param-type">object</span>
|
869 |
|
870 |
|
871 |
|
872 | </dd>
|
873 | </dl>
|
874 |
|
875 |
|
876 |
|
877 |
|
878 |
|
879 | </dd>
|
880 |
|
881 |
|
882 |
|
883 | <hr>
|
884 | <dt>
|
885 | <h4 class="name" id=".count"><span class="type-signature"><static> </span>count<span class="signature">()</span><span class="type-signature"></span></h4>
|
886 |
|
887 |
|
888 | </dt>
|
889 | <dd>
|
890 |
|
891 |
|
892 | <div class="description">
|
893 | <p>Alias for <a href="CB_Arrays.html#.sizeOf"><code>CB_Arrays.sizeOf</code></a>.</p>
|
894 | </div>
|
895 |
|
896 |
|
897 |
|
898 |
|
899 |
|
900 |
|
901 |
|
902 |
|
903 |
|
904 |
|
905 | <dl class="details">
|
906 |
|
907 |
|
908 |
|
909 |
|
910 |
|
911 |
|
912 |
|
913 |
|
914 |
|
915 |
|
916 |
|
917 |
|
918 |
|
919 |
|
920 |
|
921 |
|
922 |
|
923 |
|
924 |
|
925 |
|
926 |
|
927 |
|
928 |
|
929 |
|
930 |
|
931 |
|
932 |
|
933 |
|
934 |
|
935 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
936 | <dd class="tag-source">
|
937 | <ul class="dummy">
|
938 | <li>
|
939 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
940 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-66">line 66</a>
|
941 | </li>
|
942 | </ul>
|
943 | </dd>
|
944 |
|
945 |
|
946 |
|
947 |
|
948 |
|
949 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
950 | <dd class="tag-see">
|
951 | <ul>
|
952 | <li><a href="CB_Arrays.html#.sizeOf"><code>CB_Arrays.sizeOf</code></a></li>
|
953 | </ul>
|
954 | </dd>
|
955 |
|
956 |
|
957 |
|
958 | </dl>
|
959 |
|
960 |
|
961 |
|
962 |
|
963 |
|
964 |
|
965 |
|
966 |
|
967 |
|
968 |
|
969 |
|
970 |
|
971 |
|
972 |
|
973 |
|
974 | </dd>
|
975 |
|
976 |
|
977 |
|
978 | <hr>
|
979 | <dt>
|
980 | <h4 class="name" id=".executeFunctionAll"><span class="type-signature"><static> </span>executeFunctionAll<span class="signature">(array, functionEach [, delayBetweenEach] [, returnSetTimeoutsArray] [, delayBetweenEachAffectsFirst] [, functionFinish])</span><span class="type-signature"> → {integer|array}</span></h4>
|
981 |
|
982 |
|
983 | </dt>
|
984 | <dd>
|
985 |
|
986 |
|
987 | <div class="description">
|
988 | <p>Performs a desired action, using the provided function, on all the existing elements of a given array. Elements which are undefined or null will be skipped without calling the "functionEach" function.</p>
|
989 | </div>
|
990 |
|
991 |
|
992 |
|
993 |
|
994 |
|
995 |
|
996 |
|
997 |
|
998 | <h5>Parameters:</h5>
|
999 |
|
1000 |
|
1001 | <table class="params table table-striped">
|
1002 | <thead>
|
1003 | <tr>
|
1004 |
|
1005 | <th style="width:12%; min-width:110px;">Name</th>
|
1006 |
|
1007 |
|
1008 | <th style="width:12%; min-width:110px;">Type</th>
|
1009 |
|
1010 |
|
1011 | <th style="width:12%; min-width:110px;">Argument</th>
|
1012 |
|
1013 |
|
1014 |
|
1015 | <th style="width:12%; min-width:110px;">Default</th>
|
1016 |
|
1017 |
|
1018 | <th class="last" style="min-width:310px;">Description</th>
|
1019 | </tr>
|
1020 | </thead>
|
1021 |
|
1022 | <tbody>
|
1023 |
|
1024 |
|
1025 | <tr>
|
1026 |
|
1027 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
1028 |
|
1029 |
|
1030 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1031 |
|
1032 |
|
1033 | <span class="param-type">array</span>
|
1034 |
|
1035 |
|
1036 |
|
1037 |
|
1038 | </td>
|
1039 |
|
1040 |
|
1041 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1042 |
|
1043 |
|
1044 |
|
1045 |
|
1046 |
|
1047 | </td>
|
1048 |
|
1049 |
|
1050 |
|
1051 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1052 |
|
1053 | </td>
|
1054 |
|
1055 |
|
1056 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>A numeric array containing the elements that we want to loop.</p></td>
|
1057 | </tr>
|
1058 |
|
1059 |
|
1060 |
|
1061 | <tr>
|
1062 |
|
1063 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>functionEach</code></td>
|
1064 |
|
1065 |
|
1066 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1067 |
|
1068 |
|
1069 | <span class="param-type"><a href="CB_Arrays.html#.executeFunctionAll_ON_LOOP_CALLBACK">CB_Arrays.executeFunctionAll_ON_LOOP_CALLBACK</a></span>
|
1070 |
|
1071 |
|
1072 |
|
1073 |
|
1074 | </td>
|
1075 |
|
1076 |
|
1077 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1078 |
|
1079 |
|
1080 |
|
1081 |
|
1082 |
|
1083 | </td>
|
1084 |
|
1085 |
|
1086 |
|
1087 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1088 |
|
1089 | </td>
|
1090 |
|
1091 |
|
1092 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function that will be called for each element of the given array. As the first parameter it receives the element of the "array" provided being looped, as the second parameter the position of this element in the "array" provided, the third parameter is the array being looped and the fourth parameter will be the "delayBetweenEach" being used, being "this" the element itself.</p></td>
|
1093 | </tr>
|
1094 |
|
1095 |
|
1096 |
|
1097 | <tr>
|
1098 |
|
1099 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>delayBetweenEach</code></td>
|
1100 |
|
1101 |
|
1102 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1103 |
|
1104 |
|
1105 | <span class="param-type">number</span>
|
1106 | |
|
1107 |
|
1108 | <span class="param-type"><a href="CB_Arrays.html#.executeFunctionAll_ON_LOOP_CALLBACK">CB_Arrays.executeFunctionAll_ON_LOOP_CALLBACK</a></span>
|
1109 |
|
1110 |
|
1111 |
|
1112 |
|
1113 | </td>
|
1114 |
|
1115 |
|
1116 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1117 |
|
1118 | <optional><br>
|
1119 |
|
1120 |
|
1121 |
|
1122 |
|
1123 |
|
1124 | </td>
|
1125 |
|
1126 |
|
1127 |
|
1128 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1129 |
|
1130 | 0
|
1131 |
|
1132 | </td>
|
1133 |
|
1134 |
|
1135 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If a value greater than zero is used, it will be used as the delay desired between each call to the "functionEach" function (calling them using the <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> function internally). If not provided or the value is 0 (zero) or lower, each call to the "functionEach" function will be performed immediately one after the other. If a function is provided, it will be called with the same parameters as the "functionEach" function and its returning value will be used as the delay (executed every loop for each item).</p></td>
|
1136 | </tr>
|
1137 |
|
1138 |
|
1139 |
|
1140 | <tr>
|
1141 |
|
1142 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>returnSetTimeoutsArray</code></td>
|
1143 |
|
1144 |
|
1145 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1146 |
|
1147 |
|
1148 | <span class="param-type">boolean</span>
|
1149 |
|
1150 |
|
1151 |
|
1152 |
|
1153 | </td>
|
1154 |
|
1155 |
|
1156 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1157 |
|
1158 | <optional><br>
|
1159 |
|
1160 |
|
1161 |
|
1162 |
|
1163 |
|
1164 | </td>
|
1165 |
|
1166 |
|
1167 |
|
1168 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1169 |
|
1170 | false
|
1171 |
|
1172 | </td>
|
1173 |
|
1174 |
|
1175 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether we want the method to return an integer or a numeric array with information of each <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> call. Returning an array with information of each <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> call is only useful when the <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> function is called internally, which happens when the "delayBetweenEach" parameter is greater than 0 (zero).</p></td>
|
1176 | </tr>
|
1177 |
|
1178 |
|
1179 |
|
1180 | <tr>
|
1181 |
|
1182 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>delayBetweenEachAffectsFirst</code></td>
|
1183 |
|
1184 |
|
1185 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1186 |
|
1187 |
|
1188 | <span class="param-type">boolean</span>
|
1189 |
|
1190 |
|
1191 |
|
1192 |
|
1193 | </td>
|
1194 |
|
1195 |
|
1196 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1197 |
|
1198 | <optional><br>
|
1199 |
|
1200 |
|
1201 |
|
1202 |
|
1203 |
|
1204 | </td>
|
1205 |
|
1206 |
|
1207 |
|
1208 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1209 |
|
1210 | false
|
1211 |
|
1212 | </td>
|
1213 |
|
1214 |
|
1215 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, the desired delay (if any) will also affect the first call to the "functionEach" function.</p></td>
|
1216 | </tr>
|
1217 |
|
1218 |
|
1219 |
|
1220 | <tr>
|
1221 |
|
1222 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>functionFinish</code></td>
|
1223 |
|
1224 |
|
1225 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1226 |
|
1227 |
|
1228 | <span class="param-type"><a href="CB_Arrays.html#.executeFunctionAll_ON_FINISH_CALLBACK">CB_Arrays.executeFunctionAll_ON_FINISH_CALLBACK</a></span>
|
1229 |
|
1230 |
|
1231 |
|
1232 |
|
1233 | </td>
|
1234 |
|
1235 |
|
1236 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1237 |
|
1238 | <optional><br>
|
1239 |
|
1240 |
|
1241 |
|
1242 |
|
1243 |
|
1244 | </td>
|
1245 |
|
1246 |
|
1247 |
|
1248 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1249 |
|
1250 | </td>
|
1251 |
|
1252 |
|
1253 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function that will be called for when it has finished looping all the items. The first parameter will be the array which was looped, the second parameter will be the number of times that the "functionEach" callback was called (the most likely, matches the number of elements unless they are undefined or null), and the third parameter will be the maximum "delay" used, being "this" the array itself.</p></td>
|
1254 | </tr>
|
1255 |
|
1256 |
|
1257 | </tbody>
|
1258 | </table>
|
1259 |
|
1260 |
|
1261 |
|
1262 |
|
1263 | <dl class="details">
|
1264 |
|
1265 |
|
1266 |
|
1267 |
|
1268 |
|
1269 |
|
1270 |
|
1271 |
|
1272 |
|
1273 |
|
1274 |
|
1275 |
|
1276 |
|
1277 |
|
1278 |
|
1279 |
|
1280 |
|
1281 |
|
1282 |
|
1283 |
|
1284 |
|
1285 |
|
1286 |
|
1287 |
|
1288 |
|
1289 |
|
1290 |
|
1291 |
|
1292 |
|
1293 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1294 | <dd class="tag-source">
|
1295 | <ul class="dummy">
|
1296 | <li>
|
1297 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
1298 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-168">line 168</a>
|
1299 | </li>
|
1300 | </ul>
|
1301 | </dd>
|
1302 |
|
1303 |
|
1304 |
|
1305 |
|
1306 |
|
1307 |
|
1308 |
|
1309 | </dl>
|
1310 |
|
1311 |
|
1312 |
|
1313 |
|
1314 |
|
1315 |
|
1316 |
|
1317 |
|
1318 |
|
1319 |
|
1320 |
|
1321 |
|
1322 |
|
1323 | <h5>Returns:</h5>
|
1324 |
|
1325 |
|
1326 | <div class="param-desc">
|
1327 | <p>If the "returnSetTimeoutsArray" parameter is set to false, it will return the number of calls to the "functionEach" function that were performed (which should be the same number as the elements given in the "array" parameter). Otherwise, if the "returnSetTimeoutsArray" is set to true, it will return a numeric array with a <a href="CB_Arrays.html#.executeFunctionAll_OBJECT"><code>CB_Arrays.executeFunctionAll_OBJECT</code></a> object for each element given. The length of this array will also be the number of calls to the "functionEach" function that were performed. Note that if a value greater than 0 (zero) for the "delayBetweenEach" parameter has been provided, perhaps not all calls of the "functionEach" function will have been performed yet when exiting this method because of the asynchronous nature of the <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> function.</p>
|
1328 | </div>
|
1329 |
|
1330 |
|
1331 |
|
1332 | <dl>
|
1333 | <dt>
|
1334 | Type
|
1335 | </dt>
|
1336 | <dd>
|
1337 |
|
1338 | <span class="param-type">integer</span>
|
1339 | |
|
1340 |
|
1341 | <span class="param-type">array</span>
|
1342 |
|
1343 |
|
1344 |
|
1345 | </dd>
|
1346 | </dl>
|
1347 |
|
1348 |
|
1349 |
|
1350 |
|
1351 |
|
1352 | </dd>
|
1353 |
|
1354 |
|
1355 |
|
1356 | <hr>
|
1357 | <dt>
|
1358 | <h4 class="name" id=".forEach"><span class="type-signature"><static> </span>forEach<span class="signature">(array, callback [, thisArg] [, extendedDOM])</span><span class="type-signature"> → {array|undefined}</span></h4>
|
1359 |
|
1360 |
|
1361 | </dt>
|
1362 | <dd>
|
1363 |
|
1364 |
|
1365 | <div class="description">
|
1366 | <p>Implementation of the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach">Array.forEach</a> method for browsers that do not support it natively.<br> <br><br> Executes a function for each element of a given array.</p>
|
1367 | </div>
|
1368 |
|
1369 |
|
1370 |
|
1371 |
|
1372 |
|
1373 |
|
1374 |
|
1375 |
|
1376 | <h5>Parameters:</h5>
|
1377 |
|
1378 |
|
1379 | <table class="params table table-striped">
|
1380 | <thead>
|
1381 | <tr>
|
1382 |
|
1383 | <th style="width:12%; min-width:110px;">Name</th>
|
1384 |
|
1385 |
|
1386 | <th style="width:12%; min-width:110px;">Type</th>
|
1387 |
|
1388 |
|
1389 | <th style="width:12%; min-width:110px;">Argument</th>
|
1390 |
|
1391 |
|
1392 |
|
1393 | <th style="width:12%; min-width:110px;">Default</th>
|
1394 |
|
1395 |
|
1396 | <th class="last" style="min-width:310px;">Description</th>
|
1397 | </tr>
|
1398 | </thead>
|
1399 |
|
1400 | <tbody>
|
1401 |
|
1402 |
|
1403 | <tr>
|
1404 |
|
1405 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
1406 |
|
1407 |
|
1408 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1409 |
|
1410 |
|
1411 | <span class="param-type">array</span>
|
1412 |
|
1413 |
|
1414 |
|
1415 |
|
1416 | </td>
|
1417 |
|
1418 |
|
1419 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1420 |
|
1421 |
|
1422 |
|
1423 |
|
1424 |
|
1425 | </td>
|
1426 |
|
1427 |
|
1428 |
|
1429 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1430 |
|
1431 | </td>
|
1432 |
|
1433 |
|
1434 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Desired array.</p></td>
|
1435 | </tr>
|
1436 |
|
1437 |
|
1438 |
|
1439 | <tr>
|
1440 |
|
1441 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callback</code></td>
|
1442 |
|
1443 |
|
1444 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1445 |
|
1446 |
|
1447 | <span class="param-type">function</span>
|
1448 |
|
1449 |
|
1450 |
|
1451 |
|
1452 | </td>
|
1453 |
|
1454 |
|
1455 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1456 |
|
1457 |
|
1458 |
|
1459 |
|
1460 |
|
1461 | </td>
|
1462 |
|
1463 |
|
1464 |
|
1465 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1466 |
|
1467 | </td>
|
1468 |
|
1469 |
|
1470 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function that will be executed for each element of the given array. Following the same rules as the native <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach">Array.forEach</a> method, it will receive three arguments: currentValue, currentIndex and the array given.</p></td>
|
1471 | </tr>
|
1472 |
|
1473 |
|
1474 |
|
1475 | <tr>
|
1476 |
|
1477 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>thisArg</code></td>
|
1478 |
|
1479 |
|
1480 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1481 |
|
1482 |
|
1483 | <span class="param-type">*</span>
|
1484 |
|
1485 |
|
1486 |
|
1487 |
|
1488 | </td>
|
1489 |
|
1490 |
|
1491 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1492 |
|
1493 | <optional><br>
|
1494 |
|
1495 |
|
1496 |
|
1497 |
|
1498 |
|
1499 | </td>
|
1500 |
|
1501 |
|
1502 |
|
1503 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1504 |
|
1505 | </td>
|
1506 |
|
1507 |
|
1508 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Value that will be passed as "this" every time the function is called.</p></td>
|
1509 | </tr>
|
1510 |
|
1511 |
|
1512 |
|
1513 | <tr>
|
1514 |
|
1515 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>extendedDOM</code></td>
|
1516 |
|
1517 |
|
1518 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1519 |
|
1520 |
|
1521 | <span class="param-type">boolean</span>
|
1522 |
|
1523 |
|
1524 |
|
1525 |
|
1526 | </td>
|
1527 |
|
1528 |
|
1529 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1530 |
|
1531 | <optional><br>
|
1532 |
|
1533 |
|
1534 |
|
1535 |
|
1536 |
|
1537 | </td>
|
1538 |
|
1539 |
|
1540 |
|
1541 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1542 |
|
1543 | false
|
1544 |
|
1545 | </td>
|
1546 |
|
1547 |
|
1548 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether the function is being called by a native function which was extended. Internal usage recommended only.</p></td>
|
1549 | </tr>
|
1550 |
|
1551 |
|
1552 | </tbody>
|
1553 | </table>
|
1554 |
|
1555 |
|
1556 |
|
1557 |
|
1558 | <dl class="details">
|
1559 |
|
1560 |
|
1561 |
|
1562 |
|
1563 |
|
1564 |
|
1565 |
|
1566 |
|
1567 |
|
1568 |
|
1569 |
|
1570 |
|
1571 |
|
1572 |
|
1573 |
|
1574 |
|
1575 |
|
1576 |
|
1577 |
|
1578 |
|
1579 |
|
1580 |
|
1581 |
|
1582 |
|
1583 |
|
1584 |
|
1585 |
|
1586 |
|
1587 |
|
1588 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1589 | <dd class="tag-source">
|
1590 | <ul class="dummy">
|
1591 | <li>
|
1592 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
1593 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-136">line 136</a>
|
1594 | </li>
|
1595 | </ul>
|
1596 | </dd>
|
1597 |
|
1598 |
|
1599 |
|
1600 |
|
1601 |
|
1602 |
|
1603 |
|
1604 | </dl>
|
1605 |
|
1606 |
|
1607 |
|
1608 |
|
1609 |
|
1610 |
|
1611 |
|
1612 |
|
1613 |
|
1614 |
|
1615 |
|
1616 |
|
1617 |
|
1618 | <h5>Returns:</h5>
|
1619 |
|
1620 |
|
1621 | <div class="param-desc">
|
1622 | <p>If the "extendedDOM" parameter is set to false, returns the given "array" again. Otherwise, returns undefined.</p>
|
1623 | </div>
|
1624 |
|
1625 |
|
1626 |
|
1627 | <dl>
|
1628 | <dt>
|
1629 | Type
|
1630 | </dt>
|
1631 | <dd>
|
1632 |
|
1633 | <span class="param-type">array</span>
|
1634 | |
|
1635 |
|
1636 | <span class="param-type">undefined</span>
|
1637 |
|
1638 |
|
1639 |
|
1640 | </dd>
|
1641 | </dl>
|
1642 |
|
1643 |
|
1644 |
|
1645 |
|
1646 |
|
1647 | </dd>
|
1648 |
|
1649 |
|
1650 |
|
1651 | <hr>
|
1652 | <dt>
|
1653 | <h4 class="name" id=".indexOf"><span class="type-signature"><static> </span>indexOf<span class="signature">(array, searchElement [, fromIndex] [, extendedDOM])</span><span class="type-signature"> → {integer}</span></h4>
|
1654 |
|
1655 |
|
1656 | </dt>
|
1657 | <dd>
|
1658 |
|
1659 |
|
1660 | <div class="description">
|
1661 | <p>Implementation of <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/indexOf">Array.indexOf</a> method for arrays in browsers that do not support it natively.<br> <br><br> Returns the first index of a given element that exists in an array (starting from a certain index if desired) or -1 if not found.</p>
|
1662 | </div>
|
1663 |
|
1664 |
|
1665 |
|
1666 |
|
1667 |
|
1668 |
|
1669 |
|
1670 |
|
1671 | <h5>Parameters:</h5>
|
1672 |
|
1673 |
|
1674 | <table class="params table table-striped">
|
1675 | <thead>
|
1676 | <tr>
|
1677 |
|
1678 | <th style="width:12%; min-width:110px;">Name</th>
|
1679 |
|
1680 |
|
1681 | <th style="width:12%; min-width:110px;">Type</th>
|
1682 |
|
1683 |
|
1684 | <th style="width:12%; min-width:110px;">Argument</th>
|
1685 |
|
1686 |
|
1687 |
|
1688 | <th style="width:12%; min-width:110px;">Default</th>
|
1689 |
|
1690 |
|
1691 | <th class="last" style="min-width:310px;">Description</th>
|
1692 | </tr>
|
1693 | </thead>
|
1694 |
|
1695 | <tbody>
|
1696 |
|
1697 |
|
1698 | <tr>
|
1699 |
|
1700 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
1701 |
|
1702 |
|
1703 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1704 |
|
1705 |
|
1706 | <span class="param-type">array</span>
|
1707 |
|
1708 |
|
1709 |
|
1710 |
|
1711 | </td>
|
1712 |
|
1713 |
|
1714 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1715 |
|
1716 |
|
1717 |
|
1718 |
|
1719 |
|
1720 | </td>
|
1721 |
|
1722 |
|
1723 |
|
1724 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1725 |
|
1726 | </td>
|
1727 |
|
1728 |
|
1729 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Desired array.</p></td>
|
1730 | </tr>
|
1731 |
|
1732 |
|
1733 |
|
1734 | <tr>
|
1735 |
|
1736 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>searchElement</code></td>
|
1737 |
|
1738 |
|
1739 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1740 |
|
1741 |
|
1742 | <span class="param-type">*</span>
|
1743 |
|
1744 |
|
1745 |
|
1746 |
|
1747 | </td>
|
1748 |
|
1749 |
|
1750 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1751 |
|
1752 |
|
1753 |
|
1754 |
|
1755 |
|
1756 | </td>
|
1757 |
|
1758 |
|
1759 |
|
1760 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1761 |
|
1762 | </td>
|
1763 |
|
1764 |
|
1765 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Element we want to search. Note that it is type sensitive.</p></td>
|
1766 | </tr>
|
1767 |
|
1768 |
|
1769 |
|
1770 | <tr>
|
1771 |
|
1772 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>fromIndex</code></td>
|
1773 |
|
1774 |
|
1775 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1776 |
|
1777 |
|
1778 | <span class="param-type">integer</span>
|
1779 |
|
1780 |
|
1781 |
|
1782 |
|
1783 | </td>
|
1784 |
|
1785 |
|
1786 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1787 |
|
1788 | <optional><br>
|
1789 |
|
1790 |
|
1791 |
|
1792 |
|
1793 |
|
1794 | </td>
|
1795 |
|
1796 |
|
1797 |
|
1798 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1799 |
|
1800 | 0
|
1801 |
|
1802 | </td>
|
1803 |
|
1804 |
|
1805 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>First index of the given array where the search will start.</p></td>
|
1806 | </tr>
|
1807 |
|
1808 |
|
1809 |
|
1810 | <tr>
|
1811 |
|
1812 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>extendedDOM</code></td>
|
1813 |
|
1814 |
|
1815 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1816 |
|
1817 |
|
1818 | <span class="param-type">boolean</span>
|
1819 |
|
1820 |
|
1821 |
|
1822 |
|
1823 | </td>
|
1824 |
|
1825 |
|
1826 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1827 |
|
1828 | <optional><br>
|
1829 |
|
1830 |
|
1831 |
|
1832 |
|
1833 |
|
1834 | </td>
|
1835 |
|
1836 |
|
1837 |
|
1838 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1839 |
|
1840 | false
|
1841 |
|
1842 | </td>
|
1843 |
|
1844 |
|
1845 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether the function is being called by a native function which was extended. Internal usage recommended only.</p></td>
|
1846 | </tr>
|
1847 |
|
1848 |
|
1849 | </tbody>
|
1850 | </table>
|
1851 |
|
1852 |
|
1853 |
|
1854 |
|
1855 | <dl class="details">
|
1856 |
|
1857 |
|
1858 |
|
1859 |
|
1860 |
|
1861 |
|
1862 |
|
1863 |
|
1864 |
|
1865 |
|
1866 |
|
1867 |
|
1868 |
|
1869 |
|
1870 |
|
1871 |
|
1872 |
|
1873 |
|
1874 |
|
1875 |
|
1876 |
|
1877 |
|
1878 |
|
1879 |
|
1880 |
|
1881 |
|
1882 |
|
1883 |
|
1884 |
|
1885 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1886 | <dd class="tag-source">
|
1887 | <ul class="dummy">
|
1888 | <li>
|
1889 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
1890 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-87">line 87</a>
|
1891 | </li>
|
1892 | </ul>
|
1893 | </dd>
|
1894 |
|
1895 |
|
1896 |
|
1897 |
|
1898 |
|
1899 |
|
1900 |
|
1901 | </dl>
|
1902 |
|
1903 |
|
1904 |
|
1905 |
|
1906 |
|
1907 |
|
1908 |
|
1909 |
|
1910 |
|
1911 |
|
1912 |
|
1913 |
|
1914 |
|
1915 | <h5>Returns:</h5>
|
1916 |
|
1917 |
|
1918 |
|
1919 |
|
1920 | <dl>
|
1921 | <dt>
|
1922 | Type
|
1923 | </dt>
|
1924 | <dd>
|
1925 |
|
1926 | <span class="param-type">integer</span>
|
1927 |
|
1928 |
|
1929 |
|
1930 | </dd>
|
1931 | </dl>
|
1932 |
|
1933 |
|
1934 |
|
1935 |
|
1936 |
|
1937 | </dd>
|
1938 |
|
1939 |
|
1940 |
|
1941 | <hr>
|
1942 | <dt>
|
1943 | <h4 class="name" id=".insert"><span class="type-signature"><static> </span>insert<span class="signature">()</span><span class="type-signature"></span></h4>
|
1944 |
|
1945 |
|
1946 | </dt>
|
1947 | <dd>
|
1948 |
|
1949 |
|
1950 | <div class="description">
|
1951 | <p>Alias for <a href="CB_Arrays.html#.insertElement"><code>CB_Arrays.insertElement</code></a>.</p>
|
1952 | </div>
|
1953 |
|
1954 |
|
1955 |
|
1956 |
|
1957 |
|
1958 |
|
1959 |
|
1960 |
|
1961 |
|
1962 |
|
1963 | <dl class="details">
|
1964 |
|
1965 |
|
1966 |
|
1967 |
|
1968 |
|
1969 |
|
1970 |
|
1971 |
|
1972 |
|
1973 |
|
1974 |
|
1975 |
|
1976 |
|
1977 |
|
1978 |
|
1979 |
|
1980 |
|
1981 |
|
1982 |
|
1983 |
|
1984 |
|
1985 |
|
1986 |
|
1987 |
|
1988 |
|
1989 |
|
1990 |
|
1991 |
|
1992 |
|
1993 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1994 | <dd class="tag-source">
|
1995 | <ul class="dummy">
|
1996 | <li>
|
1997 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
1998 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-251">line 251</a>
|
1999 | </li>
|
2000 | </ul>
|
2001 | </dd>
|
2002 |
|
2003 |
|
2004 |
|
2005 |
|
2006 |
|
2007 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
2008 | <dd class="tag-see">
|
2009 | <ul>
|
2010 | <li><a href="CB_Arrays.html#.insertElement"><code>CB_Arrays.insertElement</code></a></li>
|
2011 | </ul>
|
2012 | </dd>
|
2013 |
|
2014 |
|
2015 |
|
2016 | </dl>
|
2017 |
|
2018 |
|
2019 |
|
2020 |
|
2021 |
|
2022 |
|
2023 |
|
2024 |
|
2025 |
|
2026 |
|
2027 |
|
2028 |
|
2029 |
|
2030 |
|
2031 |
|
2032 | </dd>
|
2033 |
|
2034 |
|
2035 |
|
2036 | <hr>
|
2037 | <dt>
|
2038 | <h4 class="name" id=".insertElement"><span class="type-signature"><static> </span>insertElement<span class="signature">(array [, index], item [, onInsert])</span><span class="type-signature"> → {array}</span></h4>
|
2039 |
|
2040 |
|
2041 | </dt>
|
2042 | <dd>
|
2043 |
|
2044 |
|
2045 | <div class="description">
|
2046 | <p>Inserts an element in the desired position of a given an array. Elements which are placed after it will be moved a position to the right (increasing their index).</p>
|
2047 | </div>
|
2048 |
|
2049 |
|
2050 |
|
2051 |
|
2052 |
|
2053 |
|
2054 |
|
2055 |
|
2056 | <h5>Parameters:</h5>
|
2057 |
|
2058 |
|
2059 | <table class="params table table-striped">
|
2060 | <thead>
|
2061 | <tr>
|
2062 |
|
2063 | <th style="width:12%; min-width:110px;">Name</th>
|
2064 |
|
2065 |
|
2066 | <th style="width:12%; min-width:110px;">Type</th>
|
2067 |
|
2068 |
|
2069 | <th style="width:12%; min-width:110px;">Argument</th>
|
2070 |
|
2071 |
|
2072 |
|
2073 | <th style="width:12%; min-width:110px;">Default</th>
|
2074 |
|
2075 |
|
2076 | <th class="last" style="min-width:310px;">Description</th>
|
2077 | </tr>
|
2078 | </thead>
|
2079 |
|
2080 | <tbody>
|
2081 |
|
2082 |
|
2083 | <tr>
|
2084 |
|
2085 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
2086 |
|
2087 |
|
2088 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2089 |
|
2090 |
|
2091 | <span class="param-type">array</span>
|
2092 |
|
2093 |
|
2094 |
|
2095 |
|
2096 | </td>
|
2097 |
|
2098 |
|
2099 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2100 |
|
2101 |
|
2102 |
|
2103 |
|
2104 |
|
2105 | </td>
|
2106 |
|
2107 |
|
2108 |
|
2109 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2110 |
|
2111 | </td>
|
2112 |
|
2113 |
|
2114 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The array whose element we want to delete.</p></td>
|
2115 | </tr>
|
2116 |
|
2117 |
|
2118 |
|
2119 | <tr>
|
2120 |
|
2121 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
|
2122 |
|
2123 |
|
2124 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2125 |
|
2126 |
|
2127 | <span class="param-type">integer</span>
|
2128 |
|
2129 |
|
2130 |
|
2131 |
|
2132 | </td>
|
2133 |
|
2134 |
|
2135 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2136 |
|
2137 | <optional><br>
|
2138 |
|
2139 |
|
2140 |
|
2141 |
|
2142 |
|
2143 | </td>
|
2144 |
|
2145 |
|
2146 |
|
2147 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2148 |
|
2149 | 0
|
2150 |
|
2151 | </td>
|
2152 |
|
2153 |
|
2154 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Position of the element in the given array that we want to remove.</p></td>
|
2155 | </tr>
|
2156 |
|
2157 |
|
2158 |
|
2159 | <tr>
|
2160 |
|
2161 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>item</code></td>
|
2162 |
|
2163 |
|
2164 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2165 |
|
2166 |
|
2167 | <span class="param-type">*</span>
|
2168 |
|
2169 |
|
2170 |
|
2171 |
|
2172 | </td>
|
2173 |
|
2174 |
|
2175 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2176 |
|
2177 |
|
2178 |
|
2179 |
|
2180 |
|
2181 | </td>
|
2182 |
|
2183 |
|
2184 |
|
2185 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2186 |
|
2187 | </td>
|
2188 |
|
2189 |
|
2190 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Element (item) which belongs to the index which is being checked in the current iteration of the given array.</p></td>
|
2191 | </tr>
|
2192 |
|
2193 |
|
2194 |
|
2195 | <tr>
|
2196 |
|
2197 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onInsert</code></td>
|
2198 |
|
2199 |
|
2200 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2201 |
|
2202 |
|
2203 | <span class="param-type"><a href="CB_Arrays.html#.removeDuplicated_PURGE_FUNCTION">CB_Arrays.removeDuplicated_PURGE_FUNCTION</a></span>
|
2204 |
|
2205 |
|
2206 |
|
2207 |
|
2208 | </td>
|
2209 |
|
2210 |
|
2211 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2212 |
|
2213 | <optional><br>
|
2214 |
|
2215 |
|
2216 |
|
2217 |
|
2218 |
|
2219 | </td>
|
2220 |
|
2221 |
|
2222 |
|
2223 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2224 |
|
2225 | </td>
|
2226 |
|
2227 |
|
2228 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function to call if the element is inserted, after inserting it.</p></td>
|
2229 | </tr>
|
2230 |
|
2231 |
|
2232 | </tbody>
|
2233 | </table>
|
2234 |
|
2235 |
|
2236 |
|
2237 |
|
2238 | <dl class="details">
|
2239 |
|
2240 |
|
2241 |
|
2242 |
|
2243 |
|
2244 |
|
2245 |
|
2246 |
|
2247 |
|
2248 |
|
2249 |
|
2250 |
|
2251 |
|
2252 |
|
2253 |
|
2254 |
|
2255 |
|
2256 |
|
2257 |
|
2258 |
|
2259 |
|
2260 |
|
2261 |
|
2262 |
|
2263 |
|
2264 |
|
2265 |
|
2266 |
|
2267 |
|
2268 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2269 | <dd class="tag-source">
|
2270 | <ul class="dummy">
|
2271 | <li>
|
2272 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
2273 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-270">line 270</a>
|
2274 | </li>
|
2275 | </ul>
|
2276 | </dd>
|
2277 |
|
2278 |
|
2279 |
|
2280 |
|
2281 |
|
2282 |
|
2283 |
|
2284 | </dl>
|
2285 |
|
2286 |
|
2287 |
|
2288 |
|
2289 |
|
2290 |
|
2291 |
|
2292 |
|
2293 |
|
2294 |
|
2295 |
|
2296 |
|
2297 |
|
2298 | <h5>Returns:</h5>
|
2299 |
|
2300 |
|
2301 | <div class="param-desc">
|
2302 | <p>Returns the new array (with the element inserted if it was possible). If no valid array is given, it will return an empty array.</p>
|
2303 | </div>
|
2304 |
|
2305 |
|
2306 |
|
2307 | <dl>
|
2308 | <dt>
|
2309 | Type
|
2310 | </dt>
|
2311 | <dd>
|
2312 |
|
2313 | <span class="param-type">array</span>
|
2314 |
|
2315 |
|
2316 |
|
2317 | </dd>
|
2318 | </dl>
|
2319 |
|
2320 |
|
2321 |
|
2322 |
|
2323 |
|
2324 | </dd>
|
2325 |
|
2326 |
|
2327 |
|
2328 | <hr>
|
2329 | <dt>
|
2330 | <h4 class="name" id=".insertElementByPosition"><span class="type-signature"><static> </span>insertElementByPosition<span class="signature">()</span><span class="type-signature"></span></h4>
|
2331 |
|
2332 |
|
2333 | </dt>
|
2334 | <dd>
|
2335 |
|
2336 |
|
2337 | <div class="description">
|
2338 | <p>Alias for <a href="CB_Arrays.html#.insertElement"><code>CB_Arrays.insertElement</code></a>.</p>
|
2339 | </div>
|
2340 |
|
2341 |
|
2342 |
|
2343 |
|
2344 |
|
2345 |
|
2346 |
|
2347 |
|
2348 |
|
2349 |
|
2350 | <dl class="details">
|
2351 |
|
2352 |
|
2353 |
|
2354 |
|
2355 |
|
2356 |
|
2357 |
|
2358 |
|
2359 |
|
2360 |
|
2361 |
|
2362 |
|
2363 |
|
2364 |
|
2365 |
|
2366 |
|
2367 |
|
2368 |
|
2369 |
|
2370 |
|
2371 |
|
2372 |
|
2373 |
|
2374 |
|
2375 |
|
2376 |
|
2377 |
|
2378 |
|
2379 |
|
2380 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2381 | <dd class="tag-source">
|
2382 | <ul class="dummy">
|
2383 | <li>
|
2384 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
2385 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-256">line 256</a>
|
2386 | </li>
|
2387 | </ul>
|
2388 | </dd>
|
2389 |
|
2390 |
|
2391 |
|
2392 |
|
2393 |
|
2394 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
2395 | <dd class="tag-see">
|
2396 | <ul>
|
2397 | <li><a href="CB_Arrays.html#.insertElement"><code>CB_Arrays.insertElement</code></a></li>
|
2398 | </ul>
|
2399 | </dd>
|
2400 |
|
2401 |
|
2402 |
|
2403 | </dl>
|
2404 |
|
2405 |
|
2406 |
|
2407 |
|
2408 |
|
2409 |
|
2410 |
|
2411 |
|
2412 |
|
2413 |
|
2414 |
|
2415 |
|
2416 |
|
2417 |
|
2418 |
|
2419 | </dd>
|
2420 |
|
2421 |
|
2422 |
|
2423 | <hr>
|
2424 | <dt>
|
2425 | <h4 class="name" id=".isArray"><span class="type-signature"><static> </span>isArray<span class="signature">(element [, extendedDOM])</span><span class="type-signature"> → {boolean}</span></h4>
|
2426 |
|
2427 |
|
2428 | </dt>
|
2429 | <dd>
|
2430 |
|
2431 |
|
2432 | <div class="description">
|
2433 | <p>Implementation of <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/isArray">Array.isArray</a> method for browsers that do not support it natively.<br> <br><br> Returns whether a given element is an array or not.</p>
|
2434 | </div>
|
2435 |
|
2436 |
|
2437 |
|
2438 |
|
2439 |
|
2440 |
|
2441 |
|
2442 |
|
2443 | <h5>Parameters:</h5>
|
2444 |
|
2445 |
|
2446 | <table class="params table table-striped">
|
2447 | <thead>
|
2448 | <tr>
|
2449 |
|
2450 | <th style="width:12%; min-width:110px;">Name</th>
|
2451 |
|
2452 |
|
2453 | <th style="width:12%; min-width:110px;">Type</th>
|
2454 |
|
2455 |
|
2456 | <th style="width:12%; min-width:110px;">Argument</th>
|
2457 |
|
2458 |
|
2459 |
|
2460 | <th style="width:12%; min-width:110px;">Default</th>
|
2461 |
|
2462 |
|
2463 | <th class="last" style="min-width:310px;">Description</th>
|
2464 | </tr>
|
2465 | </thead>
|
2466 |
|
2467 | <tbody>
|
2468 |
|
2469 |
|
2470 | <tr>
|
2471 |
|
2472 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
|
2473 |
|
2474 |
|
2475 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2476 |
|
2477 |
|
2478 | <span class="param-type">*</span>
|
2479 |
|
2480 |
|
2481 |
|
2482 |
|
2483 | </td>
|
2484 |
|
2485 |
|
2486 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2487 |
|
2488 |
|
2489 |
|
2490 |
|
2491 |
|
2492 | </td>
|
2493 |
|
2494 |
|
2495 |
|
2496 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2497 |
|
2498 | </td>
|
2499 |
|
2500 |
|
2501 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element we want to check.</p></td>
|
2502 | </tr>
|
2503 |
|
2504 |
|
2505 |
|
2506 | <tr>
|
2507 |
|
2508 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>extendedDOM</code></td>
|
2509 |
|
2510 |
|
2511 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2512 |
|
2513 |
|
2514 | <span class="param-type">boolean</span>
|
2515 |
|
2516 |
|
2517 |
|
2518 |
|
2519 | </td>
|
2520 |
|
2521 |
|
2522 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2523 |
|
2524 | <optional><br>
|
2525 |
|
2526 |
|
2527 |
|
2528 |
|
2529 |
|
2530 | </td>
|
2531 |
|
2532 |
|
2533 |
|
2534 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2535 |
|
2536 | false
|
2537 |
|
2538 | </td>
|
2539 |
|
2540 |
|
2541 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether the function is being called by a native function which was extended. Internal usage recommended only.</p></td>
|
2542 | </tr>
|
2543 |
|
2544 |
|
2545 | </tbody>
|
2546 | </table>
|
2547 |
|
2548 |
|
2549 |
|
2550 |
|
2551 | <dl class="details">
|
2552 |
|
2553 |
|
2554 |
|
2555 |
|
2556 |
|
2557 |
|
2558 |
|
2559 |
|
2560 |
|
2561 |
|
2562 |
|
2563 |
|
2564 |
|
2565 |
|
2566 |
|
2567 |
|
2568 |
|
2569 |
|
2570 |
|
2571 |
|
2572 |
|
2573 |
|
2574 |
|
2575 |
|
2576 |
|
2577 |
|
2578 |
|
2579 |
|
2580 |
|
2581 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2582 | <dd class="tag-source">
|
2583 | <ul class="dummy">
|
2584 | <li>
|
2585 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
2586 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-172">line 172</a>
|
2587 | </li>
|
2588 | </ul>
|
2589 | </dd>
|
2590 |
|
2591 |
|
2592 |
|
2593 |
|
2594 |
|
2595 |
|
2596 |
|
2597 | <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
|
2598 | <dd class="tag-todo">
|
2599 | <ul>
|
2600 | <li>Think about a parameter to check whether the given array is a typed array (for example, 'Uint8Array') or not.</li>
|
2601 | </ul>
|
2602 | </dd>
|
2603 |
|
2604 | </dl>
|
2605 |
|
2606 |
|
2607 |
|
2608 |
|
2609 |
|
2610 |
|
2611 |
|
2612 |
|
2613 |
|
2614 |
|
2615 |
|
2616 |
|
2617 |
|
2618 | <h5>Returns:</h5>
|
2619 |
|
2620 |
|
2621 |
|
2622 |
|
2623 | <dl>
|
2624 | <dt>
|
2625 | Type
|
2626 | </dt>
|
2627 | <dd>
|
2628 |
|
2629 | <span class="param-type">boolean</span>
|
2630 |
|
2631 |
|
2632 |
|
2633 | </dd>
|
2634 | </dl>
|
2635 |
|
2636 |
|
2637 |
|
2638 |
|
2639 |
|
2640 | </dd>
|
2641 |
|
2642 |
|
2643 |
|
2644 | <hr>
|
2645 | <dt>
|
2646 | <h4 class="name" id=".lastIndexOf"><span class="type-signature"><static> </span>lastIndexOf<span class="signature">(array, searchElement [, fromIndex] [, extendedDOM])</span><span class="type-signature"> → {integer}</span></h4>
|
2647 |
|
2648 |
|
2649 | </dt>
|
2650 | <dd>
|
2651 |
|
2652 |
|
2653 | <div class="description">
|
2654 | <p>Implementation of <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/lastIndexOf">Array.lastIndexOf</a> method for browsers that do not support it natively.<br> <br><br> Returns the last index of a given element that exists in an array (starting from a certain index if desired) or -1 if not found.</p>
|
2655 | </div>
|
2656 |
|
2657 |
|
2658 |
|
2659 |
|
2660 |
|
2661 |
|
2662 |
|
2663 |
|
2664 | <h5>Parameters:</h5>
|
2665 |
|
2666 |
|
2667 | <table class="params table table-striped">
|
2668 | <thead>
|
2669 | <tr>
|
2670 |
|
2671 | <th style="width:12%; min-width:110px;">Name</th>
|
2672 |
|
2673 |
|
2674 | <th style="width:12%; min-width:110px;">Type</th>
|
2675 |
|
2676 |
|
2677 | <th style="width:12%; min-width:110px;">Argument</th>
|
2678 |
|
2679 |
|
2680 |
|
2681 | <th style="width:12%; min-width:110px;">Default</th>
|
2682 |
|
2683 |
|
2684 | <th class="last" style="min-width:310px;">Description</th>
|
2685 | </tr>
|
2686 | </thead>
|
2687 |
|
2688 | <tbody>
|
2689 |
|
2690 |
|
2691 | <tr>
|
2692 |
|
2693 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
2694 |
|
2695 |
|
2696 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2697 |
|
2698 |
|
2699 | <span class="param-type">array</span>
|
2700 |
|
2701 |
|
2702 |
|
2703 |
|
2704 | </td>
|
2705 |
|
2706 |
|
2707 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2708 |
|
2709 |
|
2710 |
|
2711 |
|
2712 |
|
2713 | </td>
|
2714 |
|
2715 |
|
2716 |
|
2717 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2718 |
|
2719 | </td>
|
2720 |
|
2721 |
|
2722 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Desired array.</p></td>
|
2723 | </tr>
|
2724 |
|
2725 |
|
2726 |
|
2727 | <tr>
|
2728 |
|
2729 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>searchElement</code></td>
|
2730 |
|
2731 |
|
2732 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2733 |
|
2734 |
|
2735 | <span class="param-type">*</span>
|
2736 |
|
2737 |
|
2738 |
|
2739 |
|
2740 | </td>
|
2741 |
|
2742 |
|
2743 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2744 |
|
2745 |
|
2746 |
|
2747 |
|
2748 |
|
2749 | </td>
|
2750 |
|
2751 |
|
2752 |
|
2753 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2754 |
|
2755 | </td>
|
2756 |
|
2757 |
|
2758 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Element we want to search. Note that it is type sensitive.</p></td>
|
2759 | </tr>
|
2760 |
|
2761 |
|
2762 |
|
2763 | <tr>
|
2764 |
|
2765 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>fromIndex</code></td>
|
2766 |
|
2767 |
|
2768 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2769 |
|
2770 |
|
2771 | <span class="param-type">integer</span>
|
2772 |
|
2773 |
|
2774 |
|
2775 |
|
2776 | </td>
|
2777 |
|
2778 |
|
2779 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2780 |
|
2781 | <optional><br>
|
2782 |
|
2783 |
|
2784 |
|
2785 |
|
2786 |
|
2787 | </td>
|
2788 |
|
2789 |
|
2790 |
|
2791 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2792 |
|
2793 | array.length - 1
|
2794 |
|
2795 | </td>
|
2796 |
|
2797 |
|
2798 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>First index of the given array where the search will start.</p></td>
|
2799 | </tr>
|
2800 |
|
2801 |
|
2802 |
|
2803 | <tr>
|
2804 |
|
2805 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>extendedDOM</code></td>
|
2806 |
|
2807 |
|
2808 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2809 |
|
2810 |
|
2811 | <span class="param-type">boolean</span>
|
2812 |
|
2813 |
|
2814 |
|
2815 |
|
2816 | </td>
|
2817 |
|
2818 |
|
2819 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2820 |
|
2821 | <optional><br>
|
2822 |
|
2823 |
|
2824 |
|
2825 |
|
2826 |
|
2827 | </td>
|
2828 |
|
2829 |
|
2830 |
|
2831 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2832 |
|
2833 | false
|
2834 |
|
2835 | </td>
|
2836 |
|
2837 |
|
2838 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether the function is being called by a native function which was extended. Internal usage recommended only.</p></td>
|
2839 | </tr>
|
2840 |
|
2841 |
|
2842 | </tbody>
|
2843 | </table>
|
2844 |
|
2845 |
|
2846 |
|
2847 |
|
2848 | <dl class="details">
|
2849 |
|
2850 |
|
2851 |
|
2852 |
|
2853 |
|
2854 |
|
2855 |
|
2856 |
|
2857 |
|
2858 |
|
2859 |
|
2860 |
|
2861 |
|
2862 |
|
2863 |
|
2864 |
|
2865 |
|
2866 |
|
2867 |
|
2868 |
|
2869 |
|
2870 |
|
2871 |
|
2872 |
|
2873 |
|
2874 |
|
2875 |
|
2876 |
|
2877 |
|
2878 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2879 | <dd class="tag-source">
|
2880 | <ul class="dummy">
|
2881 | <li>
|
2882 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
2883 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-38">line 38</a>
|
2884 | </li>
|
2885 | </ul>
|
2886 | </dd>
|
2887 |
|
2888 |
|
2889 |
|
2890 |
|
2891 |
|
2892 |
|
2893 |
|
2894 | <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
|
2895 | <dd class="tag-todo">
|
2896 | <ul>
|
2897 | <li>Implement the "fromIndex" in the polyfill.</li>
|
2898 | </ul>
|
2899 | </dd>
|
2900 |
|
2901 | </dl>
|
2902 |
|
2903 |
|
2904 |
|
2905 |
|
2906 |
|
2907 |
|
2908 |
|
2909 |
|
2910 |
|
2911 |
|
2912 |
|
2913 |
|
2914 |
|
2915 | <h5>Returns:</h5>
|
2916 |
|
2917 |
|
2918 |
|
2919 |
|
2920 | <dl>
|
2921 | <dt>
|
2922 | Type
|
2923 | </dt>
|
2924 | <dd>
|
2925 |
|
2926 | <span class="param-type">integer</span>
|
2927 |
|
2928 |
|
2929 |
|
2930 | </dd>
|
2931 | </dl>
|
2932 |
|
2933 |
|
2934 |
|
2935 |
|
2936 |
|
2937 | </dd>
|
2938 |
|
2939 |
|
2940 |
|
2941 | <hr>
|
2942 | <dt>
|
2943 | <h4 class="name" id=".ltrim"><span class="type-signature"><static> </span>ltrim<span class="signature">(element [, undesiredStrings])</span><span class="type-signature"> → {string|array}</span></h4>
|
2944 |
|
2945 |
|
2946 | </dt>
|
2947 | <dd>
|
2948 |
|
2949 |
|
2950 | <div class="description">
|
2951 | <p>Trims the left side of a given string or array of strings (modifying the given array), taking off the desired strings or otherwise trimming spaces, tabs ("\t"), new lines ("\n") and carriage returns ("\r"). Case sensitive.</p>
|
2952 | </div>
|
2953 |
|
2954 |
|
2955 |
|
2956 |
|
2957 |
|
2958 |
|
2959 |
|
2960 |
|
2961 | <h5>Parameters:</h5>
|
2962 |
|
2963 |
|
2964 | <table class="params table table-striped">
|
2965 | <thead>
|
2966 | <tr>
|
2967 |
|
2968 | <th style="width:12%; min-width:110px;">Name</th>
|
2969 |
|
2970 |
|
2971 | <th style="width:12%; min-width:110px;">Type</th>
|
2972 |
|
2973 |
|
2974 | <th style="width:12%; min-width:110px;">Argument</th>
|
2975 |
|
2976 |
|
2977 |
|
2978 | <th style="width:12%; min-width:110px;">Default</th>
|
2979 |
|
2980 |
|
2981 | <th class="last" style="min-width:310px;">Description</th>
|
2982 | </tr>
|
2983 | </thead>
|
2984 |
|
2985 | <tbody>
|
2986 |
|
2987 |
|
2988 | <tr>
|
2989 |
|
2990 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
|
2991 |
|
2992 |
|
2993 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2994 |
|
2995 |
|
2996 | <span class="param-type">string</span>
|
2997 | |
|
2998 |
|
2999 | <span class="param-type">array</span>
|
3000 |
|
3001 |
|
3002 |
|
3003 |
|
3004 | </td>
|
3005 |
|
3006 |
|
3007 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3008 |
|
3009 |
|
3010 |
|
3011 |
|
3012 |
|
3013 | </td>
|
3014 |
|
3015 |
|
3016 |
|
3017 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3018 |
|
3019 | </td>
|
3020 |
|
3021 |
|
3022 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element that will be trimmed. It should be either a string or an array of strings.</p></td>
|
3023 | </tr>
|
3024 |
|
3025 |
|
3026 |
|
3027 | <tr>
|
3028 |
|
3029 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>undesiredStrings</code></td>
|
3030 |
|
3031 |
|
3032 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3033 |
|
3034 |
|
3035 | <span class="param-type">string</span>
|
3036 | |
|
3037 |
|
3038 | <span class="param-type">array</span>
|
3039 |
|
3040 |
|
3041 |
|
3042 |
|
3043 | </td>
|
3044 |
|
3045 |
|
3046 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3047 |
|
3048 | <optional><br>
|
3049 |
|
3050 |
|
3051 |
|
3052 |
|
3053 |
|
3054 | </td>
|
3055 |
|
3056 |
|
3057 |
|
3058 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3059 |
|
3060 | [ " ", "\n", "\r", "\t" ]
|
3061 |
|
3062 | </td>
|
3063 |
|
3064 |
|
3065 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String or an array with the strings that we want to trim off the given element.</p></td>
|
3066 | </tr>
|
3067 |
|
3068 |
|
3069 | </tbody>
|
3070 | </table>
|
3071 |
|
3072 |
|
3073 |
|
3074 |
|
3075 | <dl class="details">
|
3076 |
|
3077 |
|
3078 |
|
3079 |
|
3080 |
|
3081 |
|
3082 |
|
3083 |
|
3084 |
|
3085 |
|
3086 |
|
3087 |
|
3088 |
|
3089 |
|
3090 |
|
3091 |
|
3092 |
|
3093 |
|
3094 |
|
3095 |
|
3096 |
|
3097 |
|
3098 |
|
3099 |
|
3100 |
|
3101 |
|
3102 |
|
3103 |
|
3104 |
|
3105 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3106 | <dd class="tag-source">
|
3107 | <ul class="dummy">
|
3108 | <li>
|
3109 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
3110 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-362">line 362</a>
|
3111 | </li>
|
3112 | </ul>
|
3113 | </dd>
|
3114 |
|
3115 |
|
3116 |
|
3117 |
|
3118 |
|
3119 |
|
3120 |
|
3121 | <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
|
3122 | <dd class="tag-todo">
|
3123 | <ul>
|
3124 | <li>Accept a "recursive" parameter (boolean) to affect multiple levels (array of arrays of strings, etc.).</li>
|
3125 |
|
3126 | <li>Consider accepting objects instead of arrays in the "element" parameter.</li>
|
3127 |
|
3128 | <li>Think about optimizing (using a counter for the number of occurrences in the loop and trim all the occurrences when finished).</li>
|
3129 | </ul>
|
3130 | </dd>
|
3131 |
|
3132 | </dl>
|
3133 |
|
3134 |
|
3135 |
|
3136 |
|
3137 |
|
3138 |
|
3139 |
|
3140 |
|
3141 |
|
3142 |
|
3143 |
|
3144 |
|
3145 |
|
3146 | <h5>Returns:</h5>
|
3147 |
|
3148 |
|
3149 | <div class="param-desc">
|
3150 | <p>Returns the given element again if it was an string, a number (it will be casted to a string) or an array of strings, trimmed if it has been possible. If it was another type, returns an empty string.</p>
|
3151 | </div>
|
3152 |
|
3153 |
|
3154 |
|
3155 | <dl>
|
3156 | <dt>
|
3157 | Type
|
3158 | </dt>
|
3159 | <dd>
|
3160 |
|
3161 | <span class="param-type">string</span>
|
3162 | |
|
3163 |
|
3164 | <span class="param-type">array</span>
|
3165 |
|
3166 |
|
3167 |
|
3168 | </dd>
|
3169 | </dl>
|
3170 |
|
3171 |
|
3172 |
|
3173 |
|
3174 |
|
3175 | </dd>
|
3176 |
|
3177 |
|
3178 |
|
3179 | <hr>
|
3180 | <dt>
|
3181 | <h4 class="name" id=".removeDuplicated"><span class="type-signature"><static> </span>removeDuplicated<span class="signature">(array [, purgeFunction] [, ignoreDuplicated])</span><span class="type-signature"> → {array}</span></h4>
|
3182 |
|
3183 |
|
3184 | </dt>
|
3185 | <dd>
|
3186 |
|
3187 |
|
3188 | <div class="description">
|
3189 | <p>Deletes duplicated and/or not desired values (with a checking function to purge) from a numeric array. Values can be of any type. Internally, loops through the given array backwards (from the last index to the first one).</p>
|
3190 | </div>
|
3191 |
|
3192 |
|
3193 |
|
3194 |
|
3195 |
|
3196 |
|
3197 |
|
3198 |
|
3199 | <h5>Parameters:</h5>
|
3200 |
|
3201 |
|
3202 | <table class="params table table-striped">
|
3203 | <thead>
|
3204 | <tr>
|
3205 |
|
3206 | <th style="width:12%; min-width:110px;">Name</th>
|
3207 |
|
3208 |
|
3209 | <th style="width:12%; min-width:110px;">Type</th>
|
3210 |
|
3211 |
|
3212 | <th style="width:12%; min-width:110px;">Argument</th>
|
3213 |
|
3214 |
|
3215 |
|
3216 | <th style="width:12%; min-width:110px;">Default</th>
|
3217 |
|
3218 |
|
3219 | <th class="last" style="min-width:310px;">Description</th>
|
3220 | </tr>
|
3221 | </thead>
|
3222 |
|
3223 | <tbody>
|
3224 |
|
3225 |
|
3226 | <tr>
|
3227 |
|
3228 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
3229 |
|
3230 |
|
3231 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3232 |
|
3233 |
|
3234 | <span class="param-type">array</span>
|
3235 |
|
3236 |
|
3237 |
|
3238 |
|
3239 | </td>
|
3240 |
|
3241 |
|
3242 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3243 |
|
3244 |
|
3245 |
|
3246 |
|
3247 |
|
3248 | </td>
|
3249 |
|
3250 |
|
3251 |
|
3252 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3253 |
|
3254 | </td>
|
3255 |
|
3256 |
|
3257 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The array whose values we want to purge.</p></td>
|
3258 | </tr>
|
3259 |
|
3260 |
|
3261 |
|
3262 | <tr>
|
3263 |
|
3264 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>purgeFunction</code></td>
|
3265 |
|
3266 |
|
3267 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3268 |
|
3269 |
|
3270 | <span class="param-type"><a href="CB_Arrays.html#.removeDuplicated_PURGE_FUNCTION">CB_Arrays.removeDuplicated_PURGE_FUNCTION</a></span>
|
3271 |
|
3272 |
|
3273 |
|
3274 |
|
3275 | </td>
|
3276 |
|
3277 |
|
3278 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3279 |
|
3280 | <optional><br>
|
3281 |
|
3282 |
|
3283 |
|
3284 |
|
3285 |
|
3286 | </td>
|
3287 |
|
3288 |
|
3289 |
|
3290 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3291 |
|
3292 | </td>
|
3293 |
|
3294 |
|
3295 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback that will be called for each item, being "this" the current item. It should return false when we want to keep the value or true otherwise. If the "ignoreDuplicated" parameter is set to true, all duplicated elements will be removed regardless of the returning value of the "purgeFunction" function.</p></td>
|
3296 | </tr>
|
3297 |
|
3298 |
|
3299 |
|
3300 | <tr>
|
3301 |
|
3302 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>ignoreDuplicated</code></td>
|
3303 |
|
3304 |
|
3305 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3306 |
|
3307 |
|
3308 | <span class="param-type">boolean</span>
|
3309 |
|
3310 |
|
3311 |
|
3312 |
|
3313 | </td>
|
3314 |
|
3315 |
|
3316 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3317 |
|
3318 | <optional><br>
|
3319 |
|
3320 |
|
3321 |
|
3322 |
|
3323 |
|
3324 | </td>
|
3325 |
|
3326 |
|
3327 |
|
3328 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3329 |
|
3330 | false
|
3331 |
|
3332 | </td>
|
3333 |
|
3334 |
|
3335 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If it is set to true, it will keep duplicated values (unless the given "purgeFunction" purge them).</p></td>
|
3336 | </tr>
|
3337 |
|
3338 |
|
3339 | </tbody>
|
3340 | </table>
|
3341 |
|
3342 |
|
3343 |
|
3344 |
|
3345 | <dl class="details">
|
3346 |
|
3347 |
|
3348 |
|
3349 |
|
3350 |
|
3351 |
|
3352 |
|
3353 |
|
3354 |
|
3355 |
|
3356 |
|
3357 |
|
3358 |
|
3359 |
|
3360 |
|
3361 |
|
3362 |
|
3363 |
|
3364 |
|
3365 |
|
3366 |
|
3367 |
|
3368 |
|
3369 |
|
3370 |
|
3371 |
|
3372 |
|
3373 |
|
3374 |
|
3375 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3376 | <dd class="tag-source">
|
3377 | <ul class="dummy">
|
3378 | <li>
|
3379 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
3380 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-301">line 301</a>
|
3381 | </li>
|
3382 | </ul>
|
3383 | </dd>
|
3384 |
|
3385 |
|
3386 |
|
3387 |
|
3388 |
|
3389 |
|
3390 |
|
3391 | </dl>
|
3392 |
|
3393 |
|
3394 |
|
3395 |
|
3396 |
|
3397 |
|
3398 |
|
3399 |
|
3400 |
|
3401 |
|
3402 |
|
3403 |
|
3404 |
|
3405 | <h5>Returns:</h5>
|
3406 |
|
3407 |
|
3408 | <div class="param-desc">
|
3409 | <p>Returns the array purged. If no valid array is given, it will return an empty array.</p>
|
3410 | </div>
|
3411 |
|
3412 |
|
3413 |
|
3414 | <dl>
|
3415 | <dt>
|
3416 | Type
|
3417 | </dt>
|
3418 | <dd>
|
3419 |
|
3420 | <span class="param-type">array</span>
|
3421 |
|
3422 |
|
3423 |
|
3424 | </dd>
|
3425 | </dl>
|
3426 |
|
3427 |
|
3428 |
|
3429 |
|
3430 |
|
3431 | </dd>
|
3432 |
|
3433 |
|
3434 |
|
3435 | <hr>
|
3436 | <dt>
|
3437 | <h4 class="name" id=".removeElement"><span class="type-signature"><static> </span>removeElement<span class="signature">(array [, element] [, onRemove])</span><span class="type-signature"> → {array}</span></h4>
|
3438 |
|
3439 |
|
3440 | </dt>
|
3441 | <dd>
|
3442 |
|
3443 |
|
3444 | <div class="description">
|
3445 | <p>Deletes a given element from an array. All occurrences will be deleted. Elements which were after a removed element will be moved a position to the left (decreasing their index).</p>
|
3446 | </div>
|
3447 |
|
3448 |
|
3449 |
|
3450 |
|
3451 |
|
3452 |
|
3453 |
|
3454 |
|
3455 | <h5>Parameters:</h5>
|
3456 |
|
3457 |
|
3458 | <table class="params table table-striped">
|
3459 | <thead>
|
3460 | <tr>
|
3461 |
|
3462 | <th style="width:12%; min-width:110px;">Name</th>
|
3463 |
|
3464 |
|
3465 | <th style="width:12%; min-width:110px;">Type</th>
|
3466 |
|
3467 |
|
3468 | <th style="width:12%; min-width:110px;">Argument</th>
|
3469 |
|
3470 |
|
3471 |
|
3472 |
|
3473 | <th class="last" style="min-width:310px;">Description</th>
|
3474 | </tr>
|
3475 | </thead>
|
3476 |
|
3477 | <tbody>
|
3478 |
|
3479 |
|
3480 | <tr>
|
3481 |
|
3482 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
3483 |
|
3484 |
|
3485 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3486 |
|
3487 |
|
3488 | <span class="param-type">array</span>
|
3489 |
|
3490 |
|
3491 |
|
3492 |
|
3493 | </td>
|
3494 |
|
3495 |
|
3496 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3497 |
|
3498 |
|
3499 |
|
3500 |
|
3501 |
|
3502 | </td>
|
3503 |
|
3504 |
|
3505 |
|
3506 |
|
3507 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The array whose element we want to delete.</p></td>
|
3508 | </tr>
|
3509 |
|
3510 |
|
3511 |
|
3512 | <tr>
|
3513 |
|
3514 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
|
3515 |
|
3516 |
|
3517 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3518 |
|
3519 |
|
3520 | <span class="param-type">*</span>
|
3521 |
|
3522 |
|
3523 |
|
3524 |
|
3525 | </td>
|
3526 |
|
3527 |
|
3528 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3529 |
|
3530 | <optional><br>
|
3531 |
|
3532 |
|
3533 |
|
3534 |
|
3535 |
|
3536 | </td>
|
3537 |
|
3538 |
|
3539 |
|
3540 |
|
3541 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element we want to remove. All occurrences will be deleted. Note that it is type sensitive.</p></td>
|
3542 | </tr>
|
3543 |
|
3544 |
|
3545 |
|
3546 | <tr>
|
3547 |
|
3548 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onRemove</code></td>
|
3549 |
|
3550 |
|
3551 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3552 |
|
3553 |
|
3554 | <span class="param-type"><a href="CB_Arrays.html#.removeDuplicated_PURGE_FUNCTION">CB_Arrays.removeDuplicated_PURGE_FUNCTION</a></span>
|
3555 |
|
3556 |
|
3557 |
|
3558 |
|
3559 | </td>
|
3560 |
|
3561 |
|
3562 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3563 |
|
3564 | <optional><br>
|
3565 |
|
3566 |
|
3567 |
|
3568 |
|
3569 |
|
3570 | </td>
|
3571 |
|
3572 |
|
3573 |
|
3574 |
|
3575 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function to call if the element is removed, before removing it.</p></td>
|
3576 | </tr>
|
3577 |
|
3578 |
|
3579 | </tbody>
|
3580 | </table>
|
3581 |
|
3582 |
|
3583 |
|
3584 |
|
3585 | <dl class="details">
|
3586 |
|
3587 |
|
3588 |
|
3589 |
|
3590 |
|
3591 |
|
3592 |
|
3593 |
|
3594 |
|
3595 |
|
3596 |
|
3597 |
|
3598 |
|
3599 |
|
3600 |
|
3601 |
|
3602 |
|
3603 |
|
3604 |
|
3605 |
|
3606 |
|
3607 |
|
3608 |
|
3609 |
|
3610 |
|
3611 |
|
3612 |
|
3613 |
|
3614 |
|
3615 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3616 | <dd class="tag-source">
|
3617 | <ul class="dummy">
|
3618 | <li>
|
3619 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
3620 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-351">line 351</a>
|
3621 | </li>
|
3622 | </ul>
|
3623 | </dd>
|
3624 |
|
3625 |
|
3626 |
|
3627 |
|
3628 |
|
3629 |
|
3630 |
|
3631 | </dl>
|
3632 |
|
3633 |
|
3634 |
|
3635 |
|
3636 |
|
3637 |
|
3638 |
|
3639 |
|
3640 |
|
3641 |
|
3642 |
|
3643 |
|
3644 |
|
3645 | <h5>Returns:</h5>
|
3646 |
|
3647 |
|
3648 | <div class="param-desc">
|
3649 | <p>Returns the new array (with the element removed if it was possible). If no valid array is given, it will return an empty array.</p>
|
3650 | </div>
|
3651 |
|
3652 |
|
3653 |
|
3654 | <dl>
|
3655 | <dt>
|
3656 | Type
|
3657 | </dt>
|
3658 | <dd>
|
3659 |
|
3660 | <span class="param-type">array</span>
|
3661 |
|
3662 |
|
3663 |
|
3664 | </dd>
|
3665 | </dl>
|
3666 |
|
3667 |
|
3668 |
|
3669 |
|
3670 |
|
3671 | </dd>
|
3672 |
|
3673 |
|
3674 |
|
3675 | <hr>
|
3676 | <dt>
|
3677 | <h4 class="name" id=".removeElementByIndex"><span class="type-signature"><static> </span>removeElementByIndex<span class="signature">()</span><span class="type-signature"></span></h4>
|
3678 |
|
3679 |
|
3680 | </dt>
|
3681 | <dd>
|
3682 |
|
3683 |
|
3684 | <div class="description">
|
3685 | <p>Alias for <a href="CB_Arrays.html#.removeElementByPosition"><code>CB_Arrays.removeElementByPosition</code></a>.</p>
|
3686 | </div>
|
3687 |
|
3688 |
|
3689 |
|
3690 |
|
3691 |
|
3692 |
|
3693 |
|
3694 |
|
3695 |
|
3696 |
|
3697 | <dl class="details">
|
3698 |
|
3699 |
|
3700 |
|
3701 |
|
3702 |
|
3703 |
|
3704 |
|
3705 |
|
3706 |
|
3707 |
|
3708 |
|
3709 |
|
3710 |
|
3711 |
|
3712 |
|
3713 |
|
3714 |
|
3715 |
|
3716 |
|
3717 |
|
3718 |
|
3719 |
|
3720 |
|
3721 |
|
3722 |
|
3723 |
|
3724 |
|
3725 |
|
3726 |
|
3727 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3728 | <dd class="tag-source">
|
3729 | <ul class="dummy">
|
3730 | <li>
|
3731 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
3732 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-321">line 321</a>
|
3733 | </li>
|
3734 | </ul>
|
3735 | </dd>
|
3736 |
|
3737 |
|
3738 |
|
3739 |
|
3740 |
|
3741 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
3742 | <dd class="tag-see">
|
3743 | <ul>
|
3744 | <li><a href="CB_Arrays.html#.removeElementByPosition"><code>CB_Arrays.removeElementByPosition</code></a></li>
|
3745 | </ul>
|
3746 | </dd>
|
3747 |
|
3748 |
|
3749 |
|
3750 | </dl>
|
3751 |
|
3752 |
|
3753 |
|
3754 |
|
3755 |
|
3756 |
|
3757 |
|
3758 |
|
3759 |
|
3760 |
|
3761 |
|
3762 |
|
3763 |
|
3764 |
|
3765 |
|
3766 | </dd>
|
3767 |
|
3768 |
|
3769 |
|
3770 | <hr>
|
3771 | <dt>
|
3772 | <h4 class="name" id=".removeElementByPosition"><span class="type-signature"><static> </span>removeElementByPosition<span class="signature">(array [, index] [, onRemove])</span><span class="type-signature"> → {array}</span></h4>
|
3773 |
|
3774 |
|
3775 | </dt>
|
3776 | <dd>
|
3777 |
|
3778 |
|
3779 | <div class="description">
|
3780 | <p>Deletes an element from an array which is placed in the desired position. Elements which were after it will be moved a position to the left (decreasing their index).</p>
|
3781 | </div>
|
3782 |
|
3783 |
|
3784 |
|
3785 |
|
3786 |
|
3787 |
|
3788 |
|
3789 |
|
3790 | <h5>Parameters:</h5>
|
3791 |
|
3792 |
|
3793 | <table class="params table table-striped">
|
3794 | <thead>
|
3795 | <tr>
|
3796 |
|
3797 | <th style="width:12%; min-width:110px;">Name</th>
|
3798 |
|
3799 |
|
3800 | <th style="width:12%; min-width:110px;">Type</th>
|
3801 |
|
3802 |
|
3803 | <th style="width:12%; min-width:110px;">Argument</th>
|
3804 |
|
3805 |
|
3806 |
|
3807 | <th style="width:12%; min-width:110px;">Default</th>
|
3808 |
|
3809 |
|
3810 | <th class="last" style="min-width:310px;">Description</th>
|
3811 | </tr>
|
3812 | </thead>
|
3813 |
|
3814 | <tbody>
|
3815 |
|
3816 |
|
3817 | <tr>
|
3818 |
|
3819 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
3820 |
|
3821 |
|
3822 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3823 |
|
3824 |
|
3825 | <span class="param-type">array</span>
|
3826 |
|
3827 |
|
3828 |
|
3829 |
|
3830 | </td>
|
3831 |
|
3832 |
|
3833 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3834 |
|
3835 |
|
3836 |
|
3837 |
|
3838 |
|
3839 | </td>
|
3840 |
|
3841 |
|
3842 |
|
3843 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3844 |
|
3845 | </td>
|
3846 |
|
3847 |
|
3848 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The array whose element we want to delete.</p></td>
|
3849 | </tr>
|
3850 |
|
3851 |
|
3852 |
|
3853 | <tr>
|
3854 |
|
3855 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
|
3856 |
|
3857 |
|
3858 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3859 |
|
3860 |
|
3861 | <span class="param-type">integer</span>
|
3862 |
|
3863 |
|
3864 |
|
3865 |
|
3866 | </td>
|
3867 |
|
3868 |
|
3869 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3870 |
|
3871 | <optional><br>
|
3872 |
|
3873 |
|
3874 |
|
3875 |
|
3876 |
|
3877 | </td>
|
3878 |
|
3879 |
|
3880 |
|
3881 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3882 |
|
3883 | 0
|
3884 |
|
3885 | </td>
|
3886 |
|
3887 |
|
3888 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Position of the element in the given array that we want to remove.</p></td>
|
3889 | </tr>
|
3890 |
|
3891 |
|
3892 |
|
3893 | <tr>
|
3894 |
|
3895 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onRemove</code></td>
|
3896 |
|
3897 |
|
3898 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3899 |
|
3900 |
|
3901 | <span class="param-type"><a href="CB_Arrays.html#.removeDuplicated_PURGE_FUNCTION">CB_Arrays.removeDuplicated_PURGE_FUNCTION</a></span>
|
3902 |
|
3903 |
|
3904 |
|
3905 |
|
3906 | </td>
|
3907 |
|
3908 |
|
3909 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3910 |
|
3911 | <optional><br>
|
3912 |
|
3913 |
|
3914 |
|
3915 |
|
3916 |
|
3917 | </td>
|
3918 |
|
3919 |
|
3920 |
|
3921 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3922 |
|
3923 | </td>
|
3924 |
|
3925 |
|
3926 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function to call if the element is removed, before removing it.</p></td>
|
3927 | </tr>
|
3928 |
|
3929 |
|
3930 | </tbody>
|
3931 | </table>
|
3932 |
|
3933 |
|
3934 |
|
3935 |
|
3936 | <dl class="details">
|
3937 |
|
3938 |
|
3939 |
|
3940 |
|
3941 |
|
3942 |
|
3943 |
|
3944 |
|
3945 |
|
3946 |
|
3947 |
|
3948 |
|
3949 |
|
3950 |
|
3951 |
|
3952 |
|
3953 |
|
3954 |
|
3955 |
|
3956 |
|
3957 |
|
3958 |
|
3959 |
|
3960 |
|
3961 |
|
3962 |
|
3963 |
|
3964 |
|
3965 |
|
3966 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3967 | <dd class="tag-source">
|
3968 | <ul class="dummy">
|
3969 | <li>
|
3970 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
3971 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-334">line 334</a>
|
3972 | </li>
|
3973 | </ul>
|
3974 | </dd>
|
3975 |
|
3976 |
|
3977 |
|
3978 |
|
3979 |
|
3980 |
|
3981 |
|
3982 | </dl>
|
3983 |
|
3984 |
|
3985 |
|
3986 |
|
3987 |
|
3988 |
|
3989 |
|
3990 |
|
3991 |
|
3992 |
|
3993 |
|
3994 |
|
3995 |
|
3996 | <h5>Returns:</h5>
|
3997 |
|
3998 |
|
3999 | <div class="param-desc">
|
4000 | <p>Returns the new array (with the element removed if it was possible). If no valid array is given, it will return an empty array.</p>
|
4001 | </div>
|
4002 |
|
4003 |
|
4004 |
|
4005 | <dl>
|
4006 | <dt>
|
4007 | Type
|
4008 | </dt>
|
4009 | <dd>
|
4010 |
|
4011 | <span class="param-type">array</span>
|
4012 |
|
4013 |
|
4014 |
|
4015 | </dd>
|
4016 | </dl>
|
4017 |
|
4018 |
|
4019 |
|
4020 |
|
4021 |
|
4022 | </dd>
|
4023 |
|
4024 |
|
4025 |
|
4026 | <hr>
|
4027 | <dt>
|
4028 | <h4 class="name" id=".removeElements"><span class="type-signature"><static> </span>removeElements<span class="signature">(array, elements)</span><span class="type-signature"> → {array}</span></h4>
|
4029 |
|
4030 |
|
4031 | </dt>
|
4032 | <dd>
|
4033 |
|
4034 |
|
4035 | <div class="description">
|
4036 | <p>Deletes the given elements from an array. All occurrences will be deleted. Elements which were after a removed element will be moved a position to the left (decreasing their index).</p>
|
4037 | </div>
|
4038 |
|
4039 |
|
4040 |
|
4041 |
|
4042 |
|
4043 |
|
4044 |
|
4045 |
|
4046 | <h5>Parameters:</h5>
|
4047 |
|
4048 |
|
4049 | <table class="params table table-striped">
|
4050 | <thead>
|
4051 | <tr>
|
4052 |
|
4053 | <th style="width:12%; min-width:110px;">Name</th>
|
4054 |
|
4055 |
|
4056 | <th style="width:12%; min-width:110px;">Type</th>
|
4057 |
|
4058 |
|
4059 |
|
4060 |
|
4061 |
|
4062 | <th class="last" style="min-width:310px;">Description</th>
|
4063 | </tr>
|
4064 | </thead>
|
4065 |
|
4066 | <tbody>
|
4067 |
|
4068 |
|
4069 | <tr>
|
4070 |
|
4071 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
4072 |
|
4073 |
|
4074 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4075 |
|
4076 |
|
4077 | <span class="param-type">array</span>
|
4078 |
|
4079 |
|
4080 |
|
4081 |
|
4082 | </td>
|
4083 |
|
4084 |
|
4085 |
|
4086 |
|
4087 |
|
4088 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The array whose element we want to delete.</p></td>
|
4089 | </tr>
|
4090 |
|
4091 |
|
4092 |
|
4093 | <tr>
|
4094 |
|
4095 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>elements</code></td>
|
4096 |
|
4097 |
|
4098 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4099 |
|
4100 |
|
4101 | <span class="param-type">array</span>
|
4102 |
|
4103 |
|
4104 |
|
4105 |
|
4106 | </td>
|
4107 |
|
4108 |
|
4109 |
|
4110 |
|
4111 |
|
4112 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>An array with the elements we want to remove. All occurrences will be deleted. Note that it is type sensitive.</p></td>
|
4113 | </tr>
|
4114 |
|
4115 |
|
4116 | </tbody>
|
4117 | </table>
|
4118 |
|
4119 |
|
4120 |
|
4121 |
|
4122 | <dl class="details">
|
4123 |
|
4124 |
|
4125 |
|
4126 |
|
4127 |
|
4128 |
|
4129 |
|
4130 |
|
4131 |
|
4132 |
|
4133 |
|
4134 |
|
4135 |
|
4136 |
|
4137 |
|
4138 |
|
4139 |
|
4140 |
|
4141 |
|
4142 |
|
4143 |
|
4144 |
|
4145 |
|
4146 |
|
4147 |
|
4148 |
|
4149 |
|
4150 |
|
4151 |
|
4152 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
4153 | <dd class="tag-source">
|
4154 | <ul class="dummy">
|
4155 | <li>
|
4156 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
4157 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-364">line 364</a>
|
4158 | </li>
|
4159 | </ul>
|
4160 | </dd>
|
4161 |
|
4162 |
|
4163 |
|
4164 |
|
4165 |
|
4166 |
|
4167 |
|
4168 | </dl>
|
4169 |
|
4170 |
|
4171 |
|
4172 |
|
4173 |
|
4174 |
|
4175 |
|
4176 |
|
4177 |
|
4178 |
|
4179 |
|
4180 |
|
4181 |
|
4182 | <h5>Returns:</h5>
|
4183 |
|
4184 |
|
4185 | <div class="param-desc">
|
4186 | <p>Returns the new array (with the element removed if it was possible). If no valid array is given, it will return an empty array.</p>
|
4187 | </div>
|
4188 |
|
4189 |
|
4190 |
|
4191 | <dl>
|
4192 | <dt>
|
4193 | Type
|
4194 | </dt>
|
4195 | <dd>
|
4196 |
|
4197 | <span class="param-type">array</span>
|
4198 |
|
4199 |
|
4200 |
|
4201 | </dd>
|
4202 | </dl>
|
4203 |
|
4204 |
|
4205 |
|
4206 |
|
4207 |
|
4208 | </dd>
|
4209 |
|
4210 |
|
4211 |
|
4212 | <hr>
|
4213 | <dt>
|
4214 | <h4 class="name" id=".replaceAll"><span class="type-signature"><static> </span>replaceAll<span class="signature">(stringOrArray, stringOrArrayFind [, stringReplace] [, caseInsensitive])</span><span class="type-signature"> → {string|array}</span></h4>
|
4215 |
|
4216 |
|
4217 | </dt>
|
4218 | <dd>
|
4219 |
|
4220 |
|
4221 | <div class="description">
|
4222 | <p>Returns the string or array of strings with all the desired occurrences replaced. Calls itself recursively and calls the <a href="global.html#CB_regularExpressionString"><code>CB_regularExpressionString</code></a> function internally.</p>
|
4223 | </div>
|
4224 |
|
4225 |
|
4226 |
|
4227 |
|
4228 |
|
4229 |
|
4230 |
|
4231 |
|
4232 | <h5>Parameters:</h5>
|
4233 |
|
4234 |
|
4235 | <table class="params table table-striped">
|
4236 | <thead>
|
4237 | <tr>
|
4238 |
|
4239 | <th style="width:12%; min-width:110px;">Name</th>
|
4240 |
|
4241 |
|
4242 | <th style="width:12%; min-width:110px;">Type</th>
|
4243 |
|
4244 |
|
4245 | <th style="width:12%; min-width:110px;">Argument</th>
|
4246 |
|
4247 |
|
4248 |
|
4249 | <th style="width:12%; min-width:110px;">Default</th>
|
4250 |
|
4251 |
|
4252 | <th class="last" style="min-width:310px;">Description</th>
|
4253 | </tr>
|
4254 | </thead>
|
4255 |
|
4256 | <tbody>
|
4257 |
|
4258 |
|
4259 | <tr>
|
4260 |
|
4261 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>stringOrArray</code></td>
|
4262 |
|
4263 |
|
4264 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4265 |
|
4266 |
|
4267 | <span class="param-type">string</span>
|
4268 | |
|
4269 |
|
4270 | <span class="param-type">array</span>
|
4271 |
|
4272 |
|
4273 |
|
4274 |
|
4275 | </td>
|
4276 |
|
4277 |
|
4278 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4279 |
|
4280 |
|
4281 |
|
4282 |
|
4283 |
|
4284 | </td>
|
4285 |
|
4286 |
|
4287 |
|
4288 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4289 |
|
4290 | </td>
|
4291 |
|
4292 |
|
4293 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>An string or an array of strings whose content we want to replace. It can also be an array of arrays of strings (as many levels as you wish). If an array is given, it will not be modified and a copy from it will be generated and returned with the occurrences replaced.</p></td>
|
4294 | </tr>
|
4295 |
|
4296 |
|
4297 |
|
4298 | <tr>
|
4299 |
|
4300 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>stringOrArrayFind</code></td>
|
4301 |
|
4302 |
|
4303 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4304 |
|
4305 |
|
4306 | <span class="param-type">string</span>
|
4307 | |
|
4308 |
|
4309 | <span class="param-type">array</span>
|
4310 |
|
4311 |
|
4312 |
|
4313 |
|
4314 | </td>
|
4315 |
|
4316 |
|
4317 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4318 |
|
4319 |
|
4320 |
|
4321 |
|
4322 |
|
4323 | </td>
|
4324 |
|
4325 |
|
4326 |
|
4327 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4328 |
|
4329 | </td>
|
4330 |
|
4331 |
|
4332 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>An string or an array of strings (not a regular expressions) that we want to find to be replaced (special characters will be escaped).</p></td>
|
4333 | </tr>
|
4334 |
|
4335 |
|
4336 |
|
4337 | <tr>
|
4338 |
|
4339 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>stringReplace</code></td>
|
4340 |
|
4341 |
|
4342 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4343 |
|
4344 |
|
4345 | <span class="param-type">string</span>
|
4346 |
|
4347 |
|
4348 |
|
4349 |
|
4350 | </td>
|
4351 |
|
4352 |
|
4353 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4354 |
|
4355 | <optional><br>
|
4356 |
|
4357 |
|
4358 |
|
4359 |
|
4360 |
|
4361 | </td>
|
4362 |
|
4363 |
|
4364 |
|
4365 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4366 |
|
4367 | ""
|
4368 |
|
4369 | </td>
|
4370 |
|
4371 |
|
4372 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The string that will replace "stringFind". If not provided, it will be replaced as an empty string (it will just remove the occurrences found).</p></td>
|
4373 | </tr>
|
4374 |
|
4375 |
|
4376 |
|
4377 | <tr>
|
4378 |
|
4379 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>caseInsensitive</code></td>
|
4380 |
|
4381 |
|
4382 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4383 |
|
4384 |
|
4385 | <span class="param-type">boolean</span>
|
4386 |
|
4387 |
|
4388 |
|
4389 |
|
4390 | </td>
|
4391 |
|
4392 |
|
4393 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4394 |
|
4395 | <optional><br>
|
4396 |
|
4397 |
|
4398 |
|
4399 |
|
4400 |
|
4401 | </td>
|
4402 |
|
4403 |
|
4404 |
|
4405 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4406 |
|
4407 | false
|
4408 |
|
4409 | </td>
|
4410 |
|
4411 |
|
4412 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether we want to be case insensitive or not.</p></td>
|
4413 | </tr>
|
4414 |
|
4415 |
|
4416 | </tbody>
|
4417 | </table>
|
4418 |
|
4419 |
|
4420 |
|
4421 |
|
4422 | <dl class="details">
|
4423 |
|
4424 |
|
4425 |
|
4426 |
|
4427 |
|
4428 |
|
4429 |
|
4430 |
|
4431 |
|
4432 |
|
4433 |
|
4434 |
|
4435 |
|
4436 |
|
4437 |
|
4438 |
|
4439 |
|
4440 |
|
4441 |
|
4442 |
|
4443 |
|
4444 |
|
4445 |
|
4446 |
|
4447 |
|
4448 |
|
4449 |
|
4450 |
|
4451 |
|
4452 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
4453 | <dd class="tag-source">
|
4454 | <ul class="dummy">
|
4455 | <li>
|
4456 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
4457 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1437">line 1437</a>
|
4458 | </li>
|
4459 | </ul>
|
4460 | </dd>
|
4461 |
|
4462 |
|
4463 |
|
4464 |
|
4465 |
|
4466 |
|
4467 |
|
4468 | </dl>
|
4469 |
|
4470 |
|
4471 |
|
4472 |
|
4473 |
|
4474 |
|
4475 |
|
4476 |
|
4477 |
|
4478 |
|
4479 |
|
4480 |
|
4481 |
|
4482 | <h5>Returns:</h5>
|
4483 |
|
4484 |
|
4485 | <div class="param-desc">
|
4486 | <p>Returns the "stringOrArray" given with occurrences replaced. If the "stringOrArray" given was neither a string nor an array, it will be returned without being modified.</p>
|
4487 | </div>
|
4488 |
|
4489 |
|
4490 |
|
4491 | <dl>
|
4492 | <dt>
|
4493 | Type
|
4494 | </dt>
|
4495 | <dd>
|
4496 |
|
4497 | <span class="param-type">string</span>
|
4498 | |
|
4499 |
|
4500 | <span class="param-type">array</span>
|
4501 |
|
4502 |
|
4503 |
|
4504 | </dd>
|
4505 | </dl>
|
4506 |
|
4507 |
|
4508 |
|
4509 |
|
4510 |
|
4511 | </dd>
|
4512 |
|
4513 |
|
4514 |
|
4515 | <hr>
|
4516 | <dt>
|
4517 | <h4 class="name" id=".rtrim"><span class="type-signature"><static> </span>rtrim<span class="signature">(element [, undesiredStrings])</span><span class="type-signature"> → {string|array}</span></h4>
|
4518 |
|
4519 |
|
4520 | </dt>
|
4521 | <dd>
|
4522 |
|
4523 |
|
4524 | <div class="description">
|
4525 | <p>Trims the right side of a given string or array of strings (modifying the given array), taking off the desired strings or otherwise trimming spaces, tabs ("\t"), new lines ("\n") and carriage returns ("\r"). Case sensitive.</p>
|
4526 | </div>
|
4527 |
|
4528 |
|
4529 |
|
4530 |
|
4531 |
|
4532 |
|
4533 |
|
4534 |
|
4535 | <h5>Parameters:</h5>
|
4536 |
|
4537 |
|
4538 | <table class="params table table-striped">
|
4539 | <thead>
|
4540 | <tr>
|
4541 |
|
4542 | <th style="width:12%; min-width:110px;">Name</th>
|
4543 |
|
4544 |
|
4545 | <th style="width:12%; min-width:110px;">Type</th>
|
4546 |
|
4547 |
|
4548 | <th style="width:12%; min-width:110px;">Argument</th>
|
4549 |
|
4550 |
|
4551 |
|
4552 | <th style="width:12%; min-width:110px;">Default</th>
|
4553 |
|
4554 |
|
4555 | <th class="last" style="min-width:310px;">Description</th>
|
4556 | </tr>
|
4557 | </thead>
|
4558 |
|
4559 | <tbody>
|
4560 |
|
4561 |
|
4562 | <tr>
|
4563 |
|
4564 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
|
4565 |
|
4566 |
|
4567 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4568 |
|
4569 |
|
4570 | <span class="param-type">string</span>
|
4571 | |
|
4572 |
|
4573 | <span class="param-type">array</span>
|
4574 |
|
4575 |
|
4576 |
|
4577 |
|
4578 | </td>
|
4579 |
|
4580 |
|
4581 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4582 |
|
4583 |
|
4584 |
|
4585 |
|
4586 |
|
4587 | </td>
|
4588 |
|
4589 |
|
4590 |
|
4591 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4592 |
|
4593 | </td>
|
4594 |
|
4595 |
|
4596 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element that will be trimmed. It should be either a string or an array of strings.</p></td>
|
4597 | </tr>
|
4598 |
|
4599 |
|
4600 |
|
4601 | <tr>
|
4602 |
|
4603 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>undesiredStrings</code></td>
|
4604 |
|
4605 |
|
4606 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4607 |
|
4608 |
|
4609 | <span class="param-type">string</span>
|
4610 | |
|
4611 |
|
4612 | <span class="param-type">array</span>
|
4613 |
|
4614 |
|
4615 |
|
4616 |
|
4617 | </td>
|
4618 |
|
4619 |
|
4620 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4621 |
|
4622 | <optional><br>
|
4623 |
|
4624 |
|
4625 |
|
4626 |
|
4627 |
|
4628 | </td>
|
4629 |
|
4630 |
|
4631 |
|
4632 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4633 |
|
4634 | [ " ", "\n", "\r", "\t" ]
|
4635 |
|
4636 | </td>
|
4637 |
|
4638 |
|
4639 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String or an array with the strings that we want to trim off the given element.</p></td>
|
4640 | </tr>
|
4641 |
|
4642 |
|
4643 | </tbody>
|
4644 | </table>
|
4645 |
|
4646 |
|
4647 |
|
4648 |
|
4649 | <dl class="details">
|
4650 |
|
4651 |
|
4652 |
|
4653 |
|
4654 |
|
4655 |
|
4656 |
|
4657 |
|
4658 |
|
4659 |
|
4660 |
|
4661 |
|
4662 |
|
4663 |
|
4664 |
|
4665 |
|
4666 |
|
4667 |
|
4668 |
|
4669 |
|
4670 |
|
4671 |
|
4672 |
|
4673 |
|
4674 |
|
4675 |
|
4676 |
|
4677 |
|
4678 |
|
4679 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
4680 | <dd class="tag-source">
|
4681 | <ul class="dummy">
|
4682 | <li>
|
4683 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
4684 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-309">line 309</a>
|
4685 | </li>
|
4686 | </ul>
|
4687 | </dd>
|
4688 |
|
4689 |
|
4690 |
|
4691 |
|
4692 |
|
4693 |
|
4694 |
|
4695 | <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
|
4696 | <dd class="tag-todo">
|
4697 | <ul>
|
4698 | <li>Accept a "recursive" parameter (boolean) to affect multiple levels (array of arrays of strings, etc.).</li>
|
4699 |
|
4700 | <li>Consider accepting objects instead of arrays in the "element" parameter.</li>
|
4701 |
|
4702 | <li>Think about optimizing (using a counter for the number of occurrences in the loop and trim all the occurrences when finished).</li>
|
4703 | </ul>
|
4704 | </dd>
|
4705 |
|
4706 | </dl>
|
4707 |
|
4708 |
|
4709 |
|
4710 |
|
4711 |
|
4712 |
|
4713 |
|
4714 |
|
4715 |
|
4716 |
|
4717 |
|
4718 |
|
4719 |
|
4720 | <h5>Returns:</h5>
|
4721 |
|
4722 |
|
4723 | <div class="param-desc">
|
4724 | <p>Returns the given element again if it was an string, a number (it will be casted to a string) or an array of strings, trimmed if it has been possible. If it was another type, returns an empty string.</p>
|
4725 | </div>
|
4726 |
|
4727 |
|
4728 |
|
4729 | <dl>
|
4730 | <dt>
|
4731 | Type
|
4732 | </dt>
|
4733 | <dd>
|
4734 |
|
4735 | <span class="param-type">string</span>
|
4736 | |
|
4737 |
|
4738 | <span class="param-type">array</span>
|
4739 |
|
4740 |
|
4741 |
|
4742 | </dd>
|
4743 | </dl>
|
4744 |
|
4745 |
|
4746 |
|
4747 |
|
4748 |
|
4749 | </dd>
|
4750 |
|
4751 |
|
4752 |
|
4753 | <hr>
|
4754 | <dt>
|
4755 | <h4 class="name" id=".sizeof"><span class="type-signature"><static> </span>sizeof<span class="signature">()</span><span class="type-signature"></span></h4>
|
4756 |
|
4757 |
|
4758 | </dt>
|
4759 | <dd>
|
4760 |
|
4761 |
|
4762 | <div class="description">
|
4763 | <p>Alias for <a href="CB_Arrays.html#.sizeOf"><code>CB_Arrays.sizeOf</code></a>.</p>
|
4764 | </div>
|
4765 |
|
4766 |
|
4767 |
|
4768 |
|
4769 |
|
4770 |
|
4771 |
|
4772 |
|
4773 |
|
4774 |
|
4775 | <dl class="details">
|
4776 |
|
4777 |
|
4778 |
|
4779 |
|
4780 |
|
4781 |
|
4782 |
|
4783 |
|
4784 |
|
4785 |
|
4786 |
|
4787 |
|
4788 |
|
4789 |
|
4790 |
|
4791 |
|
4792 |
|
4793 |
|
4794 |
|
4795 |
|
4796 |
|
4797 |
|
4798 |
|
4799 |
|
4800 |
|
4801 |
|
4802 |
|
4803 |
|
4804 |
|
4805 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
4806 | <dd class="tag-source">
|
4807 | <ul class="dummy">
|
4808 | <li>
|
4809 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
4810 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-61">line 61</a>
|
4811 | </li>
|
4812 | </ul>
|
4813 | </dd>
|
4814 |
|
4815 |
|
4816 |
|
4817 |
|
4818 |
|
4819 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
4820 | <dd class="tag-see">
|
4821 | <ul>
|
4822 | <li><a href="CB_Arrays.html#.sizeOf"><code>CB_Arrays.sizeOf</code></a></li>
|
4823 | </ul>
|
4824 | </dd>
|
4825 |
|
4826 |
|
4827 |
|
4828 | </dl>
|
4829 |
|
4830 |
|
4831 |
|
4832 |
|
4833 |
|
4834 |
|
4835 |
|
4836 |
|
4837 |
|
4838 |
|
4839 |
|
4840 |
|
4841 |
|
4842 |
|
4843 |
|
4844 | </dd>
|
4845 |
|
4846 |
|
4847 |
|
4848 | <hr>
|
4849 | <dt>
|
4850 | <h4 class="name" id=".sizeOf"><span class="type-signature"><static> </span>sizeOf<span class="signature">(element [, onlyOwn])</span><span class="type-signature"> → {integer}</span></h4>
|
4851 |
|
4852 |
|
4853 | </dt>
|
4854 | <dd>
|
4855 |
|
4856 |
|
4857 | <div class="description">
|
4858 | <p>Returns the size of an object or array.</p>
|
4859 | </div>
|
4860 |
|
4861 |
|
4862 |
|
4863 |
|
4864 |
|
4865 |
|
4866 |
|
4867 |
|
4868 | <h5>Parameters:</h5>
|
4869 |
|
4870 |
|
4871 | <table class="params table table-striped">
|
4872 | <thead>
|
4873 | <tr>
|
4874 |
|
4875 | <th style="width:12%; min-width:110px;">Name</th>
|
4876 |
|
4877 |
|
4878 | <th style="width:12%; min-width:110px;">Type</th>
|
4879 |
|
4880 |
|
4881 | <th style="width:12%; min-width:110px;">Argument</th>
|
4882 |
|
4883 |
|
4884 |
|
4885 | <th style="width:12%; min-width:110px;">Default</th>
|
4886 |
|
4887 |
|
4888 | <th class="last" style="min-width:310px;">Description</th>
|
4889 | </tr>
|
4890 | </thead>
|
4891 |
|
4892 | <tbody>
|
4893 |
|
4894 |
|
4895 | <tr>
|
4896 |
|
4897 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
|
4898 |
|
4899 |
|
4900 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4901 |
|
4902 |
|
4903 | <span class="param-type">Object</span>
|
4904 | |
|
4905 |
|
4906 | <span class="param-type">array</span>
|
4907 |
|
4908 |
|
4909 |
|
4910 |
|
4911 | </td>
|
4912 |
|
4913 |
|
4914 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4915 |
|
4916 |
|
4917 |
|
4918 |
|
4919 |
|
4920 | </td>
|
4921 |
|
4922 |
|
4923 |
|
4924 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4925 |
|
4926 | </td>
|
4927 |
|
4928 |
|
4929 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element whose size we want to know. It should be an object or an array.</p></td>
|
4930 | </tr>
|
4931 |
|
4932 |
|
4933 |
|
4934 | <tr>
|
4935 |
|
4936 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onlyOwn</code></td>
|
4937 |
|
4938 |
|
4939 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4940 |
|
4941 |
|
4942 | <span class="param-type">boolean</span>
|
4943 |
|
4944 |
|
4945 |
|
4946 |
|
4947 | </td>
|
4948 |
|
4949 |
|
4950 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4951 |
|
4952 | <optional><br>
|
4953 |
|
4954 |
|
4955 |
|
4956 |
|
4957 |
|
4958 | </td>
|
4959 |
|
4960 |
|
4961 |
|
4962 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4963 |
|
4964 | false
|
4965 |
|
4966 | </td>
|
4967 |
|
4968 |
|
4969 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If the "element" given is not an object, this parameter will be ignored. Otherwise, if it is set to true, it will only have into account the properties which the object has as their own property and have not been inherited (using the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/hasOwnProperty">Object.hasOwnProperty</a> method).</p></td>
|
4970 | </tr>
|
4971 |
|
4972 |
|
4973 | </tbody>
|
4974 | </table>
|
4975 |
|
4976 |
|
4977 |
|
4978 |
|
4979 | <dl class="details">
|
4980 |
|
4981 |
|
4982 |
|
4983 |
|
4984 |
|
4985 |
|
4986 |
|
4987 |
|
4988 |
|
4989 |
|
4990 |
|
4991 |
|
4992 |
|
4993 |
|
4994 |
|
4995 |
|
4996 |
|
4997 |
|
4998 |
|
4999 |
|
5000 |
|
5001 |
|
5002 |
|
5003 |
|
5004 |
|
5005 |
|
5006 |
|
5007 |
|
5008 |
|
5009 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
5010 | <dd class="tag-source">
|
5011 | <ul class="dummy">
|
5012 | <li>
|
5013 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
5014 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-207">line 207</a>
|
5015 | </li>
|
5016 | </ul>
|
5017 | </dd>
|
5018 |
|
5019 |
|
5020 |
|
5021 |
|
5022 |
|
5023 |
|
5024 |
|
5025 | </dl>
|
5026 |
|
5027 |
|
5028 |
|
5029 |
|
5030 |
|
5031 |
|
5032 |
|
5033 |
|
5034 |
|
5035 |
|
5036 |
|
5037 |
|
5038 |
|
5039 | <h5>Returns:</h5>
|
5040 |
|
5041 |
|
5042 | <div class="param-desc">
|
5043 | <p>If an object is provided, the size will be the number of its properties. Otherwise, if an array is given, the size will be the numbers of its indexes (<a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/length">Array.length</a> property).</p>
|
5044 | </div>
|
5045 |
|
5046 |
|
5047 |
|
5048 | <dl>
|
5049 | <dt>
|
5050 | Type
|
5051 | </dt>
|
5052 | <dd>
|
5053 |
|
5054 | <span class="param-type">integer</span>
|
5055 |
|
5056 |
|
5057 |
|
5058 | </dd>
|
5059 | </dl>
|
5060 |
|
5061 |
|
5062 |
|
5063 |
|
5064 |
|
5065 | </dd>
|
5066 |
|
5067 |
|
5068 |
|
5069 | <hr>
|
5070 | <dt>
|
5071 | <h4 class="name" id=".sort"><span class="type-signature"><static> </span>sort<span class="signature">(array [, reversed] [, comparingFunction])</span><span class="type-signature"> → {array}</span></h4>
|
5072 |
|
5073 |
|
5074 | </dt>
|
5075 | <dd>
|
5076 |
|
5077 |
|
5078 | <div class="description">
|
5079 | <p>Sorts the values of an array (using the native <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort">Array.sort</a> method).</p>
|
5080 | </div>
|
5081 |
|
5082 |
|
5083 |
|
5084 |
|
5085 |
|
5086 |
|
5087 |
|
5088 |
|
5089 | <h5>Parameters:</h5>
|
5090 |
|
5091 |
|
5092 | <table class="params table table-striped">
|
5093 | <thead>
|
5094 | <tr>
|
5095 |
|
5096 | <th style="width:12%; min-width:110px;">Name</th>
|
5097 |
|
5098 |
|
5099 | <th style="width:12%; min-width:110px;">Type</th>
|
5100 |
|
5101 |
|
5102 | <th style="width:12%; min-width:110px;">Argument</th>
|
5103 |
|
5104 |
|
5105 |
|
5106 | <th style="width:12%; min-width:110px;">Default</th>
|
5107 |
|
5108 |
|
5109 | <th class="last" style="min-width:310px;">Description</th>
|
5110 | </tr>
|
5111 | </thead>
|
5112 |
|
5113 | <tbody>
|
5114 |
|
5115 |
|
5116 | <tr>
|
5117 |
|
5118 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
5119 |
|
5120 |
|
5121 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5122 |
|
5123 |
|
5124 | <span class="param-type">array</span>
|
5125 |
|
5126 |
|
5127 |
|
5128 |
|
5129 | </td>
|
5130 |
|
5131 |
|
5132 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5133 |
|
5134 |
|
5135 |
|
5136 |
|
5137 |
|
5138 | </td>
|
5139 |
|
5140 |
|
5141 |
|
5142 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5143 |
|
5144 | </td>
|
5145 |
|
5146 |
|
5147 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The array whose elements we want to sort.</p></td>
|
5148 | </tr>
|
5149 |
|
5150 |
|
5151 |
|
5152 | <tr>
|
5153 |
|
5154 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>reversed</code></td>
|
5155 |
|
5156 |
|
5157 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5158 |
|
5159 |
|
5160 | <span class="param-type">boolean</span>
|
5161 |
|
5162 |
|
5163 |
|
5164 |
|
5165 | </td>
|
5166 |
|
5167 |
|
5168 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5169 |
|
5170 | <optional><br>
|
5171 |
|
5172 |
|
5173 |
|
5174 |
|
5175 |
|
5176 | </td>
|
5177 |
|
5178 |
|
5179 |
|
5180 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5181 |
|
5182 | false
|
5183 |
|
5184 | </td>
|
5185 |
|
5186 |
|
5187 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether to sort in the reverse order or not. Only applies when comparingFunction is not provided.</p></td>
|
5188 | </tr>
|
5189 |
|
5190 |
|
5191 |
|
5192 | <tr>
|
5193 |
|
5194 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>comparingFunction</code></td>
|
5195 |
|
5196 |
|
5197 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5198 |
|
5199 |
|
5200 | <span class="param-type">function</span>
|
5201 |
|
5202 |
|
5203 |
|
5204 |
|
5205 | </td>
|
5206 |
|
5207 |
|
5208 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5209 |
|
5210 | <optional><br>
|
5211 |
|
5212 |
|
5213 |
|
5214 |
|
5215 |
|
5216 | </td>
|
5217 |
|
5218 |
|
5219 |
|
5220 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5221 |
|
5222 | </td>
|
5223 |
|
5224 |
|
5225 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Comparing function with the same rules as the native <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort">Array.sort</a> method. If provided, the "reversed" parameter will be ignored.</p></td>
|
5226 | </tr>
|
5227 |
|
5228 |
|
5229 | </tbody>
|
5230 | </table>
|
5231 |
|
5232 |
|
5233 |
|
5234 |
|
5235 | <dl class="details">
|
5236 |
|
5237 |
|
5238 |
|
5239 |
|
5240 |
|
5241 |
|
5242 |
|
5243 |
|
5244 |
|
5245 |
|
5246 |
|
5247 |
|
5248 |
|
5249 |
|
5250 |
|
5251 |
|
5252 |
|
5253 |
|
5254 |
|
5255 |
|
5256 |
|
5257 |
|
5258 |
|
5259 |
|
5260 |
|
5261 |
|
5262 |
|
5263 |
|
5264 |
|
5265 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
5266 | <dd class="tag-source">
|
5267 | <ul class="dummy">
|
5268 | <li>
|
5269 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
5270 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-380">line 380</a>
|
5271 | </li>
|
5272 | </ul>
|
5273 | </dd>
|
5274 |
|
5275 |
|
5276 |
|
5277 |
|
5278 |
|
5279 |
|
5280 |
|
5281 | </dl>
|
5282 |
|
5283 |
|
5284 |
|
5285 |
|
5286 |
|
5287 |
|
5288 |
|
5289 |
|
5290 |
|
5291 |
|
5292 |
|
5293 |
|
5294 |
|
5295 | <h5>Returns:</h5>
|
5296 |
|
5297 |
|
5298 | <div class="param-desc">
|
5299 | <p>Returns the array ordered. If another value which is not an array is given, it will be returned again.</p>
|
5300 | </div>
|
5301 |
|
5302 |
|
5303 |
|
5304 | <dl>
|
5305 | <dt>
|
5306 | Type
|
5307 | </dt>
|
5308 | <dd>
|
5309 |
|
5310 | <span class="param-type">array</span>
|
5311 |
|
5312 |
|
5313 |
|
5314 | </dd>
|
5315 | </dl>
|
5316 |
|
5317 |
|
5318 |
|
5319 |
|
5320 |
|
5321 | </dd>
|
5322 |
|
5323 |
|
5324 |
|
5325 | <hr>
|
5326 | <dt>
|
5327 | <h4 class="name" id=".trim"><span class="type-signature"><static> </span>trim<span class="signature">(element [, undesiredStrings])</span><span class="type-signature"> → {string|array}</span></h4>
|
5328 |
|
5329 |
|
5330 | </dt>
|
5331 | <dd>
|
5332 |
|
5333 |
|
5334 | <div class="description">
|
5335 | <p>Trims a given string or array of strings (modifying the given array), taking off the desired strings or otherwise trimming spaces, tabs ("\t"), new lines ("\n") and carriage returns ("\r"). Case sensitive.</p>
|
5336 | </div>
|
5337 |
|
5338 |
|
5339 |
|
5340 |
|
5341 |
|
5342 |
|
5343 |
|
5344 |
|
5345 | <h5>Parameters:</h5>
|
5346 |
|
5347 |
|
5348 | <table class="params table table-striped">
|
5349 | <thead>
|
5350 | <tr>
|
5351 |
|
5352 | <th style="width:12%; min-width:110px;">Name</th>
|
5353 |
|
5354 |
|
5355 | <th style="width:12%; min-width:110px;">Type</th>
|
5356 |
|
5357 |
|
5358 | <th style="width:12%; min-width:110px;">Argument</th>
|
5359 |
|
5360 |
|
5361 |
|
5362 | <th style="width:12%; min-width:110px;">Default</th>
|
5363 |
|
5364 |
|
5365 | <th class="last" style="min-width:310px;">Description</th>
|
5366 | </tr>
|
5367 | </thead>
|
5368 |
|
5369 | <tbody>
|
5370 |
|
5371 |
|
5372 | <tr>
|
5373 |
|
5374 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
|
5375 |
|
5376 |
|
5377 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5378 |
|
5379 |
|
5380 | <span class="param-type">string</span>
|
5381 | |
|
5382 |
|
5383 | <span class="param-type">array</span>
|
5384 |
|
5385 |
|
5386 |
|
5387 |
|
5388 | </td>
|
5389 |
|
5390 |
|
5391 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5392 |
|
5393 |
|
5394 |
|
5395 |
|
5396 |
|
5397 | </td>
|
5398 |
|
5399 |
|
5400 |
|
5401 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5402 |
|
5403 | </td>
|
5404 |
|
5405 |
|
5406 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element that will be trimmed. It should be either a string or an array of strings.</p></td>
|
5407 | </tr>
|
5408 |
|
5409 |
|
5410 |
|
5411 | <tr>
|
5412 |
|
5413 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>undesiredStrings</code></td>
|
5414 |
|
5415 |
|
5416 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5417 |
|
5418 |
|
5419 | <span class="param-type">string</span>
|
5420 | |
|
5421 |
|
5422 | <span class="param-type">array</span>
|
5423 |
|
5424 |
|
5425 |
|
5426 |
|
5427 | </td>
|
5428 |
|
5429 |
|
5430 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5431 |
|
5432 | <optional><br>
|
5433 |
|
5434 |
|
5435 |
|
5436 |
|
5437 |
|
5438 | </td>
|
5439 |
|
5440 |
|
5441 |
|
5442 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5443 |
|
5444 | [ " ", "\n", "\r", "\t" ]
|
5445 |
|
5446 | </td>
|
5447 |
|
5448 |
|
5449 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String or an array with the strings that we want to trim off the given element.</p></td>
|
5450 | </tr>
|
5451 |
|
5452 |
|
5453 | </tbody>
|
5454 | </table>
|
5455 |
|
5456 |
|
5457 |
|
5458 |
|
5459 | <dl class="details">
|
5460 |
|
5461 |
|
5462 |
|
5463 |
|
5464 |
|
5465 |
|
5466 |
|
5467 |
|
5468 |
|
5469 |
|
5470 |
|
5471 |
|
5472 |
|
5473 |
|
5474 |
|
5475 |
|
5476 |
|
5477 |
|
5478 |
|
5479 |
|
5480 |
|
5481 |
|
5482 |
|
5483 |
|
5484 |
|
5485 |
|
5486 |
|
5487 |
|
5488 |
|
5489 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
5490 | <dd class="tag-source">
|
5491 | <ul class="dummy">
|
5492 | <li>
|
5493 | <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
|
5494 | <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-267">line 267</a>
|
5495 | </li>
|
5496 | </ul>
|
5497 | </dd>
|
5498 |
|
5499 |
|
5500 |
|
5501 |
|
5502 |
|
5503 |
|
5504 |
|
5505 | <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
|
5506 | <dd class="tag-todo">
|
5507 | <ul>
|
5508 | <li>Accept a "recursive" parameter (boolean) to affect multiple levels (array of arrays of strings, etc.).</li>
|
5509 |
|
5510 | <li>Consider accepting objects instead of arrays in the "element" parameter.</li>
|
5511 | </ul>
|
5512 | </dd>
|
5513 |
|
5514 | </dl>
|
5515 |
|
5516 |
|
5517 |
|
5518 |
|
5519 |
|
5520 |
|
5521 |
|
5522 |
|
5523 |
|
5524 |
|
5525 |
|
5526 |
|
5527 |
|
5528 | <h5>Returns:</h5>
|
5529 |
|
5530 |
|
5531 | <div class="param-desc">
|
5532 | <p>Returns the given element again if it was an string, a number (it will be casted to a string) or an array of strings, trimmed if it has been possible. If it was another type, returns an empty string.</p>
|
5533 | </div>
|
5534 |
|
5535 |
|
5536 |
|
5537 | <dl>
|
5538 | <dt>
|
5539 | Type
|
5540 | </dt>
|
5541 | <dd>
|
5542 |
|
5543 | <span class="param-type">string</span>
|
5544 | |
|
5545 |
|
5546 | <span class="param-type">array</span>
|
5547 |
|
5548 |
|
5549 |
|
5550 | </dd>
|
5551 | </dl>
|
5552 |
|
5553 |
|
5554 |
|
5555 |
|
5556 |
|
5557 | </dd>
|
5558 |
|
5559 |
|
5560 |
|
5561 | <hr>
|
5562 | <dt>
|
5563 | <h4 class="name" id="executeAll"><span class="type-signature"></span>executeAll<span class="signature">()</span><span class="type-signature"></span></h4>
|
5564 |
|
5565 |
|
5566 | </dt>
|
5567 | <dd>
|
5568 |
|
5569 |
|
5570 | <div class="description">
|
5571 | <p>Alias for <code>CB_Arrays#executeFunctionAll</code>.</p>
|
5572 | </div>
|
5573 |
|
5574 |
|
5575 |
|
5576 |
|
5577 |
|
5578 |
|
5579 |
|
5580 |
|
5581 |
|
5582 |
|
5583 | <dl class="details">
|
5584 |
|
5585 |
|
5586 |
|
5587 |
|
5588 |
|
5589 |
|
5590 |
|
5591 |
|
5592 |
|
5593 |
|
5594 |
|
5595 |
|
5596 |
|
5597 |
|
5598 |
|
5599 |
|
5600 |
|
5601 |
|
5602 |
|
5603 |
|
5604 |
|
5605 |
|
5606 |
|
5607 |
|
5608 |
|
5609 |
|
5610 |
|
5611 |
|
5612 |
|
5613 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
5614 | <dd class="tag-source">
|
5615 | <ul class="dummy">
|
5616 | <li>
|
5617 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
5618 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-147">line 147</a>
|
5619 | </li>
|
5620 | </ul>
|
5621 | </dd>
|
5622 |
|
5623 |
|
5624 |
|
5625 |
|
5626 |
|
5627 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
5628 | <dd class="tag-see">
|
5629 | <ul>
|
5630 | <li><code>CB_Arrays#executeFunctionAll</code></li>
|
5631 | </ul>
|
5632 | </dd>
|
5633 |
|
5634 |
|
5635 |
|
5636 | </dl>
|
5637 |
|
5638 |
|
5639 |
|
5640 |
|
5641 |
|
5642 |
|
5643 |
|
5644 |
|
5645 |
|
5646 |
|
5647 |
|
5648 |
|
5649 |
|
5650 |
|
5651 |
|
5652 | </dd>
|
5653 |
|
5654 |
|
5655 |
|
5656 | <hr>
|
5657 | <dt>
|
5658 | <h4 class="name" id="forEachDelay"><span class="type-signature"></span>forEachDelay<span class="signature">()</span><span class="type-signature"></span></h4>
|
5659 |
|
5660 |
|
5661 | </dt>
|
5662 | <dd>
|
5663 |
|
5664 |
|
5665 | <div class="description">
|
5666 | <p>Alias for <code>CB_Arrays#executeFunctionAll</code>.</p>
|
5667 | </div>
|
5668 |
|
5669 |
|
5670 |
|
5671 |
|
5672 |
|
5673 |
|
5674 |
|
5675 |
|
5676 |
|
5677 |
|
5678 | <dl class="details">
|
5679 |
|
5680 |
|
5681 |
|
5682 |
|
5683 |
|
5684 |
|
5685 |
|
5686 |
|
5687 |
|
5688 |
|
5689 |
|
5690 |
|
5691 |
|
5692 |
|
5693 |
|
5694 |
|
5695 |
|
5696 |
|
5697 |
|
5698 |
|
5699 |
|
5700 |
|
5701 |
|
5702 |
|
5703 |
|
5704 |
|
5705 |
|
5706 |
|
5707 |
|
5708 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
5709 | <dd class="tag-source">
|
5710 | <ul class="dummy">
|
5711 | <li>
|
5712 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
5713 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-152">line 152</a>
|
5714 | </li>
|
5715 | </ul>
|
5716 | </dd>
|
5717 |
|
5718 |
|
5719 |
|
5720 |
|
5721 |
|
5722 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
5723 | <dd class="tag-see">
|
5724 | <ul>
|
5725 | <li><code>CB_Arrays#executeFunctionAll</code></li>
|
5726 | </ul>
|
5727 | </dd>
|
5728 |
|
5729 |
|
5730 |
|
5731 | </dl>
|
5732 |
|
5733 |
|
5734 |
|
5735 |
|
5736 |
|
5737 |
|
5738 |
|
5739 |
|
5740 |
|
5741 |
|
5742 |
|
5743 |
|
5744 |
|
5745 |
|
5746 |
|
5747 | </dd>
|
5748 |
|
5749 | </dl>
|
5750 |
|
5751 |
|
5752 |
|
5753 | <h3 class="subsection-title">Type Definitions</h3>
|
5754 |
|
5755 | <dl>
|
5756 |
|
5757 | <hr>
|
5758 | <dt class="name" id=".executeFunctionAll_OBJECT">
|
5759 | <h4 id=".executeFunctionAll_OBJECT">executeFunctionAll_OBJECT</h4>
|
5760 |
|
5761 |
|
5762 | </dt>
|
5763 | <dd>
|
5764 |
|
5765 | <div class="description">
|
5766 | <p>Object used by the <code>CB_Arrays#executeFunctionAll</code> method when the "returnSetTimeoutsArray" parameter is set to true.</p>
|
5767 | </div>
|
5768 |
|
5769 |
|
5770 |
|
5771 | <h5>Type:</h5>
|
5772 | <ul>
|
5773 | <li>
|
5774 |
|
5775 | <span class="param-type">Object</span>
|
5776 |
|
5777 |
|
5778 |
|
5779 | </li>
|
5780 | </ul>
|
5781 |
|
5782 |
|
5783 |
|
5784 | <dl class="details">
|
5785 |
|
5786 |
|
5787 | <h5 class="subsection-title">Properties:</h5>
|
5788 |
|
5789 | <dl>
|
5790 |
|
5791 | <table class="props table table-striped">
|
5792 | <thead>
|
5793 | <tr>
|
5794 |
|
5795 | <th>Name</th>
|
5796 |
|
5797 |
|
5798 | <th>Type</th>
|
5799 |
|
5800 |
|
5801 |
|
5802 |
|
5803 |
|
5804 | <th class="last">Description</th>
|
5805 | </tr>
|
5806 | </thead>
|
5807 |
|
5808 | <tbody>
|
5809 |
|
5810 |
|
5811 | <tr>
|
5812 |
|
5813 | <td class="name"><code>item</code></td>
|
5814 |
|
5815 |
|
5816 | <td class="type">
|
5817 |
|
5818 |
|
5819 | <span class="param-type">*</span>
|
5820 |
|
5821 |
|
5822 |
|
5823 |
|
5824 | </td>
|
5825 |
|
5826 |
|
5827 |
|
5828 |
|
5829 |
|
5830 | <td class="description last"><p>The element affected.</p></td>
|
5831 | </tr>
|
5832 |
|
5833 |
|
5834 |
|
5835 | <tr>
|
5836 |
|
5837 | <td class="name"><code>setTimeoutReturningValue</code></td>
|
5838 |
|
5839 |
|
5840 | <td class="type">
|
5841 |
|
5842 |
|
5843 | <span class="param-type">integer</span>
|
5844 |
|
5845 |
|
5846 |
|
5847 |
|
5848 | </td>
|
5849 |
|
5850 |
|
5851 |
|
5852 |
|
5853 |
|
5854 | <td class="description last"><p>The returning value of calling the <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> internally or null if it was not called, depending on the "delayBetweenEach" parameter.</p></td>
|
5855 | </tr>
|
5856 |
|
5857 |
|
5858 |
|
5859 | <tr>
|
5860 |
|
5861 | <td class="name"><code>setTimeoutDelay</code></td>
|
5862 |
|
5863 |
|
5864 | <td class="type">
|
5865 |
|
5866 |
|
5867 | <span class="param-type">number</span>
|
5868 |
|
5869 |
|
5870 |
|
5871 |
|
5872 | </td>
|
5873 |
|
5874 |
|
5875 |
|
5876 |
|
5877 |
|
5878 | <td class="description last"><p>The value used as the second parameter when calling the <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> internally or zero if it was not called, depending on the "delayBetweenEach" parameter.</p></td>
|
5879 | </tr>
|
5880 |
|
5881 |
|
5882 | </tbody>
|
5883 | </table>
|
5884 | </dl>
|
5885 |
|
5886 |
|
5887 |
|
5888 |
|
5889 |
|
5890 |
|
5891 |
|
5892 |
|
5893 |
|
5894 |
|
5895 |
|
5896 |
|
5897 |
|
5898 |
|
5899 |
|
5900 |
|
5901 |
|
5902 |
|
5903 |
|
5904 |
|
5905 |
|
5906 |
|
5907 |
|
5908 |
|
5909 |
|
5910 |
|
5911 |
|
5912 |
|
5913 |
|
5914 |
|
5915 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
5916 | <dd class="tag-source">
|
5917 | <ul class="dummy">
|
5918 | <li>
|
5919 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
5920 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-138">line 138</a>
|
5921 | </li>
|
5922 | </ul>
|
5923 | </dd>
|
5924 |
|
5925 |
|
5926 |
|
5927 |
|
5928 |
|
5929 |
|
5930 |
|
5931 | </dl>
|
5932 |
|
5933 |
|
5934 |
|
5935 | </dd>
|
5936 |
|
5937 |
|
5938 |
|
5939 | <hr>
|
5940 | <dt>
|
5941 | <h4 class="name" id=".executeFunctionAll_ON_FINISH_CALLBACK"><span class="type-signature"></span>executeFunctionAll_ON_FINISH_CALLBACK<span class="signature">(array, itemsAffected, delayMaximum)</span><span class="type-signature"></span></h4>
|
5942 |
|
5943 |
|
5944 | </dt>
|
5945 | <dd>
|
5946 |
|
5947 |
|
5948 | <div class="description">
|
5949 | <p>Callback that is used when finishes all iterations after looping the array. Being "this" the array itself.</p>
|
5950 | </div>
|
5951 |
|
5952 |
|
5953 |
|
5954 |
|
5955 |
|
5956 |
|
5957 |
|
5958 |
|
5959 | <h5>Parameters:</h5>
|
5960 |
|
5961 |
|
5962 | <table class="params table table-striped">
|
5963 | <thead>
|
5964 | <tr>
|
5965 |
|
5966 | <th style="width:12%; min-width:110px;">Name</th>
|
5967 |
|
5968 |
|
5969 | <th style="width:12%; min-width:110px;">Type</th>
|
5970 |
|
5971 |
|
5972 |
|
5973 |
|
5974 |
|
5975 | <th class="last" style="min-width:310px;">Description</th>
|
5976 | </tr>
|
5977 | </thead>
|
5978 |
|
5979 | <tbody>
|
5980 |
|
5981 |
|
5982 | <tr>
|
5983 |
|
5984 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
5985 |
|
5986 |
|
5987 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
5988 |
|
5989 |
|
5990 | <span class="param-type">array</span>
|
5991 |
|
5992 |
|
5993 |
|
5994 |
|
5995 | </td>
|
5996 |
|
5997 |
|
5998 |
|
5999 |
|
6000 |
|
6001 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Whole array which was being looped.</p></td>
|
6002 | </tr>
|
6003 |
|
6004 |
|
6005 |
|
6006 | <tr>
|
6007 |
|
6008 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>itemsAffected</code></td>
|
6009 |
|
6010 |
|
6011 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6012 |
|
6013 |
|
6014 | <span class="param-type">integer</span>
|
6015 |
|
6016 |
|
6017 |
|
6018 |
|
6019 | </td>
|
6020 |
|
6021 |
|
6022 |
|
6023 |
|
6024 |
|
6025 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The number of times that the "functionEach" callback was called (the most likely, matches the number of elements unless they are undefined or null).</p></td>
|
6026 | </tr>
|
6027 |
|
6028 |
|
6029 |
|
6030 | <tr>
|
6031 |
|
6032 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>delayMaximum</code></td>
|
6033 |
|
6034 |
|
6035 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6036 |
|
6037 |
|
6038 | <span class="param-type">integer</span>
|
6039 |
|
6040 |
|
6041 |
|
6042 |
|
6043 | </td>
|
6044 |
|
6045 |
|
6046 |
|
6047 |
|
6048 |
|
6049 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The maximum "delay" used.</p></td>
|
6050 | </tr>
|
6051 |
|
6052 |
|
6053 | </tbody>
|
6054 | </table>
|
6055 |
|
6056 |
|
6057 |
|
6058 |
|
6059 | <dl class="details">
|
6060 |
|
6061 |
|
6062 |
|
6063 |
|
6064 |
|
6065 |
|
6066 |
|
6067 |
|
6068 |
|
6069 |
|
6070 |
|
6071 |
|
6072 |
|
6073 |
|
6074 |
|
6075 |
|
6076 |
|
6077 |
|
6078 |
|
6079 |
|
6080 |
|
6081 |
|
6082 |
|
6083 |
|
6084 |
|
6085 |
|
6086 |
|
6087 |
|
6088 |
|
6089 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
6090 | <dd class="tag-source">
|
6091 | <ul class="dummy">
|
6092 | <li>
|
6093 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
6094 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-130">line 130</a>
|
6095 | </li>
|
6096 | </ul>
|
6097 | </dd>
|
6098 |
|
6099 |
|
6100 |
|
6101 |
|
6102 |
|
6103 |
|
6104 |
|
6105 | </dl>
|
6106 |
|
6107 |
|
6108 |
|
6109 |
|
6110 |
|
6111 |
|
6112 |
|
6113 |
|
6114 |
|
6115 |
|
6116 |
|
6117 |
|
6118 |
|
6119 |
|
6120 |
|
6121 | </dd>
|
6122 |
|
6123 |
|
6124 |
|
6125 | <hr>
|
6126 | <dt>
|
6127 | <h4 class="name" id=".executeFunctionAll_ON_LOOP_CALLBACK"><span class="type-signature"></span>executeFunctionAll_ON_LOOP_CALLBACK<span class="signature">(item, index, array, delay)</span><span class="type-signature"> → {number}</span></h4>
|
6128 |
|
6129 |
|
6130 | </dt>
|
6131 | <dd>
|
6132 |
|
6133 |
|
6134 | <div class="description">
|
6135 | <p>Callback that is used for each iteration when looping the array. Being "this" the value itself.</p>
|
6136 | </div>
|
6137 |
|
6138 |
|
6139 |
|
6140 |
|
6141 |
|
6142 |
|
6143 |
|
6144 |
|
6145 | <h5>Parameters:</h5>
|
6146 |
|
6147 |
|
6148 | <table class="params table table-striped">
|
6149 | <thead>
|
6150 | <tr>
|
6151 |
|
6152 | <th style="width:12%; min-width:110px;">Name</th>
|
6153 |
|
6154 |
|
6155 | <th style="width:12%; min-width:110px;">Type</th>
|
6156 |
|
6157 |
|
6158 |
|
6159 |
|
6160 |
|
6161 | <th class="last" style="min-width:310px;">Description</th>
|
6162 | </tr>
|
6163 | </thead>
|
6164 |
|
6165 | <tbody>
|
6166 |
|
6167 |
|
6168 | <tr>
|
6169 |
|
6170 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>item</code></td>
|
6171 |
|
6172 |
|
6173 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6174 |
|
6175 |
|
6176 | <span class="param-type">*</span>
|
6177 |
|
6178 |
|
6179 |
|
6180 |
|
6181 | </td>
|
6182 |
|
6183 |
|
6184 |
|
6185 |
|
6186 |
|
6187 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Element (item) which belongs to the index which is being checked in the current iteration of the given array.</p></td>
|
6188 | </tr>
|
6189 |
|
6190 |
|
6191 |
|
6192 | <tr>
|
6193 |
|
6194 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
|
6195 |
|
6196 |
|
6197 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6198 |
|
6199 |
|
6200 | <span class="param-type">integer</span>
|
6201 |
|
6202 |
|
6203 |
|
6204 |
|
6205 | </td>
|
6206 |
|
6207 |
|
6208 |
|
6209 |
|
6210 |
|
6211 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Index which is being checked in the current iteration.</p></td>
|
6212 | </tr>
|
6213 |
|
6214 |
|
6215 |
|
6216 | <tr>
|
6217 |
|
6218 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
6219 |
|
6220 |
|
6221 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6222 |
|
6223 |
|
6224 | <span class="param-type">array</span>
|
6225 |
|
6226 |
|
6227 |
|
6228 |
|
6229 | </td>
|
6230 |
|
6231 |
|
6232 |
|
6233 |
|
6234 |
|
6235 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Whole array which is being looped.</p></td>
|
6236 | </tr>
|
6237 |
|
6238 |
|
6239 |
|
6240 | <tr>
|
6241 |
|
6242 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>delay</code></td>
|
6243 |
|
6244 |
|
6245 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6246 |
|
6247 |
|
6248 | <span class="param-type">integer</span>
|
6249 |
|
6250 |
|
6251 |
|
6252 |
|
6253 | </td>
|
6254 |
|
6255 |
|
6256 |
|
6257 |
|
6258 |
|
6259 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The "delayBetweenEach" used for this loop.</p></td>
|
6260 | </tr>
|
6261 |
|
6262 |
|
6263 | </tbody>
|
6264 | </table>
|
6265 |
|
6266 |
|
6267 |
|
6268 |
|
6269 | <dl class="details">
|
6270 |
|
6271 |
|
6272 |
|
6273 |
|
6274 |
|
6275 |
|
6276 |
|
6277 |
|
6278 |
|
6279 |
|
6280 |
|
6281 |
|
6282 |
|
6283 |
|
6284 |
|
6285 |
|
6286 |
|
6287 |
|
6288 |
|
6289 |
|
6290 |
|
6291 |
|
6292 |
|
6293 |
|
6294 |
|
6295 |
|
6296 |
|
6297 |
|
6298 |
|
6299 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
6300 | <dd class="tag-source">
|
6301 | <ul class="dummy">
|
6302 | <li>
|
6303 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
6304 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-120">line 120</a>
|
6305 | </li>
|
6306 | </ul>
|
6307 | </dd>
|
6308 |
|
6309 |
|
6310 |
|
6311 |
|
6312 |
|
6313 |
|
6314 |
|
6315 | </dl>
|
6316 |
|
6317 |
|
6318 |
|
6319 |
|
6320 |
|
6321 |
|
6322 |
|
6323 |
|
6324 |
|
6325 |
|
6326 |
|
6327 |
|
6328 |
|
6329 | <h5>Returns:</h5>
|
6330 |
|
6331 |
|
6332 | <div class="param-desc">
|
6333 | <p>When used as a function to calculate the delay, it should return the delay desired as a number.</p>
|
6334 | </div>
|
6335 |
|
6336 |
|
6337 |
|
6338 | <dl>
|
6339 | <dt>
|
6340 | Type
|
6341 | </dt>
|
6342 | <dd>
|
6343 |
|
6344 | <span class="param-type">number</span>
|
6345 |
|
6346 |
|
6347 |
|
6348 | </dd>
|
6349 | </dl>
|
6350 |
|
6351 |
|
6352 |
|
6353 |
|
6354 |
|
6355 | </dd>
|
6356 |
|
6357 |
|
6358 |
|
6359 | <hr>
|
6360 | <dt>
|
6361 | <h4 class="name" id=".removeDuplicated_PURGE_FUNCTION"><span class="type-signature"></span>removeDuplicated_PURGE_FUNCTION<span class="signature">(item, index, array)</span><span class="type-signature"> → {boolean}</span></h4>
|
6362 |
|
6363 |
|
6364 | </dt>
|
6365 | <dd>
|
6366 |
|
6367 |
|
6368 | <div class="description">
|
6369 | <p>Callback that is used as the "purgeFunction" parameter of the <a href="CB_Arrays.html#.removeDuplicated"><code>CB_Arrays.removeDuplicated</code></a> function. Being "this" the current element (item). It should return false when we want to keep the value or true otherwise.</p>
|
6370 | </div>
|
6371 |
|
6372 |
|
6373 |
|
6374 |
|
6375 |
|
6376 |
|
6377 |
|
6378 |
|
6379 | <h5>Parameters:</h5>
|
6380 |
|
6381 |
|
6382 | <table class="params table table-striped">
|
6383 | <thead>
|
6384 | <tr>
|
6385 |
|
6386 | <th style="width:12%; min-width:110px;">Name</th>
|
6387 |
|
6388 |
|
6389 | <th style="width:12%; min-width:110px;">Type</th>
|
6390 |
|
6391 |
|
6392 |
|
6393 |
|
6394 |
|
6395 | <th class="last" style="min-width:310px;">Description</th>
|
6396 | </tr>
|
6397 | </thead>
|
6398 |
|
6399 | <tbody>
|
6400 |
|
6401 |
|
6402 | <tr>
|
6403 |
|
6404 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>item</code></td>
|
6405 |
|
6406 |
|
6407 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6408 |
|
6409 |
|
6410 | <span class="param-type">*</span>
|
6411 |
|
6412 |
|
6413 |
|
6414 |
|
6415 | </td>
|
6416 |
|
6417 |
|
6418 |
|
6419 |
|
6420 |
|
6421 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Element (item) which belongs to the index which is being checked in the current iteration used in <a href="CB_Arrays.html#.removeDuplicated"><code>CB_Arrays.removeDuplicated</code></a>.</p></td>
|
6422 | </tr>
|
6423 |
|
6424 |
|
6425 |
|
6426 | <tr>
|
6427 |
|
6428 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
|
6429 |
|
6430 |
|
6431 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6432 |
|
6433 |
|
6434 | <span class="param-type">integer</span>
|
6435 |
|
6436 |
|
6437 |
|
6438 |
|
6439 | </td>
|
6440 |
|
6441 |
|
6442 |
|
6443 |
|
6444 |
|
6445 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Index which is being checked in the current iteration used in <a href="CB_Arrays.html#.removeDuplicated"><code>CB_Arrays.removeDuplicated</code></a>.</p></td>
|
6446 | </tr>
|
6447 |
|
6448 |
|
6449 |
|
6450 | <tr>
|
6451 |
|
6452 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
|
6453 |
|
6454 |
|
6455 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
6456 |
|
6457 |
|
6458 | <span class="param-type">array</span>
|
6459 |
|
6460 |
|
6461 |
|
6462 |
|
6463 | </td>
|
6464 |
|
6465 |
|
6466 |
|
6467 |
|
6468 |
|
6469 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Whole array which is being checked.</p></td>
|
6470 | </tr>
|
6471 |
|
6472 |
|
6473 | </tbody>
|
6474 | </table>
|
6475 |
|
6476 |
|
6477 |
|
6478 |
|
6479 | <dl class="details">
|
6480 |
|
6481 |
|
6482 |
|
6483 |
|
6484 |
|
6485 |
|
6486 |
|
6487 |
|
6488 |
|
6489 |
|
6490 |
|
6491 |
|
6492 |
|
6493 |
|
6494 |
|
6495 |
|
6496 |
|
6497 |
|
6498 |
|
6499 |
|
6500 |
|
6501 |
|
6502 |
|
6503 |
|
6504 |
|
6505 |
|
6506 |
|
6507 |
|
6508 |
|
6509 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
6510 | <dd class="tag-source">
|
6511 | <ul class="dummy">
|
6512 | <li>
|
6513 | <a href="CrossBase_general_CB_Arrays.js.html">CrossBase/general/CB_Arrays.js</a>,
|
6514 | <a href="CrossBase_general_CB_Arrays.js.html#sunlight-1-line-283">line 283</a>
|
6515 | </li>
|
6516 | </ul>
|
6517 | </dd>
|
6518 |
|
6519 |
|
6520 |
|
6521 |
|
6522 |
|
6523 |
|
6524 |
|
6525 | </dl>
|
6526 |
|
6527 |
|
6528 |
|
6529 |
|
6530 |
|
6531 |
|
6532 |
|
6533 |
|
6534 |
|
6535 |
|
6536 |
|
6537 |
|
6538 |
|
6539 | <h5>Returns:</h5>
|
6540 |
|
6541 |
|
6542 | <div class="param-desc">
|
6543 | <p>It should return false when we want to keep the value or true otherwise.</p>
|
6544 | </div>
|
6545 |
|
6546 |
|
6547 |
|
6548 | <dl>
|
6549 | <dt>
|
6550 | Type
|
6551 | </dt>
|
6552 | <dd>
|
6553 |
|
6554 | <span class="param-type">boolean</span>
|
6555 |
|
6556 |
|
6557 |
|
6558 | </dd>
|
6559 | </dl>
|
6560 |
|
6561 |
|
6562 |
|
6563 |
|
6564 |
|
6565 | </dd>
|
6566 |
|
6567 | </dl>
|
6568 |
|
6569 |
|
6570 |
|
6571 | </article>
|
6572 |
|
6573 | </section>
|
6574 |
|
6575 |
|
6576 |
|
6577 |
|
6578 | </div>
|
6579 | </div>
|
6580 |
|
6581 | <div class="clearfix"></div>
|
6582 |
|
6583 |
|
6584 | <div class="col-md-3">
|
6585 | <div id="toc" class="col-md-3 hidden-xs hidden-sm hidden-md"></div>
|
6586 | </div>
|
6587 |
|
6588 |
|
6589 | </div>
|
6590 | </div>
|
6591 |
|
6592 |
|
6593 | <div class="modal fade" id="searchResults">
|
6594 | <div class="modal-dialog">
|
6595 | <div class="modal-content">
|
6596 | <div class="modal-header">
|
6597 | <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
6598 | <h4 class="modal-title">Search results</h4>
|
6599 | </div>
|
6600 | <div class="modal-body"></div>
|
6601 | <div class="modal-footer">
|
6602 | <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
|
6603 | </div>
|
6604 | </div>
|
6605 | </div>
|
6606 | </div>
|
6607 |
|
6608 |
|
6609 | <footer>
|
6610 |
|
6611 |
|
6612 | <span class="copyright">
|
6613 | <a href="printable/" target="_blank">See a more printer-friendly version</a><hr /><span style="color:#000000">© <address style="display:inline; font-style:normal;"><a href="https://crossbrowdy.com/" target="_blank">CrossBrowdy</a> API documentation</address> by <a href="https://joanalbamaldonado.com/" target="_blank">Joan Alba Maldonado</a> - <a href="https://creativecommons.org/licenses/by/4.0/" target="_blank">Creative Commons Attribution 4.0 International</a><br />DocStrap Copyright © 2012-2015 The contributors to the JSDoc3 and DocStrap projects.</span>
|
6614 | </span>
|
6615 |
|
6616 | <span class="jsdoc-message">
|
6617 | Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.5.5</a>
|
6618 |
|
6619 | on Mon Feb 3rd 2020
|
6620 |
|
6621 | using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>.
|
6622 | </span>
|
6623 | </footer>
|
6624 |
|
6625 | <script src="scripts/docstrap.lib.js"></script>
|
6626 | <script src="scripts/toc.js"></script>
|
6627 |
|
6628 | <script type="text/javascript" src="scripts/fulltext-search-ui.js"></script>
|
6629 |
|
6630 |
|
6631 | <script>
|
6632 | $( function () {
|
6633 | $( "[id*='$']" ).each( function () {
|
6634 | var $this = $( this );
|
6635 |
|
6636 | $this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) );
|
6637 | } );
|
6638 |
|
6639 | $( ".tutorial-section pre, .readme-section pre, pre.prettyprint.source" ).each( function () {
|
6640 | var $this = $( this );
|
6641 |
|
6642 | var example = $this.find( "code" );
|
6643 | exampleText = example.html();
|
6644 | var lang = /{@lang (.*?)}/.exec( exampleText );
|
6645 | if ( lang && lang[1] ) {
|
6646 | exampleText = exampleText.replace( lang[0], "" );
|
6647 | example.html( exampleText );
|
6648 | lang = lang[1];
|
6649 | } else {
|
6650 | var langClassMatch = example.parent()[0].className.match(/lang\-(\S+)/);
|
6651 | lang = langClassMatch ? langClassMatch[1] : "javascript";
|
6652 | }
|
6653 |
|
6654 | if ( lang ) {
|
6655 |
|
6656 | $this
|
6657 | .addClass( "sunlight-highlight-" + lang )
|
6658 | .addClass( "linenums" )
|
6659 | .html( example.html() );
|
6660 |
|
6661 | }
|
6662 | } );
|
6663 |
|
6664 | Sunlight.highlightAll( {
|
6665 | lineNumbers : true,
|
6666 | showMenu : true,
|
6667 | enableDoclinks : true
|
6668 | } );
|
6669 |
|
6670 | $.catchAnchorLinks( {
|
6671 | navbarOffset: 10
|
6672 | } );
|
6673 | $( "#toc" ).toc( {
|
6674 | anchorName : function ( i, heading, prefix ) {
|
6675 | return $( heading ).attr( "id" ) || ( prefix + i );
|
6676 | },
|
6677 | selectors : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4",
|
6678 | showAndHide : false,
|
6679 | smoothScrolling: true
|
6680 | } );
|
6681 |
|
6682 | $( "#main span[id^='toc']" ).addClass( "toc-shim" );
|
6683 | $( '.dropdown-toggle' ).dropdown();
|
6684 |
|
6685 | $( "table" ).each( function () {
|
6686 | var $this = $( this );
|
6687 | $this.addClass('table');
|
6688 | } );
|
6689 |
|
6690 | } );
|
6691 | </script>
|
6692 |
|
6693 |
|
6694 |
|
6695 |
|
6696 |
|
6697 | <script>
|
6698 | $( function () {
|
6699 | $( '#main' ).localScroll( {
|
6700 | offset : { top : 60 }
|
6701 | } );
|
6702 | $( "dt.name" ).each( function () {
|
6703 | var $this = $( this ).find("h4");
|
6704 | var icon = $( "<i/>" ).addClass( "icon-plus-sign" ).addClass( "pull-right" ).addClass( "icon-white" );
|
6705 | var dt = $(this);
|
6706 | var children = dt.next( "dd" );
|
6707 |
|
6708 | dt.prepend( icon ).css( {cursor : "pointer"} );
|
6709 | dt.addClass( "member-collapsed" ).addClass( "member" );
|
6710 |
|
6711 |
|
6712 | children.hide();
|
6713 |
|
6714 | dt.children().on( "click", function () {
|
6715 | children = dt.next( "dd" );
|
6716 | children.slideToggle( "fast", function () {
|
6717 |
|
6718 | if ( children.is( ":visible" ) ) {
|
6719 | icon.addClass( "icon-minus-sign" ).removeClass( "icon-plus-sign" ).removeClass( "icon-white" );
|
6720 | dt.addClass( "member-open" ).animate( "member-collapsed" );
|
6721 | } else {
|
6722 | icon.addClass( "icon-plus-sign" ).removeClass( "icon-minus-sign" ).addClass( "icon-white" );
|
6723 | dt.addClass( "member-collapsed" ).removeClass( "member-open" );
|
6724 | }
|
6725 | } );
|
6726 | } );
|
6727 |
|
6728 | } );
|
6729 | } );
|
6730 | </script>
|
6731 |
|
6732 |
|
6733 |
|
6734 |
|
6735 |
|
6736 |
|
6737 | <script type="text/javascript">
|
6738 | $(document).ready(function() {
|
6739 | SearcherDisplay.init();
|
6740 | });
|
6741 | </script>
|
6742 |
|
6743 |
|
6744 | </body>
|
6745 | </html> |
\ | No newline at end of file |