MCPcopy
hub / github.com/apache/echarts / appendValues

Method appendValues

src/data/SeriesData.ts:587–602  ·  view source on GitHub ↗

* Caution: Can be only called on raw data (before `this._indices` created). * This method does not modify `rawData` (`dataProvider`), but only * add values to store. * * The final count will be increased by `Math.max(values.length, names.length)`. * * @param values That

(values: any[][], names?: string[])

Source from the content-addressed store, hash-verified

585 * Each item is exactly corresponding to a dimension.
586 */
587 appendValues(values: any[][], names?: string[]): void {
588 const {start, end} = this._store.appendValues(values, names && names.length);
589 const shouldMakeIdFromName = this._shouldMakeIdFromName();
590
591 this._updateOrdinalMeta();
592
593 if (names) {
594 for (let idx = start; idx < end; idx++) {
595 const sourceIdx = idx - start;
596 this._nameList[idx] = names[sourceIdx];
597 if (shouldMakeIdFromName) {
598 makeIdFromName(this, idx);
599 }
600 }
601 }
602 }
603
604 private _updateOrdinalMeta(): void {
605 const store = this._store;

Callers 1

testArrayRowsInSourceFunction · 0.95

Calls 2

_shouldMakeIdFromNameMethod · 0.95
_updateOrdinalMetaMethod · 0.95

Tested by 1

testArrayRowsInSourceFunction · 0.76