Repository navigation
Summary
Facade cleanup: clearer, consistent names across ActivityFiles, RawEditor,
and RawActivityBuilder. Old names still work (see Deprecated), so the upgrade
is a drop-in unless you implemented one of the two interfaces under Breaking.
Breaking
ActivityFormatParserandActivityFormatEncoderare no longer exported; neither was ever an extension point, since parser and encoder selection switches on theActivityFileFormatenum with no way to register an implementation.- Migration: call
ActivityParser.parse/ActivityEncoder.encodewith the format you want; support for a new format ships in a release.
- Migration: call
Added
ActivityFiles.import()/.importBatch()replaceload/loadBatch.RawEditor.merge()/.splitBySport()andRawActivityBuilder.activityLabelNode()/.deviceNode()/.deviceSummaryNode()replace theirActivityFilesequivalents.RawEditor.autoFix()makes the auto-fix pipeline (sort/dedup, trim invalid points, recompute distance/speed, fill timestamp gaps, auto-lap-by-distance) a public chainable method, not just an option onconvert().ActivityFiles.buildAndExport()builds and exports aRawActivityfrom raw location/channel streams in one call, the streaming counterpart toconvert().- GeoJSON Point export:
EncoderOptions(geojsonGeometry: GeojsonGeometry.points)emits a Point FeatureCollection; addgeojsonIncludeChannels: trueto attach channel values per point. ActivityImportResultreplacesActivityLoadResult, matching theimport()verb that returns it; the old name stays as a deprecated alias.ActivityFiles.convert()acceptsdiagnostics, merging caller-supplied entries into the result the wayexport()already did; this closes the last gap to the deprecatedrunPipeline.
Fixed
- Passing
maxPayloadBytes: nullnow disables the buffer cap for stream sources instead of falling back to the 64MB default.
Deprecated
Everything below still works as before; removal is planned for 0.10.0 with a migration entry then.
ActivityFiles.load/.loadBatch→.import/.importBatch.ActivityFiles.convertStream/.convertAndExportStream→convert, which accepts aStream<List<int>>source and produces identical output; neither path parses incrementally, so the memory profile is unchanged.ActivityLoadResult→ActivityImportResult, via a type alias, so existing declarations and signatures keep compiling.ActivityFiles.merge/.splitBySport→RawEditor.merge/.splitBySport.ActivityFiles.gpxActivityLabelNode/.gpxDeviceNode/.gpxDeviceSummaryNode→RawActivityBuilder.activityLabelNode/.deviceNode/.deviceSummaryNode.ActivityFiles.normalizeActivity/.sortAndDedup/.trimInvalid/.crop/.smoothHeartRate/.recomputeDistanceAndSpeed→ the equivalentActivityFiles.edit(activity)chain.ActivityFiles.exportToCsv/.exportToGeojson/.exportToGeojsonPoints/.importFromCsv/.importFromGeojson→ActivityFiles.export/.importwith an explicit format; theimportFrom*methods are synchronous whileimport()is not, so useActivityParser.parse(input, format)for a sync parse.ActivityFiles.exportToCsvMultiple→ no exact replacement; it concatenates each activity's rows under one header in input order, whileRawEditor.merge()plusexport()sorts by time and drops points whose timestamps collide across activities, so encode each activity separately if you need every row.ActivityFiles.convertAndExport→convertfor source-based calls,buildAndExportfor location/channels-based calls.ActivityFiles.runPipelineandActivityExportRequest→convertfor thefromSource/fromStreamfactories,exportforfromActivity.ActivityConverter→ActivityFiles.convert, orActivityParser.parseplusActivityEncoder.encodefor a synchronous conversion; it had no capability of its own.RawTransforms.computeCumulativeDistance→RawEditor.recomputeDistanceAndSpeed(), reading the total from the lastChannel.distancesample;RawTransforms.resampleis unaffected.ParseFidelityMode→normalize: falseonconvert/export/exportAsync; the enum was never wired into the pipeline and has no effect.FitCorruptionHandlingand thefitCorruptionHandlingparameter →strictFitIntegrity, which has the same effect.IntegrityStats.invalidMessages/.recoveryAttempts/.formatSpecificIssues→ no replacement; no parser ever populated them.