package com.trade.common.utils;

public class DataScopeContext {
    private static final ThreadLocal<String> PERMISSION_SQL = new ThreadLocal<String>();

    public static void setPermissionSql(String permissionSql) {
        PERMISSION_SQL.set(permissionSql);
    }

    public static String getPermissionSql() {
        return PERMISSION_SQL.get();
    }

    public static void clear() {
        // 清理线程变量
        PERMISSION_SQL.remove();
    }
}
