sharp-chat/SharpChat/EventStorage/IEventStorage.cs
flashwave e17aed7c25
Switched to Index brand random Snowflakes instead of SharpIds.
If you were still handling message ids as integers in an environment that can't handle signed 64-bit integers you're going to be having a fun time after this update!
2025-04-25 20:05:57 +00:00

20 lines
690 B
C#

namespace SharpChat.EventStorage {
public interface IEventStorage {
void AddEvent(
long id,
string type,
string channelName,
long senderId,
string senderName,
ChatColour senderColour,
int senderRank,
string senderNick,
ChatUserPermissions senderPerms,
object? data = null,
StoredEventFlags flags = StoredEventFlags.None
);
void RemoveEvent(StoredEventInfo evt);
StoredEventInfo? GetEvent(long seqId);
IEnumerable<StoredEventInfo> GetChannelEventLog(string channelName, int amount = 20, int offset = 0);
}
}