1 /* 2 * Copyright (C) 2019 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 #include <memory> 18 #include <stats_event.h> 19 20 namespace android { 21 namespace mediametrics { 22 class Item; 23 } 24 25 using statsd_pusher = bool (const std::shared_ptr<const mediametrics::Item>& item, 26 const std::shared_ptr<mediametrics::StatsdLog>& statsdLog); 27 // component specific dumpers 28 extern statsd_pusher statsd_audiopolicy; 29 extern statsd_pusher statsd_audiorecord; 30 extern statsd_pusher statsd_audiothread; 31 extern statsd_pusher statsd_audiotrack; 32 extern statsd_pusher statsd_codec; 33 extern statsd_pusher statsd_extractor; 34 extern statsd_pusher statsd_mediaparser; 35 36 extern statsd_pusher statsd_nuplayer; 37 extern statsd_pusher statsd_recorder; 38 extern statsd_pusher statsd_mediadrm; 39 extern statsd_pusher statsd_drmmanager; 40 41 using statsd_puller = bool (const std::shared_ptr<const mediametrics::Item>& item, 42 AStatsEventList *, const std::shared_ptr<mediametrics::StatsdLog>& statsdLog); 43 // component specific pullers 44 extern statsd_puller statsd_mediadrm_puller; 45 46 bool dump2Statsd(const std::shared_ptr<const mediametrics::Item>& item, 47 const std::shared_ptr<mediametrics::StatsdLog>& statsdLog); 48 bool dump2Statsd(const std::shared_ptr<const mediametrics::Item>& item, AStatsEventList* out, 49 const std::shared_ptr<mediametrics::StatsdLog>& statsdLog); 50 } // namespace android 51