@Test public void currentClassMethod() { assertEquals("com.baidu.unbiz.common.RuntimeUtilTest.currentClassMethod", RuntimeUtil.currentClassMethod()); }
public static String currentClassMethod() { StackTraceElement[] ste = new Exception().getStackTrace(); int ndx = (ste.length > 1) ? 1 : 0; StackTraceElement element = new Exception().getStackTrace()[ndx]; return element.getClassName() + "." + element.getMethodName(); }
RuntimeUtil { public static String currentClassMethod() { StackTraceElement[] ste = new Exception().getStackTrace(); int ndx = (ste.length > 1) ? 1 : 0; StackTraceElement element = new Exception().getStackTrace()[ndx]; return element.getClassName() + "." + element.getMethodName(); } }
RuntimeUtil { public static String currentClassMethod() { StackTraceElement[] ste = new Exception().getStackTrace(); int ndx = (ste.length > 1) ? 1 : 0; StackTraceElement element = new Exception().getStackTrace()[ndx]; return element.getClassName() + "." + element.getMethodName(); }  }
RuntimeUtil { public static String currentClassMethod() { StackTraceElement[] ste = new Exception().getStackTrace(); int ndx = (ste.length > 1) ? 1 : 0; StackTraceElement element = new Exception().getStackTrace()[ndx]; return element.getClassName() + "." + element.getMethodName(); }  static String currentClassMethod(); static String currentMethodName(); static String currentClassName(); static String currentNamespace(); static String classLocation(Class<?> clazz); static String classLocation(); }
RuntimeUtil { public static String currentClassMethod() { StackTraceElement[] ste = new Exception().getStackTrace(); int ndx = (ste.length > 1) ? 1 : 0; StackTraceElement element = new Exception().getStackTrace()[ndx]; return element.getClassName() + "." + element.getMethodName(); }  static String currentClassMethod(); static String currentMethodName(); static String currentClassName(); static String currentNamespace(); static String classLocation(Class<?> clazz); static String classLocation();  }