Log message
Description
The following code shows how to Log message.
Example
import android.app.Activity;
import android.os.Bundle;
import android.util.Log;
// w w w . ja v a 2 s . c o m
public class MainActivity extends Activity {
private static final String LOG_TAG = "MainActivity";
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
Log.d(LOG_TAG, "Log should be deleted");
}
}
Note
The code above uses the Log.d
method to log debug information.