this repo has no description
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add CoreAnalytics framework stub

+721
+1
src/private-frameworks/CMakeLists.txt
··· 7 7 add_subdirectory(AuthKit) 8 8 add_subdirectory(CrashReporterSupport) 9 9 add_subdirectory(ConfigurationProfiles) 10 + add_subdirectory(CoreAnalytics) 10 11 add_subdirectory(CoreSymbolication) 11 12 add_subdirectory(CoreUI) 12 13 add_subdirectory(DataDetectors)
+27
src/private-frameworks/CoreAnalytics/CMakeLists.txt
··· 1 + project(CoreAnalytics) 2 + 3 + set(DYLIB_COMPAT_VERSION "1.0.0") 4 + set(DYLIB_CURRENT_VERSION "1.0.0") 5 + 6 + include_directories(BEFORE ${CMAKE_SOURCE_DIR}/src/external/libcxx/include) 7 + 8 + add_compile_options(-Wno-error=stdlibcxx-not-found) 9 + 10 + add_framework(CoreAnalytics 11 + FAT 12 + CURRENT_VERSION 13 + PRIVATE 14 + VERSION "A" 15 + 16 + SOURCES 17 + src/CoreAnalytics.mm 18 + src/AnalyticsEventObserver.m 19 + src/AnalyticsConfigurationObserver.m 20 + 21 + DEPENDENCIES 22 + system 23 + objc 24 + Foundation 25 + cxx 26 + AppleSauce 27 + )
+24
src/private-frameworks/CoreAnalytics/include/CoreAnalytics/AnalyticsConfigurationObserver.h
··· 1 + /* 2 + This file is part of Darling. 3 + 4 + Copyright (C) 2020 Lubos Dolezel 5 + 6 + Darling is free software: you can redistribute it and/or modify 7 + it under the terms of the GNU General Public License as published by 8 + the Free Software Foundation, either version 3 of the License, or 9 + (at your option) any later version. 10 + 11 + Darling is distributed in the hope that it will be useful, 12 + but WITHOUT ANY WARRANTY; without even the implied warranty of 13 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 + GNU General Public License for more details. 15 + 16 + You should have received a copy of the GNU General Public License 17 + along with Darling. If not, see <http://www.gnu.org/licenses/>. 18 + */ 19 + 20 + #include <Foundation/Foundation.h> 21 + 22 + @interface AnalyticsConfigurationObserver : NSObject 23 + 24 + @end
+24
src/private-frameworks/CoreAnalytics/include/CoreAnalytics/AnalyticsEventObserver.h
··· 1 + /* 2 + This file is part of Darling. 3 + 4 + Copyright (C) 2020 Lubos Dolezel 5 + 6 + Darling is free software: you can redistribute it and/or modify 7 + it under the terms of the GNU General Public License as published by 8 + the Free Software Foundation, either version 3 of the License, or 9 + (at your option) any later version. 10 + 11 + Darling is distributed in the hope that it will be useful, 12 + but WITHOUT ANY WARRANTY; without even the implied warranty of 13 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 + GNU General Public License for more details. 15 + 16 + You should have received a copy of the GNU General Public License 17 + along with Darling. If not, see <http://www.gnu.org/licenses/>. 18 + */ 19 + 20 + #include <Foundation/Foundation.h> 21 + 22 + @interface AnalyticsEventObserver : NSObject 23 + 24 + @end
+153
src/private-frameworks/CoreAnalytics/include/CoreAnalytics/CoreAnalytics.h
··· 1 + /* 2 + This file is part of Darling. 3 + 4 + Copyright (C) 2020 Lubos Dolezel 5 + 6 + Darling is free software: you can redistribute it and/or modify 7 + it under the terms of the GNU General Public License as published by 8 + the Free Software Foundation, either version 3 of the License, or 9 + (at your option) any later version. 10 + 11 + Darling is distributed in the hope that it will be useful, 12 + but WITHOUT ANY WARRANTY; without even the implied warranty of 13 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 + GNU General Public License for more details. 15 + 16 + You should have received a copy of the GNU General Public License 17 + along with Darling. If not, see <http://www.gnu.org/licenses/>. 18 + */ 19 + 20 + #ifndef _CoreAnalytics_H_ 21 + #define _CoreAnalytics_H_ 22 + 23 + #include <string> 24 + #include <functional> 25 + #include <memory> 26 + #include <string_view> 27 + #include <AppleSauce/AppleSauce.h> 28 + #include <dispatch/dispatch.h> 29 + #include <xpc/xpc.h> 30 + 31 + #import <Foundation/Foundation.h> 32 + 33 + #import <CoreAnalytics/AnalyticsConfigurationObserver.h> 34 + #import <CoreAnalytics/AnalyticsEventObserver.h> 35 + 36 + /** 37 + * NOTE(@facekapow): 38 + * these method signatures are pretty much guesses. 39 + * good guesses, but guesses nonetheless 40 + * 41 + * unlike the guesses in AppleSauce, these guesses are 42 + * less reliable 43 + */ 44 + 45 + #ifdef __cplusplus 46 + extern "C" { 47 + #endif 48 + 49 + bool AnalyticsIsEventUsed(void*); 50 + void AnalyticsSendEvent(void*, void*); 51 + bool AnalyticsSendEventLazy(void*); 52 + void AnalyticsSetCallbackForQueriedEvent(void*, void(^)()); 53 + void AnalyticsSetCallbackForQueriedEventWithQueue(void*, int, void(^)()); 54 + 55 + #ifdef __cplusplus 56 + }; 57 + #endif 58 + 59 + #ifdef __cplusplus 60 + 61 + std::string analytics_tool_dump(std::string); 62 + void analytics_tool_save(std::string); 63 + void analytics_tool_commit(); 64 + void analytics_tool_rollover(); 65 + bool analytics_tool_has_config(); 66 + std::string analytics_tool_config_dump(); 67 + std::string analytics_tool_config_info(); 68 + std::string analytics_tool_config_list(); 69 + void analytics_tool_send_barrier(); 70 + void analytics_tool_config_reload(); 71 + std::string analytics_tool_get_cache_list(); 72 + std::string analytics_tool_transform_info(std::string); 73 + bool analytics_tool_transform_evict(std::string); 74 + bool analytics_tool_transform_persist(std::string); 75 + void analytics_tool_config_set_tasking(std::string); 76 + std::string analytics_tool_get_queried_events(); 77 + bool analytics_tool_is_event_used_check_db(std::string); 78 + void analytics_tool_config_set_tasking_ndjson(applesauce::xpc::object); 79 + 80 + namespace CoreAnalytics { 81 + class EventObserver { 82 + public: 83 + ~EventObserver(); 84 + }; 85 + class ConfigurationObserver { 86 + public: 87 + ~ConfigurationObserver(); 88 + }; 89 + class Client { 90 + public: 91 + void barrierSync(); 92 + void sendAwdMetric(unsigned int, void const*, unsigned long); 93 + void sendAwdTrigger(char const*, unsigned int, unsigned int, unsigned int, void const*, unsigned long); 94 + void sendEventAlways(char const*, applesauce::xpc::object const&); 95 + dispatch_queue_t getCallbackQueue(); 96 + void sendEventWithTag(char const*, applesauce::xpc::object const&, applesauce::xpc::object); 97 + void updateDaemonState(int); 98 + void registerStateHandler(std::string const&, applesauce::dispatch::v1::queue, std::function<void(std::string const&, applesauce::xpc::object const&)>); 99 + void sendAwdMetricWithTag(char const*, unsigned int, applesauce::xpc::object, void const*, unsigned long); 100 + void addAwdQueriableMetric(unsigned int); 101 + void handleQueryState_sync(applesauce::xpc::dict const&); 102 + void registerEventObserver(std::weak_ptr<CoreAnalytics::EventObserver>); 103 + void sendAwdTriggerWithTag(char const*, unsigned int, unsigned int, applesauce::xpc::object, void const*, unsigned long); 104 + void sendManagementCommand(char const*); 105 + void sendManagementCommand(char const*, applesauce::xpc::dict); 106 + void registerAwdQueryHandler(std::function<void(unsigned int, char const*, void*)>); 107 + void sendCheckinMessage_sync(); 108 + void handleServerMessage_sync(applesauce::xpc::dict); 109 + void handleQueryAwdMetric_sync(applesauce::xpc::dict const&); 110 + xpc_object_t sendManagementCommandSync(char const*); 111 + xpc_object_t sendManagementCommandSync(char const*, applesauce::xpc::dict); 112 + void handleSinkMessageEmit_sync(applesauce::xpc::dict const&); 113 + void sendStateHandlersList_sync(); 114 + void registerConfigurationObserver(std::weak_ptr<ConfigurationObserver>); 115 + void handleConfigurationChange_sync(applesauce::xpc::dict const&); 116 + void sendAwdQueriableMetricsList_sync(); 117 + static Client* get(); 118 + void init(); 119 + Client(); 120 + ~Client(); 121 + void sendXpcMessage(applesauce::xpc::dict) const; 122 + bool isEventWhitelisted(std::string_view) const; 123 + bool isAwdMetricWhitelisted(unsigned int) const; 124 + bool hasConfig() const; 125 + }; 126 + }; 127 + 128 + #endif 129 + 130 + #ifdef __cplusplus 131 + extern "C" { 132 + #endif 133 + 134 + void analytics_cancel_queried_awd_metric(char const*, xpc_object_t); 135 + bool analytics_is_awd_metric_enabled(unsigned int); 136 + bool analytics_is_event_used(char const*); 137 + void analytics_mark_awd_queriable(unsigned int); 138 + void analytics_send_awd_metric(unsigned int, void const*, unsigned long); 139 + void analytics_send_awd_trigger(char const*, unsigned int, unsigned int, unsigned int, void const*, unsigned long); 140 + void analytics_send_event(char const*, xpc_object_t); 141 + void analytics_send_event_lazy(char const*, xpc_object_t); 142 + void analytics_send_queried_awd_metric(char const*, unsigned int, xpc_object_t, void const*, unsigned long); 143 + void analytics_send_queried_awd_trigger(char const*, unsigned int, unsigned int, xpc_object_t, void const*, unsigned long); 144 + void analytics_set_awd_query_callback(void(^)(unsigned int, char const*, void*)); 145 + void analytics_set_callback_for_queried_event(char const*, void(^)()); 146 + void analytics_set_callback_for_queried_event_with_queue(char const*, void*, void(^)()); 147 + void report_locale_prefs_to_analyticsd(); 148 + 149 + #ifdef __cplusplus 150 + }; 151 + #endif 152 + 153 + #endif
+34
src/private-frameworks/CoreAnalytics/src/AnalyticsConfigurationObserver.m
··· 1 + /* 2 + This file is part of Darling. 3 + 4 + Copyright (C) 2020 Lubos Dolezel 5 + 6 + Darling is free software: you can redistribute it and/or modify 7 + it under the terms of the GNU General Public License as published by 8 + the Free Software Foundation, either version 3 of the License, or 9 + (at your option) any later version. 10 + 11 + Darling is distributed in the hope that it will be useful, 12 + but WITHOUT ANY WARRANTY; without even the implied warranty of 13 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 + GNU General Public License for more details. 15 + 16 + You should have received a copy of the GNU General Public License 17 + along with Darling. If not, see <http://www.gnu.org/licenses/>. 18 + */ 19 + 20 + #import <CoreAnalytics/AnalyticsConfigurationObserver.h> 21 + 22 + @implementation AnalyticsConfigurationObserver 23 + 24 + - (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector 25 + { 26 + return [NSMethodSignature signatureWithObjCTypes: "v@:"]; 27 + } 28 + 29 + - (void)forwardInvocation:(NSInvocation *)anInvocation 30 + { 31 + NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]); 32 + } 33 + 34 + @end
+34
src/private-frameworks/CoreAnalytics/src/AnalyticsEventObserver.m
··· 1 + /* 2 + This file is part of Darling. 3 + 4 + Copyright (C) 2020 Lubos Dolezel 5 + 6 + Darling is free software: you can redistribute it and/or modify 7 + it under the terms of the GNU General Public License as published by 8 + the Free Software Foundation, either version 3 of the License, or 9 + (at your option) any later version. 10 + 11 + Darling is distributed in the hope that it will be useful, 12 + but WITHOUT ANY WARRANTY; without even the implied warranty of 13 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 + GNU General Public License for more details. 15 + 16 + You should have received a copy of the GNU General Public License 17 + along with Darling. If not, see <http://www.gnu.org/licenses/>. 18 + */ 19 + 20 + #import <CoreAnalytics/AnalyticsEventObserver.h> 21 + 22 + @implementation AnalyticsEventObserver 23 + 24 + - (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector 25 + { 26 + return [NSMethodSignature signatureWithObjCTypes: "v@:"]; 27 + } 28 + 29 + - (void)forwardInvocation:(NSInvocation *)anInvocation 30 + { 31 + NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]); 32 + } 33 + 34 + @end
+423
src/private-frameworks/CoreAnalytics/src/CoreAnalytics.mm
··· 1 + /* 2 + This file is part of Darling. 3 + 4 + Copyright (C) 2020 Lubos Dolezel 5 + 6 + Darling is free software: you can redistribute it and/or modify 7 + it under the terms of the GNU General Public License as published by 8 + the Free Software Foundation, either version 3 of the License, or 9 + (at your option) any later version. 10 + 11 + Darling is distributed in the hope that it will be useful, 12 + but WITHOUT ANY WARRANTY; without even the implied warranty of 13 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 + GNU General Public License for more details. 15 + 16 + You should have received a copy of the GNU General Public License 17 + along with Darling. If not, see <http://www.gnu.org/licenses/>. 18 + */ 19 + 20 + #include <CoreAnalytics/CoreAnalytics.h> 21 + #include <iostream> 22 + 23 + static bool verbose = false; 24 + 25 + __attribute__((constructor)) 26 + static void initme() { 27 + verbose = getenv("STUB_VERBOSE") != NULL; 28 + }; 29 + 30 + extern "C" { 31 + 32 + bool AnalyticsIsEventUsed(void*) { 33 + if (verbose) 34 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 35 + return false; 36 + }; 37 + 38 + void AnalyticsSendEvent(void*, void*) { 39 + if (verbose) 40 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 41 + }; 42 + 43 + bool AnalyticsSendEventLazy(void*) { 44 + if (verbose) 45 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 46 + return false; 47 + }; 48 + 49 + void AnalyticsSetCallbackForQueriedEvent(void*, void(^)()) { 50 + if (verbose) 51 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 52 + }; 53 + 54 + void AnalyticsSetCallbackForQueriedEventWithQueue(void*, int, void(^)()) { 55 + if (verbose) 56 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 57 + }; 58 + 59 + }; 60 + 61 + std::string analytics_tool_dump(std::string) { 62 + if (verbose) 63 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 64 + return std::string(); 65 + }; 66 + 67 + void analytics_tool_save(std::string) { 68 + if (verbose) 69 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 70 + }; 71 + 72 + void analytics_tool_commit() { 73 + if (verbose) 74 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 75 + }; 76 + 77 + void analytics_tool_rollover() { 78 + if (verbose) 79 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 80 + }; 81 + 82 + bool analytics_tool_has_config() { 83 + if (verbose) 84 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 85 + return false; 86 + }; 87 + 88 + std::string analytics_tool_config_dump() { 89 + if (verbose) 90 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 91 + return std::string(); 92 + }; 93 + 94 + std::string analytics_tool_config_info() { 95 + if (verbose) 96 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 97 + return std::string(); 98 + }; 99 + 100 + std::string analytics_tool_config_list() { 101 + if (verbose) 102 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 103 + return std::string(); 104 + }; 105 + 106 + void analytics_tool_send_barrier() { 107 + if (verbose) 108 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 109 + }; 110 + 111 + void analytics_tool_config_reload() { 112 + if (verbose) 113 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 114 + }; 115 + 116 + std::string analytics_tool_get_cache_list() { 117 + if (verbose) 118 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 119 + return std::string(); 120 + }; 121 + 122 + std::string analytics_tool_transform_info(std::string) { 123 + if (verbose) 124 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 125 + return std::string(); 126 + }; 127 + 128 + bool analytics_tool_transform_evict(std::string) { 129 + if (verbose) 130 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 131 + return false; 132 + }; 133 + 134 + bool analytics_tool_transform_persist(std::string) { 135 + if (verbose) 136 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 137 + return false; 138 + }; 139 + 140 + void analytics_tool_config_set_tasking(std::string) { 141 + if (verbose) 142 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 143 + }; 144 + 145 + std::string analytics_tool_get_queried_events() { 146 + if (verbose) 147 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 148 + return std::string(); 149 + }; 150 + 151 + bool analytics_tool_is_event_used_check_db(std::string) { 152 + if (verbose) 153 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 154 + return false; 155 + }; 156 + 157 + void analytics_tool_config_set_tasking_ndjson(applesauce::xpc::object) { 158 + if (verbose) 159 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 160 + }; 161 + 162 + CoreAnalytics::EventObserver::~EventObserver() { 163 + if (verbose) 164 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 165 + }; 166 + 167 + CoreAnalytics::ConfigurationObserver::~ConfigurationObserver() { 168 + if (verbose) 169 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 170 + }; 171 + 172 + void CoreAnalytics::Client::barrierSync() { 173 + if (verbose) 174 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 175 + }; 176 + 177 + void CoreAnalytics::Client::sendAwdMetric(unsigned int, void const*, unsigned long) { 178 + if (verbose) 179 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 180 + }; 181 + 182 + void CoreAnalytics::Client::sendAwdTrigger(char const*, unsigned int, unsigned int, unsigned int, void const*, unsigned long) { 183 + if (verbose) 184 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 185 + }; 186 + 187 + void CoreAnalytics::Client::sendEventAlways(char const*, applesauce::xpc::object const&) { 188 + if (verbose) 189 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 190 + }; 191 + 192 + dispatch_queue_t CoreAnalytics::Client::getCallbackQueue() { 193 + if (verbose) 194 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 195 + return NULL; 196 + }; 197 + 198 + void CoreAnalytics::Client::sendEventWithTag(char const*, applesauce::xpc::object const&, applesauce::xpc::object) { 199 + if (verbose) 200 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 201 + }; 202 + 203 + void CoreAnalytics::Client::updateDaemonState(int) { 204 + if (verbose) 205 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 206 + }; 207 + 208 + void CoreAnalytics::Client::registerStateHandler(std::string const&, applesauce::dispatch::v1::queue, std::function<void (std::string const&, applesauce::xpc::object const&)>) { 209 + if (verbose) 210 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 211 + }; 212 + 213 + void CoreAnalytics::Client::sendAwdMetricWithTag(char const*, unsigned int, applesauce::xpc::object, void const*, unsigned long) { 214 + if (verbose) 215 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 216 + }; 217 + 218 + void CoreAnalytics::Client::addAwdQueriableMetric(unsigned int) { 219 + if (verbose) 220 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 221 + }; 222 + 223 + void CoreAnalytics::Client::handleQueryState_sync(applesauce::xpc::dict const&) { 224 + if (verbose) 225 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 226 + }; 227 + 228 + void CoreAnalytics::Client::registerEventObserver(std::weak_ptr<CoreAnalytics::EventObserver>) { 229 + if (verbose) 230 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 231 + }; 232 + 233 + void CoreAnalytics::Client::sendAwdTriggerWithTag(char const*, unsigned int, unsigned int, applesauce::xpc::object, void const*, unsigned long) { 234 + if (verbose) 235 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 236 + }; 237 + 238 + void CoreAnalytics::Client::sendManagementCommand(char const*) { 239 + if (verbose) 240 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 241 + }; 242 + 243 + void CoreAnalytics::Client::sendManagementCommand(char const*, applesauce::xpc::dict) { 244 + if (verbose) 245 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 246 + }; 247 + 248 + void CoreAnalytics::Client::registerAwdQueryHandler(std::function<void (unsigned int, char const*, void*)>) { 249 + if (verbose) 250 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 251 + }; 252 + 253 + void CoreAnalytics::Client::sendCheckinMessage_sync() { 254 + if (verbose) 255 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 256 + }; 257 + 258 + void CoreAnalytics::Client::handleServerMessage_sync(applesauce::xpc::dict) { 259 + if (verbose) 260 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 261 + }; 262 + 263 + void CoreAnalytics::Client::handleQueryAwdMetric_sync(applesauce::xpc::dict const&) { 264 + if (verbose) 265 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 266 + }; 267 + 268 + xpc_object_t CoreAnalytics::Client::sendManagementCommandSync(char const*) { 269 + if (verbose) 270 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 271 + return NULL; 272 + }; 273 + 274 + xpc_object_t CoreAnalytics::Client::sendManagementCommandSync(char const*, applesauce::xpc::dict) { 275 + if (verbose) 276 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 277 + return NULL; 278 + }; 279 + 280 + void CoreAnalytics::Client::handleSinkMessageEmit_sync(applesauce::xpc::dict const&) { 281 + if (verbose) 282 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 283 + }; 284 + 285 + void CoreAnalytics::Client::sendStateHandlersList_sync() { 286 + if (verbose) 287 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 288 + }; 289 + 290 + void CoreAnalytics::Client::registerConfigurationObserver(std::weak_ptr<CoreAnalytics::ConfigurationObserver>) { 291 + if (verbose) 292 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 293 + }; 294 + 295 + void CoreAnalytics::Client::handleConfigurationChange_sync(applesauce::xpc::dict const&) { 296 + if (verbose) 297 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 298 + }; 299 + 300 + void CoreAnalytics::Client::sendAwdQueriableMetricsList_sync() { 301 + if (verbose) 302 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 303 + }; 304 + 305 + CoreAnalytics::Client* CoreAnalytics::Client::get() { 306 + if (verbose) 307 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 308 + return NULL; 309 + }; 310 + 311 + void CoreAnalytics::Client::init() { 312 + if (verbose) 313 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 314 + }; 315 + 316 + CoreAnalytics::Client::Client() { 317 + if (verbose) 318 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 319 + }; 320 + 321 + CoreAnalytics::Client::~Client() { 322 + if (verbose) 323 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 324 + }; 325 + 326 + void CoreAnalytics::Client::sendXpcMessage(applesauce::xpc::dict) const { 327 + if (verbose) 328 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 329 + }; 330 + 331 + bool CoreAnalytics::Client::isEventWhitelisted(std::string_view) const { 332 + if (verbose) 333 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 334 + return false; 335 + }; 336 + 337 + bool CoreAnalytics::Client::isAwdMetricWhitelisted(unsigned int) const { 338 + if (verbose) 339 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 340 + return false; 341 + }; 342 + 343 + bool CoreAnalytics::Client::hasConfig() const { 344 + if (verbose) 345 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 346 + return false; 347 + }; 348 + 349 + extern "C" { 350 + 351 + void analytics_cancel_queried_awd_metric(char const*, xpc_object_t) { 352 + if (verbose) 353 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 354 + }; 355 + 356 + bool analytics_is_awd_metric_enabled(unsigned int) { 357 + if (verbose) 358 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 359 + return false; 360 + }; 361 + 362 + bool analytics_is_event_used(char const*) { 363 + if (verbose) 364 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 365 + return false; 366 + }; 367 + 368 + void analytics_mark_awd_queriable(unsigned int) { 369 + if (verbose) 370 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 371 + }; 372 + 373 + void analytics_send_awd_metric(unsigned int, void const*, unsigned long) { 374 + if (verbose) 375 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 376 + }; 377 + 378 + void analytics_send_awd_trigger(char const*, unsigned int, unsigned int, unsigned int, void const*, unsigned long) { 379 + if (verbose) 380 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 381 + }; 382 + 383 + void analytics_send_event(char const*, xpc_object_t) { 384 + if (verbose) 385 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 386 + }; 387 + 388 + void analytics_send_event_lazy(char const*, xpc_object_t) { 389 + if (verbose) 390 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 391 + }; 392 + 393 + void analytics_send_queried_awd_metric(char const*, unsigned int, xpc_object_t, void const*, unsigned long) { 394 + if (verbose) 395 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 396 + }; 397 + 398 + void analytics_send_queried_awd_trigger(char const*, unsigned int, unsigned int, xpc_object_t, void const*, unsigned long) { 399 + if (verbose) 400 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 401 + }; 402 + 403 + void analytics_set_awd_query_callback(void(^)(unsigned int, char const*, void*)) { 404 + if (verbose) 405 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 406 + }; 407 + 408 + void analytics_set_callback_for_queried_event(char const*, void(^)()) { 409 + if (verbose) 410 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 411 + }; 412 + 413 + void analytics_set_callback_for_queried_event_with_queue(char const*, void*, void(^)()) { 414 + if (verbose) 415 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 416 + }; 417 + 418 + void report_locale_prefs_to_analyticsd() { 419 + if (verbose) 420 + std::cerr << "STUB: " << __PRETTY_FUNCTION__ << " called" << std::endl; 421 + }; 422 + 423 + };
+1
src/private-frameworks/include/CoreAnalytics
··· 1 + ../CoreAnalytics/include/CoreAnalytics