Home
last modified time | relevance | path

Searched refs:base (Results 1 – 25 of 1643) sorted by relevance

12345678910>>...66

/system/bt/build/secondary/third_party/libchrome/
DBUILD.gn19 "base/at_exit.cc",
20 "base/atomic_ref_count.h",
21 "base/atomic_sequence_num.h",
22 "base/atomicops.h",
23 "base/base64.cc",
24 "base/base64.h",
25 "base/base_export.h",
26 "base/base_switches.cc",
27 "base/build_time.cc",
28 "base/callback_helpers.cc",
[all …]
/system/bt/build/dpkg/libchrome/debian/
Dinstall_headers.sh6 base
7 base/allocator
8 base/containers
9 base/debug
10 base/files
11 base/hash
12 base/i18n
13 base/json
14 base/memory
15 base/message_loop
[all …]
/system/bt/build/dpkg/libchrome-822064/debian/
Dinstall_headers.sh6 base
7 base/allocator
8 base/containers
9 base/debug
10 base/files
11 base/hash
12 base/i18n
13 base/json
14 base/memory
15 base/message_loop
[all …]
/system/libbase/
Dstrings_test.cpp27 std::vector<std::string> parts = android::base::Split("", ","); in TEST()
33 std::vector<std::string> parts = android::base::Split("foo", ","); in TEST()
39 std::vector<std::string> parts = android::base::Split("foo,bar,baz", ","); in TEST()
47 std::vector<std::string> parts = android::base::Split("foo,,bar", ","); in TEST()
55 std::vector<std::string> parts = android::base::Split("foo,bar,", ","); in TEST()
64 android::base::Split(std::string("foo\0bar", 7), std::string("\0", 1)); in TEST()
71 std::vector<std::string> parts = android::base::Split("foo:bar,baz", ",:"); in TEST()
79 std::vector<std::string> parts = android::base::Split("foo:,bar", ",:"); in TEST()
87 ASSERT_EQ("", android::base::Trim("")); in TEST()
91 ASSERT_EQ("foo", android::base::Trim("foo")); in TEST()
[all …]
Dparsedouble_test.cpp23 ASSERT_FALSE(android::base::ParseDouble("", &d)); in TEST()
24 ASSERT_FALSE(android::base::ParseDouble("x", &d)); in TEST()
25 ASSERT_FALSE(android::base::ParseDouble("123.4x", &d)); in TEST()
27 ASSERT_TRUE(android::base::ParseDouble("123.4", &d)); in TEST()
29 ASSERT_TRUE(android::base::ParseDouble("-123.4", &d)); in TEST()
32 ASSERT_TRUE(android::base::ParseDouble("0", &d, 0.0)); in TEST()
34 ASSERT_FALSE(android::base::ParseDouble("0", &d, 1e-9)); in TEST()
35 ASSERT_FALSE(android::base::ParseDouble("3.0", &d, -1.0, 2.0)); in TEST()
36 ASSERT_TRUE(android::base::ParseDouble("1.0", &d, 0.0, 2.0)); in TEST()
39 ASSERT_FALSE(android::base::ParseDouble("123.4x", nullptr)); in TEST()
[all …]
Dparseint_test.cpp26 ASSERT_FALSE(android::base::ParseInt("x", &i)); in TEST()
29 ASSERT_FALSE(android::base::ParseInt("123x", &i)); in TEST()
32 ASSERT_TRUE(android::base::ParseInt("123", &i)); in TEST()
36 EXPECT_TRUE(android::base::ParseInt(" 123", &i)); in TEST()
38 ASSERT_TRUE(android::base::ParseInt("-123", &i)); in TEST()
41 EXPECT_TRUE(android::base::ParseInt(" -123", &i)); in TEST()
45 ASSERT_TRUE(android::base::ParseInt("1234", &s)); in TEST()
48 ASSERT_TRUE(android::base::ParseInt("12", &i, 0, 15)); in TEST()
51 ASSERT_FALSE(android::base::ParseInt("-12", &i, 0, 15)); in TEST()
54 ASSERT_FALSE(android::base::ParseInt("16", &i, 0, 15)); in TEST()
[all …]
Dproperties_test.cpp33 android::base::SetProperty("debug.libbase.property_test", "hello"); in TEST()
35 std::string s = android::base::GetProperty("debug.libbase.property_test", ""); in TEST()
38 android::base::SetProperty("debug.libbase.property_test", "world"); in TEST()
39 s = android::base::GetProperty("debug.libbase.property_test", ""); in TEST()
42 s = android::base::GetProperty("this.property.does.not.exist", ""); in TEST()
45 s = android::base::GetProperty("this.property.does.not.exist", "default"); in TEST()
58 ASSERT_FALSE(android::base::SetProperty(key, value)); in TEST()
59 ASSERT_EQ("missing", android::base::GetProperty(key, "missing")); in TEST()
63 ASSERT_TRUE(android::base::SetProperty(key, value)); in TEST()
64 ASSERT_EQ(value, android::base::GetProperty(key, "missing")); in TEST()
[all …]
Dlogging_test.cpp101 if (android::base::kEnableDChecks) { in TEST()
106 if (android::base::kEnableDChecks) { in TEST()
112 if (android::base::kEnableDChecks) { in TEST()
118 if (android::base::kEnableDChecks) { in TEST()
131 static_assert(android::base::severity < android::base::FATAL, "Bad input"); \
132 for (size_t i = static_cast<size_t>(android::base::severity) + 1; \
133 i <= static_cast<size_t>(android::base::FATAL); \
136 android::base::ScopedLogSeverity sls2(static_cast<android::base::LogSeverity>(i)); \
140 android::base::ScopedLogSeverity sls2(static_cast<android::base::LogSeverity>(i)); \
141 EXPECT_FALSE(WOULD_LOG(::android::base::severity)) << i; \
[all …]
/system/update_engine/update_manager/
Devaluation_context.h66 base::TimeDelta evaluation_timeout,
67 base::TimeDelta expiration_timeout,
68 std::unique_ptr<base::Callback<void(EvaluationContext*)>> unregister_cb);
69 explicit EvaluationContext(base::TimeDelta evaluation_timeout) in EvaluationContext()
72 base::TimeDelta::Max(), in EvaluationContext()
73 std::unique_ptr<base::Callback<void(EvaluationContext*)>>()) {} in EvaluationContext()
88 bool IsWallclockTimeGreaterThan(base::Time timestamp);
89 bool IsMonotonicTimeGreaterThan(base::Time timestamp);
114 bool RunOnValueChangeOrTimeout(base::Closure callback);
124 std::unique_ptr<base::Closure> RemoveObserversAndTimeout();
[all …]
/system/server_configurable_flags/libflags/
Dserver_configurable_flags_test.cc31 using namespace android::base;
44 android::base::SetProperty("persist.device_config.category.flag", "hello"); in TEST()
50 android::base::SetProperty("persist.device_config.category.flag", ""); in TEST()
67 android::base::SetProperty("persist.device_config.attempted_boot_count", "1"); in TEST()
68 android::base::SetProperty("persist.device_config.category1.prop1", "val1"); in TEST()
69 android::base::SetProperty("persist.device_config.category1.prop2", "val2"); in TEST()
70 android::base::SetProperty("persist.device_config.category2.prop3", "val3"); in TEST()
71 android::base::SetProperty("sys.category3.test", "val4"); in TEST()
72 android::base::SetProperty("device_config.reset_performed", ""); in TEST()
76 ASSERT_EQ("2", android::base::GetProperty("persist.device_config.attempted_boot_count", "")); in TEST()
[all …]
/system/bt/include/
Dabstract_message_loop.h43 class AbstractMessageLoop : public base::SingleThreadTaskExecutor {
45 static scoped_refptr<base::SingleThreadTaskRunner> current_task_runner() { in current_task_runner()
46 return base::ThreadTaskRunnerHandle::Get(); in current_task_runner()
50 class AbstractTestMessageLoop : public base::test::TaskEnvironment {
52 static scoped_refptr<base::SingleThreadTaskRunner> current_task_runner() { in current_task_runner()
53 return base::ThreadTaskRunnerHandle::Get(); in current_task_runner()
59 base::AbstractTestMessageLoop var { \
60 base::test::TaskEnvironment::ThreadingMode::MAIN_THREAD_ONLY \
63 inline void set_message_loop_type_IO(base::Thread::Options& options) { in set_message_loop_type_IO()
64 options.message_pump_type = base::MessagePumpType::IO; in set_message_loop_type_IO()
[all …]
/system/bt/service/test/
Dsettings_unittest.cc35 void SetUp() override { base::CommandLine::Reset(); } in SetUp()
37 void TearDown() override { base::CommandLine::Reset(); } in TearDown()
40 base::AtExitManager exit_manager_;
48 const base::CommandLine::CharType* argv[] = {"program"}; in TEST_F()
49 EXPECT_TRUE(base::CommandLine::Init(ARRAY_SIZE(argv), argv)); in TEST_F()
54 const base::CommandLine::CharType* argv[] = { in TEST_F()
56 EXPECT_TRUE(base::CommandLine::Init(ARRAY_SIZE(argv), argv)); in TEST_F()
61 const base::CommandLine::CharType* argv[] = {"program", "--foobarbaz"}; in TEST_F()
62 EXPECT_TRUE(base::CommandLine::Init(ARRAY_SIZE(argv), argv)); in TEST_F()
67 const base::CommandLine::CharType* argv[] = {"program", "foobarbaz"}; in TEST_F()
[all …]
/system/core/fs_mgr/libfs_avb/tests/
Dfs_avb_test_util.h40 int rc = system(base::StringPrintf(command_format, ##__VA_ARGS__).c_str()); \
51 base::FilePath path;
59 base::FilePath key_blob_path;
62 inline android::base::unique_fd OpenUniqueReadFd(const base::FilePath& file_path) { in OpenUniqueReadFd()
63 return android::base::unique_fd(open(file_path.value().c_str(), O_RDONLY | O_CLOEXEC)); in OpenUniqueReadFd()
81 base::FilePath GenerateVBMetaImage(
83 const base::FilePath& key_path,
84 const std::vector<base::FilePath>& include_descriptor_image_paths,
90 base::FilePath ExtractVBMetaImage(const base::FilePath& image_path,
96 base::FilePath GenerateImage(const std::string& file_name, size_t image_size,
[all …]
Dfs_avb_test_util.cpp29 base::FilePath BaseFsAvbTest::data_dir_ = base::FilePath("tests/data");
36 base::SetCurrentDirectory(base::FilePath(android::base::GetExecutableDirectory())); in SetUp()
39 base::FilePath tmp_dir; in SetUp()
41 base::CreateTemporaryDirInDir(tmp_dir, "libfs_avb-tests.", &test_dir_); in SetUp()
47 ASSERT_TRUE(base::DeleteFile(test_dir_, true /* recursive */)); in TearDown()
56 base::FilePath image_path = iter->second.path; in CalcVBMetaDigest()
57 base::FilePath vbmeta_digest_path = test_dir_.Append("vbmeta_digest"); in CalcVBMetaDigest()
65 EXPECT_TRUE(base::ReadFileToString(vbmeta_digest_path, &vbmeta_digest_data)); in CalcVBMetaDigest()
68 base::TrimString(vbmeta_digest_data, " \t\n", &trimmed_digest_data); in CalcVBMetaDigest()
72 base::FilePath BaseFsAvbTest::GenerateVBMetaImage( in GenerateVBMetaImage()
[all …]
Dutil_test.cpp155 base::FilePath tmp_dir; in TEST()
159 base::FilePath wait_path = tmp_dir.Append("libfs_avb-test-exist-dir"); in TEST()
160 ASSERT_TRUE(base::DeleteFile(wait_path, false /* resursive */)); in TEST()
162 EXPECT_TRUE(base::CreateDirectory(wait_path)); in TEST()
166 ASSERT_TRUE(base::DeleteFile(wait_path, false /* resursive */)); in TEST()
170 base::FilePath wait_path("/path/not/exist"); in TEST()
176 base::FilePath tmp_dir; in TEST()
180 base::FilePath wait_path = tmp_dir.Append("libfs_avb-test-exist-dir"); in TEST()
181 ASSERT_TRUE(base::DeleteFile(wait_path, false /* resursive */)); in TEST()
186 EXPECT_TRUE(base::CreateDirectory(wait_path)); in TEST()
[all …]
/system/bpf/libbpf_android/include/bpf/
DBpfMap.h64 base::Result<Key> getFirstKey() const { in getFirstKey()
72 base::Result<Key> getNextKey(const Key& key) const { in getNextKey()
80 base::Result<void> writeValue(const Key& key, const Value& value, uint64_t flags) { in writeValue()
87 base::Result<Value> readValue(const Key key) const { in readValue()
95 base::Result<void> deleteValue(const Key& key) { in deleteValue()
103 base::Result<void> init(const char* path);
107 base::Result<void> iterate(
108 const std::function<base::Result<void>(const Key& key, const BpfMap<Key, Value>& map)>&
113 base::Result<void> iterateWithValue(
114 const std::function<base::Result<void>(const Key& key, const Value& value,
[all …]
/system/apex/apexd/
Dapexd.h63 android::base::Result<void> Unmount(
66 android::base::Result<void> ResumeRevertIfNeeded();
68 android::base::Result<void> PreinstallPackages(
70 android::base::Result<void> PostinstallPackages(
73 android::base::Result<void> StagePackages(
75 android::base::Result<void> UnstagePackages(
78 android::base::Result<std::vector<ApexFile>> SubmitStagedSession(
82 android::base::Result<void> MarkStagedSessionReady(const int session_id)
84 android::base::Result<void> MarkStagedSessionSuccessful(const int session_id)
87 android::base::Result<void> RevertActiveSessions(
[all …]
Dapexd_utils.h63 inline android::base::Result<void> ForkAndRun( in ForkAndRun()
65 LOG(DEBUG) << "Forking : " << android::base::Join(args, " "); in ForkAndRun()
74 return android::base::ErrnoError() << "Unable to fork"; in ForkAndRun()
85 return android::base::Error() << "Failed run: status=" << rc; in ForkAndRun()
91 android::base::Result<void> WalkDir(const std::string& path, Fn fn) { in WalkDir()
101 return android::base::Error() in WalkDir()
108 android::base::Result<std::vector<std::string>> ReadDir(const std::string& path, in ReadDir()
129 inline android::base::Result<void> CreateDirIfNeeded(const std::string& path, in CreateDirIfNeeded()
136 return android::base::ErrnoError() << "Could not mkdir " << path; in CreateDirIfNeeded()
139 return android::base::ErrnoError() << "Could not stat " << path; in CreateDirIfNeeded()
[all …]
/system/update_engine/common/
Dclock.cc23 base::Time Clock::GetWallclockTime() const { in GetWallclockTime()
24 return base::Time::Now(); in GetWallclockTime()
27 base::Time Clock::GetMonotonicTime() const { in GetMonotonicTime()
35 return base::Time(); in GetMonotonicTime()
39 now_tv.tv_usec = now_ts.tv_nsec / base::Time::kNanosecondsPerMicrosecond; in GetMonotonicTime()
40 return base::Time::FromTimeVal(now_tv); in GetMonotonicTime()
43 base::Time Clock::GetBootTime() const { in GetBootTime()
50 return base::Time(); in GetBootTime()
54 now_tv.tv_usec = now_ts.tv_nsec / base::Time::kNanosecondsPerMicrosecond; in GetBootTime()
55 return base::Time::FromTimeVal(now_tv); in GetBootTime()
Dfake_clock.h29 base::Time GetWallclockTime() const override { return wallclock_time_; } in GetWallclockTime()
31 base::Time GetMonotonicTime() const override { return monotonic_time_; } in GetMonotonicTime()
33 base::Time GetBootTime() const override { return boot_time_; } in GetBootTime()
35 void SetWallclockTime(const base::Time& time) { wallclock_time_ = time; } in SetWallclockTime()
37 void SetMonotonicTime(const base::Time& time) { monotonic_time_ = time; } in SetMonotonicTime()
39 void SetBootTime(const base::Time& time) { boot_time_ = time; } in SetBootTime()
42 base::Time wallclock_time_;
43 base::Time monotonic_time_;
44 base::Time boot_time_;
Dprefs.cc37 void DeleteEmptyDirectories(const base::FilePath& path) { in DeleteEmptyDirectories()
38 base::FileEnumerator path_enum( in DeleteEmptyDirectories()
39 path, false /* recursive */, base::FileEnumerator::DIRECTORIES); in DeleteEmptyDirectories()
40 for (base::FilePath dir_path = path_enum.Next(); !dir_path.empty(); in DeleteEmptyDirectories()
43 if (base::IsDirectoryEmpty(dir_path)) in DeleteEmptyDirectories()
45 base::DeleteFile(dir_path, false); in DeleteEmptyDirectories()
47 base::DeleteFile(dir_path); in DeleteEmptyDirectories()
73 base::TrimWhitespaceASCII(str_value, base::TRIM_ALL, &str_value); in GetInt64()
74 TEST_AND_RETURN_FALSE(base::StringToInt64(str_value, value)); in GetInt64()
79 return SetString(key, base::NumberToString(value)); in SetInt64()
[all …]
/system/bt/gd/common/
Dbind.h24 using base::Bind;
25 using base::BindOnce;
26 using base::IgnoreResult;
27 using base::MakeUnboundRunType;
28 using base::Owned;
29 using base::Passed;
30 using base::RetainedRef;
31 using base::Unretained;
34 inline base::Callback<MakeUnboundRunType<Functor, T, Args...>> BindOn(T* obj, Functor&& functor, Ar… in BindOn()
/system/core/toolbox/
Dmodprobe.cpp78 void MyLogger(android::base::LogId id, android::base::LogSeverity severity, const char* tag, in MyLogger()
80 android::base::StdioLogger(id, severity, tag, file, line, message); in MyLogger()
82 android::base::KernelLogger(id, severity, tag, file, line, message); in MyLogger()
89 android::base::InitLogging(argv, MyLogger); in modprobe_main()
90 android::base::SetMinimumLogSeverity(android::base::INFO); in modprobe_main()
125 if (!android::base::ReadFileToString(optarg, &mods)) { in modprobe_main()
129 for (auto mod : android::base::Split(stripComments(mods), "\n")) { in modprobe_main()
130 mod = android::base::Trim(mod); in modprobe_main()
147 android::base::SetMinimumLogSeverity(android::base::INFO); in modprobe_main()
155 android::base::SetMinimumLogSeverity(android::base::WARNING); in modprobe_main()
[all …]
/system/bt/common/
Donce_timer_unittest.cc98 base::BindOnce(&OnceTimerTest::GetName, in TEST_F()
99 base::Unretained(this), &my_name, promise_), in TEST_F()
100 base::TimeDelta::FromMilliseconds(delay_ms)); in TEST_F()
125 base::BindOnce(&OnceTimerTest::CancelTimerAndWait, in TEST_F()
126 base::Unretained(this)), in TEST_F()
127 base::TimeDelta::FromMilliseconds(delay_ms)); in TEST_F()
137 base::BindOnce(&OnceTimerTest::ShouldNotHappen, base::Unretained(this)), in TEST_F()
138 base::TimeDelta::FromMilliseconds(delay_ms)); in TEST_F()
151 base::BindOnce(&OnceTimerTest::ShouldNotHappen, base::Unretained(this)), in TEST_F()
152 base::TimeDelta::FromMilliseconds(delay_ms)); in TEST_F()
[all …]
/system/bt/btif/avrcp/
Davrcp_service.cc39 void do_in_avrcp_jni(const base::Closure& task) { in do_in_avrcp_jni()
141 do_in_avrcp_jni(base::Bind(&MediaInterface::SendKeyEvent, in SendKeyEvent()
142 base::Unretained(wrapped_), key, state)); in SendKeyEvent()
147 do_in_main_thread(FROM_HERE, base::Bind(cb, data)); in GetSongInfo()
150 auto bound_cb = base::Bind(cb_lambda, info_cb); in GetSongInfo()
152 do_in_avrcp_jni(base::Bind(&MediaInterface::GetSongInfo, in GetSongInfo()
153 base::Unretained(wrapped_), bound_cb)); in GetSongInfo()
158 do_in_main_thread(FROM_HERE, base::Bind(cb, status)); in GetPlayStatus()
161 auto bound_cb = base::Bind(cb_lambda, status_cb); in GetPlayStatus()
163 do_in_avrcp_jni(base::Bind(&MediaInterface::GetPlayStatus, in GetPlayStatus()
[all …]

12345678910>>...66