package com.trade.client.enterprise.customer.service;

import com.trade.client.enterprise.customer.domain.CustomerUser;

/**
 * @description: 密码服务类
 * @Author: wanglang
 * @Date: 2023/7/27 10:59
 * @Version: 1.0
 */
public interface CustomerPasswordService {

    /**
     * 校验
     * 
     * @param user
     */
    void validate(CustomerUser user);

    /**
     * 密码匹配
     * 
     * @param user
     * @param rawPassword
     * @return
     */
    boolean matches(CustomerUser user, String rawPassword);

    /**
     * 清除登录记录缓存
     * 
     * @param loginName
     */
    void clearLoginRecordCache(String loginName);
}
