List of usage examples for android.util Log e
public static int e(String tag, String msg)
From source file:Main.java
public static String getPackagNameFromPath(Context context, String path) { PackageInfo pi = context.getPackageManager().getPackageArchiveInfo(path, 0); if (pi == null) { Log.e("null package:", "could not generate package info from path:" + path); return null; }/*from ww w. j a va 2s .c o m*/ return pi.packageName; }
From source file:Main.java
public static void e(String text) { if (debug) { Log.e(TAG, text); } }
From source file:Main.java
/** * error log//from ww w . j av a 2s . com * @param msg log msg */ public static void e(String msg) { if (LOG_ENABLE) { Log.e(TAG, buildMsg(msg)); } }
From source file:Main.java
public static String getVerName(Context context) { String verName = ""; try {/* ww w.j ava2s .c o m*/ verName = context.getPackageManager().getPackageInfo("com.example.t.myapplication", 0).versionName; } catch (Exception e) { Log.e("msg", e.getMessage()); } return verName; }
From source file:Main.java
/** * /* w ww. ja va 2 s . co m*/ * @param filename * @return */ public static long getFileSize(String filename) { File file = new File(filename); if (!file.exists() || !file.isFile()) { Log.e(TAG, "GETFILESIZE: File \"" + filename + "\" doesn\'t exist"); return -1; } return (file.length() / 1024); }
From source file:Main.java
private static void printNotMatchErrorMessage() { String errorMessage = "Please check your ProxyClassName,the " + mCustomProxyClassName + " is not match the rule."; Log.e(TAG, "printNotMatchErrorMessage: " + errorMessage); throw new IllegalArgumentException(errorMessage); }
From source file:Main.java
public static int getVersionCode(Context context) { try {//from w ww.java 2s . co m return context.getPackageManager().getPackageInfo(context.getPackageName(), 0).versionCode; } catch (Exception e) { Log.e(TAG, "Cannot find package and its version info."); return -1; } }
From source file:Main.java
public static void e(String cusPreLogStr, String logStr) { Log.e(TAG, cusPreLogStr + logStr); }
From source file:Main.java
public static void LogPass(boolean pass, String message) { if (pass) {/*from w ww .j a v a2 s .c om*/ PrintLog("PASS -" + message); Log.e("Test", "PASS -" + message); } else { PrintLog("-FAILE -" + message); Log.e("Test", "-FAILE -" + message); } }
From source file:Main.java
public static void print(Matrix matrix) { float scale = getValue(matrix, Matrix.MSCALE_X); float moveX = getValue(matrix, Matrix.MTRANS_X); float moveY = getValue(matrix, Matrix.MTRANS_Y); Log.e("[MatrixUtils]", "matrix: { moveX: " + moveX + ", moveY: " + moveY + ", scale: " + scale + " }"); }