A message that can hold any of the supported value types.
This class is in the Values
namespace.
class Value
The default constructor.
Value()
Params:
name
- The resource name of the document.
The constructor with the object value.
See the below supported objects classes.
Value(T value)
Params:
value
- The object value.
A null value.
This class is in the Values
namespace.
class NullValue
The default constructor.
NullValue()
A string value.
This class is in the Values
namespace.
class StringValue
The constructor with string value.
StringValue(const String &value)
Params:
value
- The string value.
A boolean value.
This class is in the Values
namespace.
class BooleanValue
The constructor with boolean value.
BooleanValue(bool value)
Params:
value
- The boolean value.
A 64-bit signed integer value.
This class is in the Values
namespace.
class IntegerValue
The constructor with a 64-bit signed integer value.
IntegerValue(int64_t value)
Params:
value
- The 64-bit signed integer value.
A double value.
This class is in the Values
namespace.
class DoubleValue
The constructor with double value.
This constructor is obsoleted.
DoubleValue(double value)
Params:
value
- The double value.
The constructor with number_t
represents the double value.
DoubleValue(const number_t &value)
Params:
value
- Thenumber_t
represents the double value.
A timestampValue value.
This class is in the Values
namespace.
class TimestampValue
The constructor with timestamp value string.
Precise only to microseconds. When stored, any additional precision is rounded down.
TimestampValue(const String &value)
Params:
value
- The timestamp value string.
A bytes value.
This class is in the Values
namespace.
class BytesValue
The constructor with timestamp (base64-encoded) value string.
Must not exceed 1 MiB - 89 bytes. Only the first 1,500 bytes are considered by queries.
BytesValue(const String &value)
Params:
value
- The bytes (base64-encoded) value string.
A reference to a document.
This class is in the Values
namespace.
class ReferenceValue
The constructor with resource name string.
ReferenceValue(const String &value)
Params:
value
- The resource name of document.
A geo point representing a point on the surface of Earth.
This class is in the Values
namespace.
class GeoPointValue
The constructor with latitude and longitude.
This constructor is obsoleted.
GeoPointValue(double lat, double lng)
Params:
-
lat
- The latitude. -
lng
- The longitude.
The constructor with latitude and longitude.
This constructor is obsoleted.
GeoPointValue(const number_t &lat, const number_t &lng)
Params:
-
lat
- Thenumber_t
represents the latitude value. -
lng
- Thenumber_t
represents the latitude value.
An array value.
This class is in the Values
namespace.
class ArrayValue
The constructor with object.
Cannot directly contain another array value, though can contain an map which contains another array.
ArrayValue(T value)
Params:
value
- The object except for array value.
A map value.
This class is in the Values
namespace.
class MapValue
The constructor with key and object value.
MapValue(const String &key, T value)
Params:
-
key
- The key. -
value
- The object value.
Add key and value pair to a map.
MapValue &add(const String &key, T value)
Params:
-
key
- The key. -
value
- The object value.