aboutsummaryrefslogtreecommitdiff
path: root/ride/ride.go
diff options
context:
space:
mode:
Diffstat (limited to 'ride/ride.go')
-rw-r--r--ride/ride.go27
1 files changed, 0 insertions, 27 deletions
diff --git a/ride/ride.go b/ride/ride.go
index a694df9..1de8b07 100644
--- a/ride/ride.go
+++ b/ride/ride.go
@@ -59,26 +59,6 @@ func (r Ride) Cadences() ([]float64, bool) { return optionalComponent(r.cadences
func (r Ride) HeartRates() ([]float64, bool) { return optionalComponent(r.heartRates) }
-func (r Ride) DistanceM(i int) float64 { return r.distances[i] }
-
-func (r Ride) ElevationM(i int) float64 { return r.elevations[i] }
-
-func (r Ride) Coord(i int) geodist.Coord { return r.coords[i] }
-
-func (r Ride) Timestamp(i int) time.Time { return r.timestamps[i] }
-
-func (r Ride) HeartRateBpm(i int) (float64, bool) {
- return optionalMetric(r.heartRates, i)
-}
-
-func (r Ride) CadenceRpm(i int) (float64, bool) {
- return optionalMetric(r.cadences, i)
-}
-
-func (r Ride) PowerW(i int) (float64, bool) {
- return optionalMetric(r.powers, i)
-}
-
func optionalComponent(column []float64) ([]float64, bool) {
if len(column) == 0 {
return nil, false
@@ -86,13 +66,6 @@ func optionalComponent(column []float64) ([]float64, bool) {
return column, true
}
-func optionalMetric(column []float64, i int) (float64, bool) {
- if len(column) == 0 {
- return 0, false
- }
- return column[i], true
-}
-
type RideParser interface {
Parse(reader io.Reader) (Ride, error)
}