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#ifndef HIDUMPER_SERVICES_DUMPER_CONSTANT_H
16#define HIDUMPER_SERVICES_DUMPER_CONSTANT_H
17
18#include <string>
19#include <vector>
20#include <iostream>
21#include <memory>
22
23namespace OHOS {
24namespace HiviewDFX {
25enum DumperConstant {
26    NONE,
27    GROUP,        // group
28    DUMPER_BEGIN, // dumper begin
29    CPU_DUMPER,
30    FILE_DUMPER,
31    ENV_PARAM_DUMPER,
32    CMD_DUMPER,
33    PROPERTIES_DUMPER,
34    API_DUMPER,
35    LIST_DUMPER,
36    VERSION_DUMPER,
37    SA_DUMPER,
38    MEMORY_DUMPER,
39    JSHEAP_MEMORY_DUMPER,
40    STACK_DUMPER,
41    TRAFFIC_DUMPER,
42    IPC_STAT_DUMPER,
43    DUMPER_END,   // dumper end
44    FILTER_BEGIN, // filter begin
45    COLUMN_ROWS_FILTER,
46    FILE_FORMAT_DUMP_FILTER,
47    FILTER_END,   // filter end
48    OUTPUT_BEGIN, // output begin
49    STD_OUTPUT,
50    FILE_OUTPUT,
51    FD_OUTPUT,
52    ZIP_OUTPUT,
53    OUTPUT_END,  // output end
54    LEVEL_BEGIN, // level begin
55    LEVEL_NONE,
56    LEVEL_MIDDLE,
57    LEVEL_HIGH,
58    LEVEL_ALL,
59    LEVEL_END,       // level end
60    GROUPTYPE_BEGIN, // group type begin
61    GROUPTYPE_PID,   // pid of group type
62    GROUPTYPE_CPUID, // cpuid of group type
63    GROUPTYPE_END,   // group type end
64    LOOP,
65};
66
67const std::string LOG_DEFAULT = "log.txt";
68const std::string ZIP_FILEEXT = "zip";
69const std::string ZIP_FOLDER = "/data/log/hidumper/";
70
71const std::string RELEASE_MODE = "Release";
72} // namespace HiviewDFX
73} // namespace OHOS
74#endif // HIDUMPER_SERVICES_DUMPER_CONSTANT_H
75