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

#include <value.h>

Inheritance diagram for google_fitness_api::Value:

Public Member Functions

 Value (const Json::Value &storage)
 
 Value (Json::Value *storage)
 
virtual ~Value ()
 
const StringPiece GetTypeName () const
 
bool has_fp_val () const
 
void clear_fp_val ()
 
double get_fp_val () const
 
void set_fp_val (double value)
 
bool has_int_val () const
 
void clear_int_val ()
 
int32 get_int_val () const
 
void set_int_val (int32 value)
 
bool has_map_val () const
 
void clear_map_val ()
 
const client::JsonCppArray< ValueMapValEntryget_map_val () const
 
client::JsonCppArray< ValueMapValEntrymutable_mapVal ()
 
bool has_string_val () const
 
void clear_string_val ()
 
const StringPiece get_string_val () const
 
void set_string_val (const StringPiece &value)
 

Static Public Member Functions

static ValueNew ()
 

Detailed Description

Holder object for the value of a single field in a data point.

A field value has a particular format and is only ever set to one of an integer or a floating point value.

Constructor & Destructor Documentation

◆ Value() [1/2]

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

Standard constructor for an immutable data object instance.

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

◆ Value() [2/2]

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

Standard constructor for a mutable data object instance.

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

◆ ~Value()

google_fitness_api::Value::~Value ( )
virtual

Standard destructor.

Member Function Documentation

◆ clear_fp_val()

void google_fitness_api::Value::clear_fp_val ( )
inline

Clears the 'fpVal' attribute.

◆ clear_int_val()

void google_fitness_api::Value::clear_int_val ( )
inline

Clears the 'intVal' attribute.

◆ clear_map_val()

void google_fitness_api::Value::clear_map_val ( )
inline

Clears the 'mapVal' attribute.

◆ clear_string_val()

void google_fitness_api::Value::clear_string_val ( )
inline

Clears the 'stringVal' attribute.

◆ get_fp_val()

double google_fitness_api::Value::get_fp_val ( ) const
inline

Get the value of the 'fpVal' attribute.

◆ get_int_val()

int32 google_fitness_api::Value::get_int_val ( ) const
inline

Get the value of the 'intVal' attribute.

◆ get_map_val()

const client::JsonCppArray<ValueMapValEntry > google_fitness_api::Value::get_map_val ( ) const

Get a reference to the value of the 'mapVal' attribute.

◆ get_string_val()

const StringPiece google_fitness_api::Value::get_string_val ( ) const
inline

Get the value of the 'stringVal' attribute.

◆ GetTypeName()

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

Returns a string denoting the type of this data object.

Returns
google_fitness_api::Value

◆ has_fp_val()

bool google_fitness_api::Value::has_fp_val ( ) const
inline

Determine if the 'fpVal' attribute was set.

Returns
true if the 'fpVal' attribute was set.

◆ has_int_val()

bool google_fitness_api::Value::has_int_val ( ) const
inline

Determine if the 'intVal' attribute was set.

Returns
true if the 'intVal' attribute was set.

◆ has_map_val()

bool google_fitness_api::Value::has_map_val ( ) const
inline

Determine if the 'mapVal' attribute was set.

Returns
true if the 'mapVal' attribute was set.

◆ has_string_val()

bool google_fitness_api::Value::has_string_val ( ) const
inline

Determine if the 'stringVal' attribute was set.

Returns
true if the 'stringVal' attribute was set.

◆ mutable_mapVal()

client::JsonCppArray<ValueMapValEntry > google_fitness_api::Value::mutable_mapVal ( )

Gets a reference to a mutable value of the 'mapVal' property.

Map value. The valid key space and units for the corresponding value of each entry should be documented as part of the data type definition. Keys should be kept small whenever possible. Data streams with large keys and high data frequency may be down sampled.

Returns
The result can be modified to change the attribute value.

◆ New()

Value * google_fitness_api::Value::New ( )
static

Creates a new default instance.

Returns
Ownership is passed back to the caller.

◆ set_fp_val()

void google_fitness_api::Value::set_fp_val ( double  value)
inline

Change the 'fpVal' attribute.

Floating point value. When this is set, other values must not be set.

Parameters
[in]valueThe new value.

◆ set_int_val()

void google_fitness_api::Value::set_int_val ( int32  value)
inline

Change the 'intVal' attribute.

Integer value. When this is set, other values must not be set.

Parameters
[in]valueThe new value.

◆ set_string_val()

void google_fitness_api::Value::set_string_val ( const StringPiece &  value)
inline

Change the 'stringVal' attribute.

String value. When this is set, other values must not be set. Strings should be kept small whenever possible. Data streams with large string values and high data frequency may be down sampled.

Parameters
[in]valueThe new value.

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