This commit is contained in:
novice.li
2024-02-25 12:18:32 +08:00
commit 439a127799
7 changed files with 233 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
package com.novitechie;
public class StackTraceRule {
public static boolean check() {
RuntimeException e = new RuntimeException();
for (StackTraceElement stackTraceElement : e.getStackTrace()) {
if (stackTraceElement.getFileName() == null) {
return true;
}
}
return false;
}
}