OnDataPointListener | Android Developers

Quicknav Quicknav
Links

- Google Play Developer Console
- Android Developers Blog
- About Android

Android Sites

- Android.com
- Android Developers
- Android Open Source Project

Language
close

- - About
  - Wear
  - TV
  - Auto
- - Get Started
  - Devices
  - Style
  - Patterns
  - Building Blocks
  - Downloads
  - Videos
- - Training
  - API Guides
  - Reference
  - Tools
  - Google Services
  - Samples
- - Google Play
  - Essentials
  - Get Users
  - Engage & Retain
  - Monetize
  - Analyze
  - Tools & Reference
  - Developer Stories

## Results

Loading...
public interface

# OnDataPointListener

com.google.android.gms.fitness.request.OnDataPointListener

## Class Overview

Listener used to register to live data updates from a `DataSource`. Used by clients wanting to subscribe to live data stream updates via `SensorsApi`. Each event is delivered as a `DataPoint`.

The listener is used both when adding a registration and when removing it. The same listener can be used for multiple registrations.

## Summary

Public Methods
abstract void | onDataPoint(DataPoint dataPoint) Handle a new data point from the data source.

## Public Methods

#### public abstract void onDataPoint (DataPoint dataPoint)

Handle a new data point from the data source. The data point's data type describes the format and meaning of its values.

Note: The application doesn't own the data point object passed as a parameter after this method returns and therefore should not hold on to it, since the DataPoint can be reused by the platform.

##### Parameters

dataPoint | the data point for this event