aboutsummaryrefslogtreecommitdiff
path: root/service/src/com/android/car/CarLog.java
blob: 97734a8540b00388de0adec0bf52b95a0d011a49 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
/*
 * Copyright (C) 2015 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.android.car;

public class CarLog {
    private static final int MAX_TAG_LEN = 23;

    public static final String TAG_AM = "CAR.AM";
    public static final String TAG_APP_FOCUS = "CAR.APP_FOCUS";
    public static final String TAG_AUDIO = "CAR.AUDIO";
    public static final String TAG_CABIN = "CAR.CABIN";
    public static final String TAG_CAMERA = "CAR.CAMERA";
    public static final String TAG_CAN_BUS = "CAR.CAN_BUS";
    public static final String TAG_CLUSTER = "CAR.CLUSTER";
    public static final String TAG_HAL = "CAR.HAL";
    public static final String TAG_HVAC = "CAR.HVAC";
    public static final String TAG_VENDOR_EXT = "CAR.VENDOR_EXT";
    public static final String TAG_INFO = "CAR.INFO";
    public static final String TAG_INPUT = "CAR.INPUT";
    public static final String TAG_MONITORING = "CAR.MONITORING";
    public static final String TAG_NAV = "CAR.NAV";
    public static final String TAG_PACKAGE = "CAR.PACKAGE";
    public static final String TAG_POWER = "CAR.POWER";
    public static final String TAG_PROJECTION = "CAR.PROJECTION";
    public static final String TAG_PROPERTY = "CAR.PROPERTY";
    public static final String TAG_SENSOR = "CAR.SENSOR";
    public static final String TAG_SERVICE = "CAR.SERVICE";
    public static final String TAG_SYS = "CAR.SYS";
    public static final String TAG_TEST = "CAR.TEST";
    public static final String TAG_DIAGNOSTIC = "CAR.DIAGNOSTIC";
    public static final String TAG_STORAGE = "CAR.STORAGE";

    public static String concatTag(String tagPrefix, Class clazz) {
        String tag = tagPrefix + "." + clazz.getSimpleName();
        if (tag.length() > MAX_TAG_LEN) {
            tag = tag.substring(0, MAX_TAG_LEN);
        }
        return tag;
    }
}