fitness  v1
Public Member Functions | Static Public Member Functions | List of all members
google_fitness_api::Device Class Reference

#include <device.h>

Inheritance diagram for google_fitness_api::Device:

Public Member Functions

 Device (const Json::Value &storage)
 
 Device (Json::Value *storage)
 
virtual ~Device ()
 
const StringPiece GetTypeName () const
 
bool has_manufacturer () const
 
void clear_manufacturer ()
 
const StringPiece get_manufacturer () const
 
void set_manufacturer (const StringPiece &value)
 
bool has_model () const
 
void clear_model ()
 
const StringPiece get_model () const
 
void set_model (const StringPiece &value)
 
bool has_type () const
 
void clear_type ()
 
const StringPiece get_type () const
 
void set_type (const StringPiece &value)
 
bool has_uid () const
 
void clear_uid ()
 
const StringPiece get_uid () const
 
void set_uid (const StringPiece &value)
 
bool has_version () const
 
void clear_version ()
 
const StringPiece get_version () const
 
void set_version (const StringPiece &value)
 

Static Public Member Functions

static DeviceNew ()
 

Detailed Description

Representation of an integrated device (such as a phone or a wearable) that can hold sensors. Each sensor is exposed as a data source.

The main purpose of the device information contained in this class is to identify the hardware of a particular data source. This can be useful in different ways, including:

Constructor & Destructor Documentation

◆ Device() [1/2]

google_fitness_api::Device::Device ( const Json::Value &  storage)
explicit

Standard constructor for an immutable data object instance.

Parameters
[in]storageThe underlying data storage for this instance.

◆ Device() [2/2]

google_fitness_api::Device::Device ( Json::Value *  storage)
explicit

Standard constructor for a mutable data object instance.

Parameters
[in]storageThe underlying data storage for this instance.

◆ ~Device()

google_fitness_api::Device::~Device ( )
virtual

Standard destructor.

Member Function Documentation

◆ clear_manufacturer()

void google_fitness_api::Device::clear_manufacturer ( )
inline

Clears the 'manufacturer' attribute.

◆ clear_model()

void google_fitness_api::Device::clear_model ( )
inline

Clears the 'model' attribute.

◆ clear_type()

void google_fitness_api::Device::clear_type ( )
inline

Clears the 'type' attribute.

◆ clear_uid()

void google_fitness_api::Device::clear_uid ( )
inline

Clears the 'uid' attribute.

◆ clear_version()

void google_fitness_api::Device::clear_version ( )
inline

Clears the 'version' attribute.

◆ get_manufacturer()

const StringPiece google_fitness_api::Device::get_manufacturer ( ) const
inline

Get the value of the 'manufacturer' attribute.

◆ get_model()

const StringPiece google_fitness_api::Device::get_model ( ) const
inline

Get the value of the 'model' attribute.

◆ get_type()

const StringPiece google_fitness_api::Device::get_type ( ) const
inline

Get the value of the 'type' attribute.

◆ get_uid()

const StringPiece google_fitness_api::Device::get_uid ( ) const
inline

Get the value of the 'uid' attribute.

◆ get_version()

const StringPiece google_fitness_api::Device::get_version ( ) const
inline

Get the value of the 'version' attribute.

◆ GetTypeName()

const StringPiece google_fitness_api::Device::GetTypeName ( ) const
inline

Returns a string denoting the type of this data object.

Returns
google_fitness_api::Device

◆ has_manufacturer()

bool google_fitness_api::Device::has_manufacturer ( ) const
inline

Determine if the 'manufacturer' attribute was set.

Returns
true if the 'manufacturer' attribute was set.

◆ has_model()

bool google_fitness_api::Device::has_model ( ) const
inline

Determine if the 'model' attribute was set.

Returns
true if the 'model' attribute was set.

◆ has_type()

bool google_fitness_api::Device::has_type ( ) const
inline

Determine if the 'type' attribute was set.

Returns
true if the 'type' attribute was set.

◆ has_uid()

bool google_fitness_api::Device::has_uid ( ) const
inline

Determine if the 'uid' attribute was set.

Returns
true if the 'uid' attribute was set.

◆ has_version()

bool google_fitness_api::Device::has_version ( ) const
inline

Determine if the 'version' attribute was set.

Returns
true if the 'version' attribute was set.

◆ New()

Device * google_fitness_api::Device::New ( )
static

Creates a new default instance.

Returns
Ownership is passed back to the caller.

◆ set_manufacturer()

void google_fitness_api::Device::set_manufacturer ( const StringPiece &  value)
inline

Change the 'manufacturer' attribute.

Manufacturer of the product/hardware.

Parameters
[in]valueThe new value.

◆ set_model()

void google_fitness_api::Device::set_model ( const StringPiece &  value)
inline

Change the 'model' attribute.

End-user visible model name for the device.

Parameters
[in]valueThe new value.

◆ set_type()

void google_fitness_api::Device::set_type ( const StringPiece &  value)
inline

Change the 'type' attribute.

A constant representing the type of the device.

Parameters
[in]valueThe new value.

◆ set_uid()

void google_fitness_api::Device::set_uid ( const StringPiece &  value)
inline

Change the 'uid' attribute.

The serial number or other unique ID for the hardware. This field is obfuscated when read by any REST or Android client that did not create the data source. Only the data source creator will see the uid field in clear and normal form.

The obfuscation preserves equality; that is, given two IDs, if id1 == id2, obfuscated(id1) == obfuscated(id2).

Parameters
[in]valueThe new value.

◆ set_version()

void google_fitness_api::Device::set_version ( const StringPiece &  value)
inline

Change the 'version' attribute.

Version string for the device hardware/software.

Parameters
[in]valueThe new value.

The documentation for this class was generated from the following files: