Menu
Important: This documentation is about an older version. It's relevant only to the release noted, many of the features and functions have been updated or replaced. Please view the current version.
Enterprise
Open source
AppendedVectors class
This may be more trouble than it is worth. This trades some computation time for RAM – rather than allocate a new array the size of all previous arrays, this just points the correct index to their original array values
Signature
typescript
export declare class AppendedVectors<T = any> implements Vector<T>
Import
typescript
import { AppendedVectors } from '@grafana/data';
Constructors
Constructor | Modifiers | Description |
---|---|---|
constructor(startAt) | Constructs a new instance of the AppendedVectors class |
Properties
Property | Modifiers | Type | Description |
---|---|---|---|
length | number | ||
source | Array<AppendedVectorInfo<T>> |
Methods
Method | Modifiers | Description |
---|---|---|
append(v) | ||
get(index) | ||
setLength(length) | Make the vector look like it is this long | |
toArray() | ||
toJSON() |
constructor(startAt)
Constructs a new instance of the AppendedVectors
class
Signature
typescript
constructor(startAt?: number);
Parameters
Parameter | Type | Description |
---|---|---|
startAt | number |
length property
Signature
typescript
length: number;
source property
Signature
typescript
source: Array<AppendedVectorInfo<T>>;
append method
Signature
typescript
append(v: Vector<T>): AppendedVectorInfo<T>;
Parameters
Parameter | Type | Description |
---|---|---|
v | Vector<T> |
Returns:
AppendedVectorInfo<T>
get method
Signature
typescript
get(index: number): T;
Parameters
Parameter | Type | Description |
---|---|---|
index | number |
Returns:
T
setLength method
Make the vector look like it is this long
Signature
typescript
setLength(length: number): void;
Parameters
Parameter | Type | Description |
---|---|---|
length | number |
Returns:
void
toArray method
Signature
typescript
toArray(): T[];
Returns:
T[]
toJSON method
Signature
typescript
toJSON(): T[];
Returns:
T[]
Was this page helpful?
Related resources from Grafana Labs
Additional helpful documentation, links, and articles:

Getting started with the Grafana LGTM Stack
In this webinar, we’ll demo how to get started using the LGTM Stack: Loki for logs, Grafana for visualization, Tempo for traces, and Mimir for metrics.

Getting started with Grafana dashboard design (EMEA Timezone)
In this webinar, you'll learn how to design stylish and easily accessible Grafana dashboards that tell a story.

Unify your data with Grafana plugins: Datadog, Splunk, MongoDB, and more
In this webinar, learn how to leverage Grafana's plugin ecosystem for access to 80+ data sources, including plugins for Datadog, Splunk, MongoDB, and more.