summaryrefslogtreecommitdiff
path: root/matrix-specification/Data/AccountData.php
diff options
context:
space:
mode:
Diffstat (limited to 'matrix-specification/Data/AccountData.php')
-rw-r--r--matrix-specification/Data/AccountData.php23
1 files changed, 23 insertions, 0 deletions
diff --git a/matrix-specification/Data/AccountData.php b/matrix-specification/Data/AccountData.php
new file mode 100644
index 0000000..fa3e4a3
--- /dev/null
+++ b/matrix-specification/Data/AccountData.php
@@ -0,0 +1,23 @@
+<?php
+
+namespace Matrix\Data;
+
+use Matrix\Events\Event;
+
+class AccountData implements \JsonSerializable
+{
+ /**
+ * @param Event[] $events
+ */
+ public function __construct(
+ private array $events
+ )
+ {}
+
+ public function jsonSerialize(): array
+ {
+ return [
+ "events" => $this->events,
+ ];
+ }
+}