Commit 45832d6f by patpat

增加log工具类

parent 3b01dcc4
package com.bgycc.smartcanteen.util;
import android.util.Log;
public class LogUtil {
private static boolean sEnable = false;
public static void setEnable(boolean enable) {
sEnable = enable;
}
public static void i(String tag, String log) {
if (!sEnable) return;
Log.i(tag, log);
}
public static void d(String tag, String log) {
if (!sEnable) return;
Log.d(tag, log);
}
public static void w(String tag, String log) {
if (!sEnable) return;
Log.w(tag, log);
}
public static void e(String tag, String log) {
if (!sEnable) return;
Log.e(tag, log);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment