Java tutorial
//package com.java2s; import android.util.Log; public class Main { public static boolean debug = true; public final static void d(String tag, String msg) { if (debug) { Log.d(tag, msg); } } public final static void d(String tag, String msg, Throwable tr) { if (debug) { Log.d(tag, msg, tr); } } }