Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

quantified-self-lib

Package Overview
Dependencies
Maintainers
1
Versions
134
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

quantified-self-lib - npm Package Compare versions

Comparing version 1.0.0-pre-15 to 1.0.0-pre-16

lib/data/data.fused-altitude.d.ts

2

lib/activities/activity.types.d.ts

@@ -100,3 +100,3 @@ /**

'Fishing' = "Fishing",
'Hunting' = "Hunting",
'Hunting' = "Hunting"
}

@@ -14,3 +14,3 @@ import { SerializableClassInterface } from '../serializable/serializable.class.interface';

Metric = 0,
Imperial = 1,
Imperial = 1
}

@@ -58,2 +58,3 @@ "use strict";

var data_pace_1 = require("./data.pace");
var data_fused_altitude_1 = require("./data.fused-altitude");
/**

@@ -114,2 +115,3 @@ * Only concrete classes no abstracts

DataFusedLocation: data_fused_location_1.DataFusedLocation,
DataFusedAltitude: data_fused_altitude_1.DataFusedAltitude,
DataPace: data_pace_1.DataPace,

@@ -116,0 +118,0 @@ DataPaceMin: data_pace_min_1.DataPaceMin,

import { EventInterface } from '../../../event.interface';
export declare class EventImporterFIT {
static getFromArrayBuffer(arrayBuffer: ArrayBuffer, name?: string): Promise<EventInterface>;
private static getPointFromSessionLapObjectRecord(sessionLapObjectRecord);
private static getLapFromSessionLapObject(sessionLapObject);
private static getActivityFromSessionObject(sessionObject, fitDataObject);
private static getActivityTypeFromSessionObject(session);
private static getStatsFromObject(object);
private static getCreatorFromFitDataObject(fitDataObject);
private static getPointFromSessionLapObjectRecord;
private static getLapFromSessionLapObject;
private static getActivityFromSessionObject;
private static getActivityTypeFromSessionObject;
private static getStatsFromObject;
private static getCreatorFromFitDataObject;
}
import { EventInterface } from '../../../event.interface';
export declare class EventImporterGPX {
static getFromString(gpx: string, name?: string): EventInterface;
private static getPointsFromGPX(parsedGPX);
private static addExtensionDataToPoint(point, extensionData);
private static getLaps(parsedGPX);
private static getPointsFromGPX;
private static addExtensionDataToPoint;
private static getLaps;
}
import { EventInterface } from '../../../event.interface';
export declare class EventImporterJSON {
static getFromJSONString(jsonString: string): EventInterface;
private static getGeoLocationInfo(object);
private static getWeather(object);
private static getGeoLocationInfo;
private static getWeather;
}

@@ -83,3 +83,3 @@ export declare enum ImporterSuuntoActivityIds {

'Fishing' = 97,
'Hunting' = 98,
'Hunting' = 98
}
import { EventInterface } from '../../../event.interface';
export declare class EventImporterSuuntoJSON {
static getFromJSONString(jsonString: string): EventInterface;
private static hasFusedLocData(sample);
private static setIntensityZones(activity, object);
private static setIBIData(activity, ibiData);
private static getPointFromSample(sample);
private static getZones(zonesObj);
private static getStats(object);
private static hasFusedLocData;
private static setIntensityZones;
private static setIBIData;
private static getPointFromSample;
private static getZones;
private static getStats;
}

@@ -70,2 +70,3 @@ "use strict";

var data_pace_min_1 = require("../../../../data/data.pace-min");
var data_fused_altitude_1 = require("../../../../data/data.fused-altitude");
var EventImporterSuuntoJSON = /** @class */ (function () {

@@ -93,2 +94,6 @@ function EventImporterSuuntoJSON() {

});
// Check if there is a Fused Altitude event
var fusedAltitudeEventSamples = eventJSONObject.DeviceLog.Samples.filter(function (sample) {
return sample.Events && sample.Events[0].Altitude;
});
// Get the lap start events

@@ -126,2 +131,9 @@ var lapEventSamples = eventJSONObject.DeviceLog.Samples.filter(function (sample) {

_this.setIntensityZones(activity, eventJSONObject.DeviceLog.Header);
// Add the fused altitude event
if (fusedAltitudeEventSamples.length) {
activity.addStat(new data_fused_altitude_1.DataFusedAltitude(true));
}
else {
activity.addStat(new data_fused_altitude_1.DataFusedAltitude(false));
}
return activity;

@@ -128,0 +140,0 @@ });

import { EventInterface } from '../../../event.interface';
export declare class EventImporterTCX {
static getFromXML(xml: Document, name?: string): EventInterface;
private static getPoints(trackPointsElements);
private static getCreator(creatorElement?);
private static getLaps(lapElements);
private static getPoints;
private static getCreator;
private static getLaps;
}

@@ -12,5 +12,5 @@ import { EventInterface } from '../event.interface';

static getEventDataTypeLoss(event: EventInterface, dataType: string, starDate?: Date, endDate?: Date, activities?: ActivityInterface[], minDiff?: number): number;
private static getEventDataTypeGainOrLoss(gain, event, dataType, starDate?, endDate?, activities?, minDiff?);
private static getDataTypeMinOrMax(max, event, dataType, startDate?, endDate?, activities?);
private static generateStatsForActivityOrLap(event, subject);
private static getEventDataTypeGainOrLoss;
private static getDataTypeMinOrMax;
private static generateStatsForActivityOrLap;
static getDistanceInMeters(event: EventInterface, startDate?: Date, endDate?: Date, activities?: ActivityInterface[]): number;

@@ -17,0 +17,0 @@ }

@@ -88,2 +88,3 @@ "use strict";

mergeEvent.getPause().setValue(mergeEvent.getPause().getValue() + activity.getPause().getValue());
// @todo merge the rest of the stats
}

@@ -90,0 +91,0 @@ }

@@ -24,3 +24,3 @@ /**

'session_end' = "Session end",
'fitness_equipment' = "Fitness equipment",
'fitness_equipment' = "Fitness equipment"
}
{
"name": "quantified-self-lib",
"version": "1.0.0-pre-15",
"version": "1.0.0-pre-16",
"description": "A Library to for processing GPX, TCX, FIT and JSON files from services such as Strava, Movescount, Garmin, Polar etc",

@@ -50,6 +50,6 @@ "keywords": [

"@types/jest": "^22.2.3",
"jest": "^23.0.0",
"jest": "^23.1.0",
"ts-jest": "^22.4.6",
"tslint": "^5.10.0",
"typescript": "^2.8.3"
"typescript": "^2.9.1"
},

@@ -56,0 +56,0 @@ "jest": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc