import '../../../../core/errors/result.dart';
import '../../domain/entities/chat.dart';
import '../../domain/entities/message.dart';

abstract class ChatLocalDataSource {
  Future<Result<List<Chat>>> getCachedChats();
  Future<Result<void>> cacheChats(List<Chat> chats);
  Future<Result<Chat>> getChatFromCache(String chatId);
  Future<Result<void>> cacheChat(Chat chat);
  Future<Result<List<Message>>> getMessagesFromCache(String chatId);
  Future<Result<void>> cacheMessages(String chatId, List<Message> messages);
  Future<Result<void>> clearCache();
}
