Home
last modified time | relevance | path

Searched refs:ToValue (Results 1 – 7 of 7) sorted by relevance

/external/libbrillo/brillo/
Dvalue_conversion.h106 BRILLO_EXPORT std::unique_ptr<base::Value> ToValue(int value);
107 BRILLO_EXPORT std::unique_ptr<base::Value> ToValue(bool value);
108 BRILLO_EXPORT std::unique_ptr<base::Value> ToValue(double value);
109 BRILLO_EXPORT std::unique_ptr<base::Value> ToValue(const std::string& value);
112 BRILLO_EXPORT std::unique_ptr<base::Value> ToValue(const char* value);
115 std::unique_ptr<base::Value> ToValue(
119 std::unique_ptr<base::Value> ToValue(const std::vector<T, Alloc>& list) { in ToValue() function
122 result->Append(ToValue(value).release()); in ToValue()
128 std::unique_ptr<base::Value> ToValue( in ToValue() function
132 result->Set(pair.first, ToValue(pair.second).release()); in ToValue()
Dvalue_conversion_unittest.cc238 EXPECT_JSON_EQ("1234", *ToValue(1234)); in TEST()
239 EXPECT_JSON_EQ("true", *ToValue(true)); in TEST()
240 EXPECT_JSON_EQ("false", *ToValue(false)); in TEST()
241 EXPECT_JSON_EQ("12.5", *ToValue(12.5)); in TEST()
242 EXPECT_JSON_EQ("'foobar'", *ToValue("foobar")); in TEST()
246 EXPECT_JSON_EQ("[1, 2, 3]", *ToValue(std::vector<int>{1, 2, 3})); in TEST()
247 EXPECT_JSON_EQ("[]", *ToValue(std::vector<int>{})); in TEST()
248 EXPECT_JSON_EQ("[true, false]", *ToValue(std::vector<bool>{true, false})); in TEST()
250 *ToValue(std::vector<std::string>{"foo", "bar"})); in TEST()
252 *ToValue(std::vector<std::vector<int>>{{1, 2}, {3}})); in TEST()
[all …]
Dvalue_conversion.cc40 std::unique_ptr<base::Value> ToValue(int value) { in ToValue() function
44 std::unique_ptr<base::Value> ToValue(bool value) { in ToValue() function
48 std::unique_ptr<base::Value> ToValue(double value) { in ToValue() function
52 std::unique_ptr<base::Value> ToValue(const char* value) { in ToValue() function
56 std::unique_ptr<base::Value> ToValue(const std::string& value) { in ToValue() function
/external/libchrome/base/process/
Dprocess_metrics.cc34 scoped_ptr<Value> SystemMetrics::ToValue() const { in ToValue() function in base::SystemMetrics
39 res->Set("meminfo", memory_info_.ToValue()); in ToValue()
40 res->Set("diskinfo", disk_info_.ToValue()); in ToValue()
43 res->Set("swapinfo", swap_info_.ToValue()); in ToValue()
Dprocess_metrics.h266 scoped_ptr<Value> ToValue() const;
341 scoped_ptr<Value> ToValue() const;
378 scoped_ptr<Value> ToValue() const;
402 scoped_ptr<Value> ToValue() const;
Dprocess_metrics_linux.cc558 scoped_ptr<Value> SystemMemoryInfoKB::ToValue() const { in ToValue() function in base::SystemMemoryInfoKB
769 scoped_ptr<Value> SystemDiskInfo::ToValue() const { in ToValue() function in base::SystemDiskInfo
895 scoped_ptr<Value> SwapInfo::ToValue() const { in ToValue() function in base::SwapInfo
/external/libweave/src/privet/
Dprivet_handler.cc120 std::unique_ptr<base::ListValue> ToValue(const Container& list) { in ToValue() function
550 ToValue(std::vector<std::string>{GetDeviceUiKind(cloud_->GetModelId())}) in HandleInfo()