Skip to content

Commit 1536e1f

Browse files
chore: create room event presence payload
1 parent afc5f32 commit 1536e1f

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
/*
2+
* Copyright (c) 2023. Smart Operating Block
3+
*
4+
* Use of this source code is governed by an MIT-style
5+
* license that can be found in the LICENSE file or at
6+
* https://opensource.org/licenses/MIT.
7+
*/
8+
9+
package application.presenter.event.model.roomevent.payload;
10+
11+
/**
12+
* Presence payload for {@link application.presenter.event.model.roomevent.RoomEvent}.
13+
*/
14+
public class PresencePayload implements RoomEventPayload {
15+
private final boolean presenceDetected;
16+
17+
/**
18+
* Default constructor.
19+
* @param presenceDetected the presence payload.
20+
*/
21+
public PresencePayload(final boolean presenceDetected) {
22+
this.presenceDetected = presenceDetected;
23+
}
24+
25+
/**
26+
* State if the presence is detected or not.
27+
* @return true if the presence is detected, false otherwise.
28+
*/
29+
public boolean isPresenceDetected() {
30+
return this.presenceDetected;
31+
}
32+
}

0 commit comments

Comments
 (0)