-
Notifications
You must be signed in to change notification settings - Fork 5.9k
/
WhiteboardApplication.java
executable file
·119 lines (95 loc) · 3.53 KB
/
WhiteboardApplication.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
/**
* BigBlueButton open source conferencing system - http://www.bigbluebutton.org/
*
* Copyright (c) 2012 BigBlueButton Inc. and by respective authors (see below).
*
* This program is free software; you can redistribute it and/or modify it under the
* terms of the GNU Lesser General Public License as published by the Free Software
* Foundation; either version 3.0 of the License, or (at your option) any later
* version.
*
* BigBlueButton is distributed in the hope that it will be useful, but WITHOUT ANY
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
* PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License along
* with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
*
*/
package org.bigbluebutton.red5.service;
import org.red5.logging.Red5LoggerFactory;
import org.red5.server.adapter.IApplication;
import org.red5.server.api.IClient;
import org.red5.server.api.IConnection;
import org.red5.server.api.scope.IScope;
import org.slf4j.Logger;
import org.bigbluebutton.red5.pubsub.MessagePublisher;
public class WhiteboardApplication implements IApplication {
private static Logger log = Red5LoggerFactory.getLogger(WhiteboardApplication.class, "bigbluebutton");
private MessagePublisher red5BBBInGW;
public void setRed5Publisher(MessagePublisher inGW) {
red5BBBInGW = inGW;
}
@Override
public boolean appConnect(IConnection conn, Object[] params) {
return true;
}
@Override
public void appDisconnect(IConnection conn) {
}
@Override
public boolean appJoin(IClient client, IScope scope) {
return true;
}
@Override
public void appLeave(IClient client, IScope scope) {
}
@Override
public boolean appStart(IScope scope) {
return true;
}
@Override
public void appStop(IScope scope) {
}
@Override
public boolean roomConnect(IConnection connection, Object[] params) {
return true;
}
@Override
public void roomDisconnect(IConnection connection) {
}
@Override
public boolean roomJoin(IClient client, IScope scope) {
return true;
}
@Override
public void roomLeave(IClient client, IScope scope) {
}
@Override
public boolean roomStart(IScope scope) {
return true;
}
@Override
public void roomStop(IScope scope) {
}
public void requestAnnotationHistory(String meetingID, String requesterID, String whiteboardId) {
// Just hardcode as we don't really need it for flash client. (ralam may 7, 2014)
String replyTo = meetingID + "/" + requesterID;
red5BBBInGW.requestWhiteboardAnnotationHistory(meetingID, requesterID, whiteboardId, replyTo);
}
public void sendWhiteboardAnnotation(String meetingID, String requesterID, java.util.Map<String, Object> shape) {
red5BBBInGW.sendWhiteboardAnnotation(meetingID, requesterID, shape);
}
public void clearWhiteboard(String meetingID, String requesterID, String whiteboardId) {
red5BBBInGW.clearWhiteboard(meetingID, requesterID, whiteboardId);
}
public void undoWhiteboard(String meetingID, String requesterID, String whiteboardId) {
red5BBBInGW.undoWhiteboard(meetingID, requesterID, whiteboardId);
}
public void modifyWhiteboardAccess(String meetingID, String requesterID, Boolean multiUser) {
red5BBBInGW.modifyWhiteboardAccess(meetingID, requesterID, multiUser);
}
public void getWhiteboardAccess(String meetingID, String requesterID) {
red5BBBInGW.getWhiteboardAccess(meetingID, requesterID);
}
}