Correct Processing of log information in android projects, androidlog

Source: Internet
Author: User

Correct Processing of log information in android projects, androidlog

In our project, debugging programs usually involve debugging or logging, especially reading json data, however, when the project goes online, the log information cannot be printed out. You can download some bad apps and connect to eclipse to see the request url or returned data, if you come across some skilled people, do you know what to do? You know, below is a log class, which is usually used in projects as a tool class,

public class LogUitl {private static final boolean IS_OPEN = true;private static final String TAG = "LogUitl";public static void e(String msg){Log.e(TAG, msg);}public static void d(String msg){Log.e(TAG, msg);}public static void i(String msg){Log.e(TAG, msg);}public static void w(String msg){Log.e(TAG, msg);}public static void v(String msg){Log.e(TAG, msg);}}




Information captured by LogCat during Android project debugging: yigaoPush

The five letters in the upper-right corner of qLogCat indicate five different types of log information, and their levels increase in turn
[V]: Verbose information [D]: Debug information
[I]: Announcement (Info) information [W]: Warning (Warn) Information
[E]: Error Information
N use Log. v (), Log. d (), Log. I (), Log. w () and Log. e () Five functions in the program set "log point" n when the program runs to "log point, the Application log information is sent to LogCat. n is used to determine whether the "log point" information is consistent with the expected content. n is used to determine whether the program has an error qLog. v () is used to record detailed information, Log. d () is used to record debugging information, Log. I () is used to record announcement information, Log. w () is used to record warning information, Log. e () is used to record communication error information

LogCat provides the "filter" function. The "+" and "-" signs in the upper right corner are used to add and delete filters. You can filter the displayed log Content Based on the Tag of the log information, the process ID (Pid) of the generated log, or the information Level (Level ).

YigaoPush is your tag.
Final static String TAG = "yigaoPush ";
Log. v (TAG ,"............. ");


For the log error information of the android program, I am a beginner. I have not changed a new android project.

Exception in thread "main" java. lang. SecurityException: unable to locate logon Configuration
At com. sun. security. auth. login. ConfigFile. <init> (ConfigFile. java: 97)
He said he couldn't find the file. You can see if the path is incorrect elsewhere,
Your questions and answers are not clear enough. You may have to guess this and it is very difficult to solve!
You should give some code or take a look at the resource file and xml next time!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.