@@ -40,6 +40,13 @@ import java.util.function.Supplier;
public class ThreadLocalUtils {
private static final ThreadLocal<Map<String, Object>> local = ThreadLocal.withInitial(HashMap::new);
+ /**
+ * @return threadLocal中的全部值
+ */
+ public static Map<String, Object> getAll(){
+ return local.get();
+ }
+
/**
* 设置一个值到ThreadLocal
*