checkindelta

package
v0.0.0-...-d2356ba Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 19, 2017 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package checkindelta contains functions to calculate deltas between snapshots of aggregated checkin battery stats from a device.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComputeDelta

func ComputeDelta(first, second *bspb.BatteryStats) *bspb.BatteryStats

ComputeDelta takes two protos and outputs a third one that contains the difference between the two. Second will be subtracted from first.

func ComputeDeltaFromSameDevice

func ComputeDeltaFromSameDevice(first, second *bspb.BatteryStats) *bspb.BatteryStats

ComputeDeltaFromSameDevice takes two Batterystats protos taken from the same device and outputs a third one that contains the difference between the two, including fields that can only be subtracted in special cases (same device and same start clock time). Second will be subtracted from first.

func NormalizeStats

func NormalizeStats(p *bspb.BatteryStats) (*bspb.BatteryStats, error)

NormalizeStats takes in a proto and normalizes it by converting any absolute value to value/TotalTime.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL