@sports-alliance/sports-lib
Version:
A Library to for importing / exporting and processing GPX, TCX, FIT and JSON files from services such as Strava, Movescount, Garmin, Polar etc
21 lines (20 loc) • 763 B
TypeScript
import { DataInterface, DefaultDataClassValue, UnitSystem } from './data.interface';
import { DataJSONInterface } from './data.json.interface';
export declare abstract class Data<T = DefaultDataClassValue> implements DataInterface<T> {
static type: string;
static unit: string;
static displayType?: string;
static unitSystem: UnitSystem;
protected value: T;
protected constructor(value: T);
setValue(value: T): this;
getValue(_formatForDataType?: string): T;
getDisplayValue(): number | string | string[];
getType(): string;
getUnit(): string;
getDisplayUnit(): string;
getDisplayType(): string;
getUnitSystem(): UnitSystem;
isValueTypeValid(value: unknown): boolean;
toJSON(): DataJSONInterface;
}