Created
December 4, 2014 21:47
-
-
Save mustafa01ali/027c79dcd6c917816e08 to your computer and use it in GitHub Desktop.
Simple logging util for Android
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.util.Log; | |
/** | |
* @author Mustafa Ali | |
*/ | |
public class L { | |
private static final String LOG_TAG = "MyAwesomeApp"; | |
private static final boolean IS_LOGGING_ENABLED = true; | |
public static void d(String msg) { | |
if (IS_LOGGING_ENABLED) { | |
Log.d(LOG_TAG, msg); | |
} | |
} | |
public static void e(String msg, Throwable t) { | |
if (IS_LOGGING_ENABLED) { | |
Log.e(LOG_TAG, msg, t); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment