summaryrefslogtreecommitdiff
path: root/include/modules/chanserv/entrymsg.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/modules/chanserv/entrymsg.h')
-rw-r--r--include/modules/chanserv/entrymsg.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/include/modules/chanserv/entrymsg.h b/include/modules/chanserv/entrymsg.h
new file mode 100644
index 000000000..2672f8ac0
--- /dev/null
+++ b/include/modules/chanserv/entrymsg.h
@@ -0,0 +1,37 @@
+/*
+ *
+ * (C) 2003-2025 Anope Team
+ * Contact us at team@anope.org
+ *
+ * Please read COPYING and README for further details.
+ */
+
+#pragma once
+
+struct EntryMsg
+{
+ Anope::string chan;
+ Anope::string creator;
+ Anope::string message;
+ time_t when;
+
+ virtual ~EntryMsg() = default;
+protected:
+ EntryMsg() = default;
+};
+
+struct EntryMessageList
+ : Serialize::Checker<std::vector<EntryMsg *> >
+{
+protected:
+ EntryMessageList() : Serialize::Checker<std::vector<EntryMsg *> >("EntryMsg") { }
+
+public:
+ virtual ~EntryMessageList()
+ {
+ for (unsigned i = (*this)->size(); i > 0; --i)
+ delete (*this)->at(i - 1);
+ }
+
+ virtual EntryMsg *Create() = 0;
+};