Example usage for android.util Log i

List of usage examples for android.util Log i

Introduction

In this page you can find the example usage for android.util Log i.

Prototype

public static int i(String tag, String msg) 

Source Link

Document

Send an #INFO log message.

Usage

From source file:Main.java

public static void v(String tag, String msg) {
    if (isDebug)
        Log.i(tag, msg);
}

From source file:Main.java

public static void e(String tag, String msg) {
    if (isDebug)
        Log.i(tag, msg);
}

From source file:Main.java

public static void d(String tag, String msg) {
    if (isDebug)
        Log.i(tag, msg);
}

From source file:Main.java

public static String getAbsPath(File file) {
    String path = null;//from w  w  w.  j a  va 2  s  .c  o m
    try {
        path = file.getCanonicalPath();
    } catch (IOException e) {
        path = file.getAbsolutePath();
        Log.i("[explorer():]", e.toString());
    }

    return path;
}

From source file:Main.java

public static void i(String text) {
    if (debug) {
        Log.i(TAG, text);
    }
}

From source file:Main.java

public static void log(Exception e) {
    //        _log(message);
    if (e == null) {
        return;//from  w w  w  . ja  v a2 s . c om
    }
    e.printStackTrace();
    Log.i("JC-LOG", "" + e.getMessage());
}

From source file:Main.java

public static void makeRootDirectory(String filePath) {
    File file = null;//w w w.j  av  a  2s  .co m
    try {
        file = new File(filePath);
        if (!file.exists()) {
            file.mkdirs();
        }
    } catch (Exception e) {
        Log.i("error:", e + "");
    }
}

From source file:Main.java

public static void sleep(double sec) throws Exception {
    Log.i(TAG, String.format("Sleep %f sceond(s) forcibly", sec));

    Thread.sleep((long) (sec * 1000));
}

From source file:Main.java

public static void i(String message) {

    if (!isLog) {
        return;/*from w  w w .  j a v  a  2  s. c o  m*/
    }
    Log.i("CommonTool", message);

}

From source file:Main.java

public static boolean displayGPSStatus(LocationManager locManager) {
    boolean gps_enabled = false;
    try {/*from   w w w . j a v  a 2  s  .c  o m*/
        gps_enabled = locManager.isProviderEnabled(LocationManager.GPS_PROVIDER);
    } catch (Exception ex) {
        Log.i("GPSStatus", " checking GPSStatus throws error " + ex);
    }
    return gps_enabled;
}