package com.jeesharp.business.modules.member.service;

import com.jeesharp.business.modules.member.entity.MemberFavorite;
import com.jeesharp.framework.pojo.Page;

import java.util.List;
import java.util.Optional;

/**
 * 会员统一收藏领域服务接口。
 *
 * @author jeesharp
 * @since 2026-05-20
 */
public interface MemberFavoriteService {

    Optional<MemberFavorite> findActive(String memberId, String bizType, String bizId);

    boolean exists(String memberId, String bizType, String bizId);

    void saveFavorite(MemberFavorite favorite);

    void removeFavorite(String memberId, String bizType, String bizId);

    Page<MemberFavorite> findPageByMember(Page<MemberFavorite> page, String memberId, String bizType);

    List<MemberFavorite> listByMember(String memberId, String bizType, int limit);

    long countByMemberId(String memberId);
}
