package cn.novalon.gym.manage.notify.core.service;

import cn.novalon.gym.manage.common.dto.PageRequest;
import cn.novalon.gym.manage.common.dto.PageResponse;
import cn.novalon.gym.manage.notify.core.domain.SysUserMessage;
import reactor.core.publisher.Flux;
import reactor.core.publisher.Mono;

public interface ISysUserMessageService {

    Flux<SysUserMessage> getMessagesByUser(Long userId);

    Mono<Long> getUnreadCount(Long userId);

    Flux<SysUserMessage> getUnreadMessages(Long userId);

    Mono<PageResponse<SysUserMessage>> getMessagesByUserPage(Long userId, PageRequest pageRequest);

    Mono<PageResponse<SysUserMessage>> getUnreadMessagesPage(Long userId, PageRequest pageRequest);

    Mono<Long> markAllAsRead(Long userId);

    Mono<SysUserMessage> createMessage(SysUserMessage message);

    Mono<SysUserMessage> markAsRead(Long id);

    Mono<Void> deleteMessage(Long id);
}