-
<inner> appendPage(operation, page)
-
Appends a page's data to the operation data.
Parameters:
Name |
Type |
Description |
operation |
Object
|
Operation with (i)ndex, (c)ount and (d)ata. |
page |
Object
|
Page with (i)ndex, (c)ount and (d)ata. |
- Source:
-
<inner> checkUndefinedGreaterThanZero(val, name)
-
Checks whether val is undefined or a number with value greater than zero.
Parameters:
Name |
Type |
Description |
val |
Number
|
Value to check. |
name |
String
|
Parameter name to use in exception. |
- Source:
Throws:
Throws an exception if the check fails
-
<inner> checkUndefinedOrNumber(val, name)
-
Checks whether val is undefined or a number
Parameters:
Name |
Type |
Description |
val |
Number
|
Value to check. |
name |
String
|
Parameter name to use in exception. |
- Source:
Throws:
Throws an exception if the check fails
-
<inner> checkZeroGreater(val, name)
-
Checks whether val is a defined number with value zero or greater.
Parameters:
Name |
Type |
Description |
val |
Number
|
Value to check. |
name |
String
|
Parameter name to use in exception. |
- Source:
Throws:
Throws an exception if the check fails
-
<inner> createDataCache(options) → {DataCache}
-
Creates a data cache for a collection that is efficiently loaded on-demand.
Parameters:
Name |
Type |
Description |
options |
|
Options for the data cache, including name, source, pageSize, TODO check doku
prefetchSize, cacheSize, storage mechanism, and initial prefetch and local-data handler. |
- Source:
Returns:
A new data cache instance.
-
Type
-
DataCache
-
<inner> estimateSize(object) → {Number}
-
Estimates the size of an object in bytes.
Object trees are traversed recursively
Parameters:
Name |
Type |
Description |
object |
Object
|
Object to determine the size of. |
- Source:
Returns:
Estimated size of the object in bytes.
-
Type
-
Number
-
<inner> intersectRanges(x, y) → {Object}
-
Returns the {(i)ndex, (c)ount} range for the intersection of x and y.
Parameters:
Name |
Type |
Description |
x |
Object
|
Range with (i)ndex and (c)ount members. |
y |
Object
|
Range with (i)ndex and (c)ount members. |
- Source:
Returns:
The intersection (i)ndex and (c)ount; undefined if there is no intersection.
-
Type
-
Object
-
<inner> removeFromArray(arr, item) → {Boolean}
-
Performs a linear search on the specified array and removes the first instance of 'item'.
Parameters:
Name |
Type |
Description |
arr |
Array
|
Array to search. |
item |
*
|
Item being sought. |
- Source:
Returns:
true if the item was removed otherwise false
-
Type
-
Boolean
-
<inner> snapToPageBoundaries(lowIndex, highIndex, pageSize) → {Object}
-
Snaps low and high indices into page sizes and returns a range.
Parameters:
Name |
Type |
Description |
lowIndex |
Number
|
Low index to snap to a lower value. |
highIndex |
Number
|
High index to snap to a higher value. |
pageSize |
Number
|
Page size to snap to. |
- Source:
Returns:
A range with (i)ndex and (c)ount of elements.
-
Type
-
Object