* Returns all timestamps * @return {number[]} * @private
()
| 135 | * @private |
| 136 | */ |
| 137 | _getTimestampsForTable() { |
| 138 | let timestamps = this._cache.all || []; |
| 139 | |
| 140 | if (timestamps.length) { |
| 141 | return timestamps; |
| 142 | } |
| 143 | |
| 144 | const data = this.getDataTimestamps(); |
| 145 | const label = this.getLabelTimestamps(); |
| 146 | if (data.length && label.length) { |
| 147 | // If combining labels and data (data might not contain all labels), |
| 148 | // we need to recheck uniqueness and sort |
| 149 | timestamps = this.normalize(data.concat(label)); |
| 150 | } else { |
| 151 | timestamps = data.length ? data : label; |
| 152 | } |
| 153 | timestamps = this._cache.all = timestamps; |
| 154 | |
| 155 | return timestamps; |
| 156 | } |
| 157 | |
| 158 | /** |
| 159 | * @param {number} value - Milliseconds since epoch (1 January 1970 00:00:00 UTC) |
no test coverage detected