레이블이 Android인 게시물을 표시합니다. 모든 게시물 표시
레이블이 Android인 게시물을 표시합니다. 모든 게시물 표시

2010년 6월 8일 화요일

ddms를 별도로 띄울때 콘솔창 없애기

find_java.bat 파일을 찾는다.
C:\Program Files\android-sdk-windows\tools\lib\find_java.bat

set java_exe=java
아래와 같이 수정
set java_exe=javaw

ddms.bat 파일을 찾는다.
C:\Program Files\android-sdk-windows\tools\ddms.bat

call %java_exe% %java_debug% -Djava.ext.dirs=%javaextdirs% -
아래와 같이 수정
start %java_exe% %java_debug% -Djava.ext.dirs=%javaextdirs% -

2010년 5월 31일 월요일

Android Logging

According to the android documentation you can configure logging on a development device using System Properties. The property to set is log.tag. and it should be set to one of the following values: VERBOSE, DEBUG, INFO, WARN, ERROR, ASSERT, or SUPPRESS. More information on this is available in the documentation for the isLoggable() method.

You can set properties temporarily using the setprop command. For example:

C:\android>adb shell setprop log.tag.MyAppTag WARN
C:\android>adb shell getprop log.tag.MyAppTag WARN

Alternatively, you can specify them in the file '/data/local.prop' as follows:

log.tag.MyAppTag=WARN

This file as read at boot time so you'll need to restart after updating it.

Finally, you can set them programmatically using the System.setProperty() method.

You should use :
if (Log.isLoggable(TAG, Log.VERBOSE)) {
     Log.v(TAG, "my log message");
}