Android Wear API

Sanjay M. Mishra · 2015

This chapter first focuses on Google Play Services, which helps Apps avail of the latest Google-powered features. The Wear API contains at a high level a Node API, Data API, and Message API. The Android Wear API's main package, wearable (com.google.android.gms.wearable), contains about seven interfaces and 10 classes. DataItem, DataItemMap, and DataMap are closely related, and furthermore, they are all related to the PutDataRequest and PutDataMapRequest. Both the PutDataRequest and PutDataMapRequest are used for creating new DataItems and adding them to the Android Wear Network by calling the Data API. Both the Asset and DataItemAsset are similar in that they represent the binary, blob kind of data. The Asset class represents data that may not yet have been added to the Android Wear Network. The MessageApi supports sending and receiving short, transient messages privately between instances of the same App that reside on different nodes in the Android Wear Network.

Read the paper · More papers on PaperTik