1 import android.util.Log; 2 3 /** 4 * @author orca 5 * Log工具类,方便打印log 6 * 封装了info,debug,error,方法 7 * 添加了分隔线 8 */ 9 public class LogUtil { 10 private static String TAG = "ace"; 11 12 public static void getInfoLog(String msg) { 13 Log.i(TAG, msg); 14 } 15 16 public static void getDebugLog(String msg) { 17 Log.d(TAG, msg); 18 } 19 20 public static void getErrorLog(String msg) { 21 Log.i(TAG, msg); 22 } 23 24 public static void getDevider() { 25 Log.d(TAG, "************************************"); 26 } 27 28 }
原文:http://www.cnblogs.com/jinglecode/p/4358318.html