• If you are citizen of an European Union member nation, you may not use this service unless you are at least 16 years old.

  • Stop wasting time looking for files and revisions. Connect your Gmail, DriveDropbox, and Slack accounts and in less than 2 minutes, Dokkio will automatically organize all your file attachments. Learn more and claim your free account.


Using Log to debug applications

Page history last edited by Will 9 years, 3 months ago

Log is an API for sending log output

Log can help you debug your code or provide the end user information on what is going on.


There are three versions of the log routine, they are: Log.v(), Log.i(), and Log.d().


Log.v() - Is used for verbose logging

Log.i() - Is used for general information notification

Log.d() - Is used for error checking and debugging typically used during application development



     Log.v(String tag, String msg);

     Log.i(String tag, String msg);

     Log.d(String tag, String msg);



tag Used to identify the source of a log message. It usually identifies the class or activity where the log call occurs.
msg The message you would like logged.



       String TAG = "SkeletonActivity";


       Log.v(TAG, "Hello");
       Log.i(TAG, "Hello");
       Log.d(TAG, "Hello");


$ adb.exe logcat *


Comments (0)

You don't have permission to comment on this page.