• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2021 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef ARGS_FILTER_H
17 #define ARGS_FILTER_H
18 
19 #include <map>
20 #include <string_view>
21 #include <tuple>
22 
23 #include "args_set.h"
24 #include "double_map.h"
25 #include "filter_base.h"
26 #include "trace_data_cache.h"
27 #include "trace_streamer_filters.h"
28 
29 namespace SysTuning {
30 namespace TraceStreamer {
31 class ArgsFilter : private FilterBase {
32 public:
33     ArgsFilter(TraceDataCache*, const TraceStreamerFilters*);
34     ArgsFilter(const ArgsFilter&) = delete;
35     ArgsFilter& operator=(const ArgsFilter&) = delete;
36     ~ArgsFilter() override;
37     uint32_t NewArgs(const ArgsSet& args);
38     uint32_t AppendArgs(const ArgsSet& args, const size_t argSetId);
39     int count_ = 0;
40 };
41 } // namespace TraceStreamer
42 } // namespace SysTuning
43 #endif // ARGS_FILTER_H
44