Skip to content

Commit

Permalink
Change logger method name
Browse files Browse the repository at this point in the history
  • Loading branch information
peiwen.liu committed Apr 15, 2020
1 parent cd6407f commit 7d4a7bd
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions pwlogger/src/main/java/cn/qd/peiwen/pwlogger/PWLogger.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,61 +28,61 @@ private static StackTraceElement getCallerStackTraceElement() {
return Thread.currentThread().getStackTrace()[4];
}

public static void d(String content) {
public static void dubug(String content) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.debug(tag + "->" + content);
}

public static void d(Throwable throwable) {
public static void dubug(Throwable throwable) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.debug(tag, throwable);
}

public static void e(String content) {
public static void error(String content) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.error(tag + "->" + content);
}

public static void e(Throwable throwable) {
public static void error(Throwable throwable) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.error(tag, throwable);
}

public static void f(String content) {
public static void fatal(String content) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.fatal(tag + "->" + content);
}

public static void f(Throwable throwable) {
public static void fatal(Throwable throwable) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.fatal(tag, throwable);
}

public static void i(String content) {
public static void info(String content) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.info(tag + "->" + content);
}

public static void i(Throwable throwable) {
public static void info(Throwable throwable) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.info(tag, throwable);
}

public static void w(String content) {
public static void warn(String content) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.warn(tag + "->" + content);
}

public static void w(Throwable throwable) {
public static void warn(Throwable throwable) {
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
logger.warn(tag, throwable);
Expand Down

0 comments on commit 7d4a7bd

Please sign in to comment.