Пример #1
0
 public void joinSession(IEventDispatcher dispatcher) {
   User user = MojaveApplicationData.getSession().getUser();
   if (!users.contains(user)) {
     users.add(user);
     dispatcher.dispatch(new ProjectSessionJoinEvent(sessionId, user), EventScope.UNIVERSAL);
   }
 }
Пример #2
0
 public void leaveSession(IEventDispatcher dispatcher) {
   User user = MojaveApplicationData.getSession().getUser();
   if (users.remove(user))
     dispatcher.dispatch(new ProjectSessionLeaveEvent(sessionId, user), EventScope.UNIVERSAL);
 }