package com.ruoyi.web.modules.category.support;

/**
 * 商家端当前店铺上下文
 */
public final class SellerShopContext
{
    private static final ThreadLocal<Long> SHOP_ID = new ThreadLocal<>();

    private SellerShopContext()
    {
    }

    public static void setShopId(Long shopId)
    {
        SHOP_ID.set(shopId);
    }

    public static Long getShopId()
    {
        return SHOP_ID.get();
    }

    public static void clear()
    {
        SHOP_ID.remove();
    }
}
