21 lines
551 B
Java
21 lines
551 B
Java
package xyz.maggioni.ProvaArgo;
|
|
|
|
import org.apache.cordova.LOG;
|
|
|
|
public class PluginLOG {
|
|
public static boolean useCordova = true;
|
|
|
|
public static void i(String tag, String message) {
|
|
if (useCordova) LOG.i(tag, message);
|
|
else System.out.println("INFO (" + tag + "): " + message);
|
|
}
|
|
|
|
public static void e(String tag, String s, Throwable e) {
|
|
if (useCordova) LOG.e(tag, s, e);
|
|
else {
|
|
System.err.println("ERROR (" + tag + "): " + s);
|
|
e.printStackTrace(System.err);
|
|
}
|
|
}
|
|
}
|