Package org.openmeetings.app.conference.session

Examples of org.openmeetings.app.conference.session.RoomClient


  public Boolean deleteWhiteboard(Long whiteBoardId) {
    try {
      IConnection current = Red5.getConnectionLocal();
      String streamid = current.getClient().getId();
      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);
      Long room_id = currentClient.getRoom_id();

      WhiteboardObjectList whiteboardObjectList = this.whiteBoardObjectListManagerById
          .getWhiteBoardObjectListByRoomId(room_id);

      for (Iterator<Long> iter = whiteboardObjectList
View Full Code Here


  public WhiteboardObjectList getRoomItemsBy() {
    try {
      IConnection current = Red5.getConnectionLocal();
      String streamid = current.getClient().getId();
      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);
      Long room_id = currentClient.getRoom_id();

      log.debug("getRoomItems: " + room_id);
      WhiteboardObjectList whiteboardObjectList = this.whiteBoardObjectListManagerById
          .getWhiteBoardObjectListByRoomId(room_id);
View Full Code Here

      String swfURL = "";
      if (conn.getConnectParams().get("swfUrl") != null) {
        swfURL = conn.getConnectParams().get("swfUrl").toString();
      }

      RoomClient rcm = this.clientListManager.addClientListItem(streamId,
          conn.getScope().getName(), conn.getRemotePort(),
          conn.getRemoteAddress(), swfURL, isAVClient);

      // Log the User
      conferenceLogDao.addConferenceLog("ClientConnect",
          rcm.getUser_id(), streamId, null, rcm.getUserip(),
          rcm.getScope(), rcm.getExternalUserId(),
          rcm.getExternalUserType(), rcm.getMail(),
          rcm.getFirstname(), rcm.getLastname());

    } catch (Exception err) {
      log.error("roomJoin", err);
    }
    return true;
View Full Code Here

  public Boolean setCanDraw(String SID, String publicSID, boolean canDraw) {
    try {

      IConnection current = Red5.getConnectionLocal();
      String streamid = current.getClient().getId();
      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);

      Long users_id = sessionManagement.checkSession(SID);
      Long user_level = userManagement.getUserLevelByID(users_id);

      if (authLevelManagement.checkUserLevel(user_level)) {

        if (currentClient.getIsMod()) {
          RoomClient rcl = this.clientListManager
              .getClientByPublicSID(publicSID, false);

          if (rcl != null) {
            rcl.setCanDraw(canDraw);
            this.clientListManager.updateClientByStreamId(
                rcl.getStreamid(), rcl);

            HashMap<Integer, Object> newMessage = new HashMap<Integer, Object>();
            newMessage.put(0, "updateDrawStatus");
            newMessage.put(1, rcl);
            this.scopeApplicationAdapter
View Full Code Here

  public Boolean setCanShare(String SID, String publicSID, boolean canShare) {
    try {

      IConnection current = Red5.getConnectionLocal();
      String streamid = current.getClient().getId();
      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);

      Long users_id = sessionManagement.checkSession(SID);
      Long user_level = userManagement.getUserLevelByID(users_id);

      if (authLevelManagement.checkUserLevel(user_level)) {

        if (currentClient.getIsMod()) {
          RoomClient rcl = this.clientListManager
              .getClientByPublicSID(publicSID, false);

          if (rcl != null) {
            rcl.setCanShare(canShare);
            this.clientListManager.updateClientByStreamId(
                rcl.getStreamid(), rcl);

            HashMap<Integer, Object> newMessage = new HashMap<Integer, Object>();
            newMessage.put(0, "updateDrawStatus");
            newMessage.put(1, rcl);
            this.scopeApplicationAdapter
View Full Code Here

  public Boolean setCanRemote(String SID, String publicSID, boolean canRemote) {
    try {

      IConnection current = Red5.getConnectionLocal();
      String streamid = current.getClient().getId();
      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);

      Long users_id = sessionManagement.checkSession(SID);
      Long user_level = userManagement.getUserLevelByID(users_id);

      if (authLevelManagement.checkUserLevel(user_level)) {

        if (currentClient.getIsMod()) {
          RoomClient rcl = this.clientListManager
              .getClientByPublicSID(publicSID, false);

          if (rcl != null) {
            rcl.setCanRemote(canRemote);
            this.clientListManager.updateClientByStreamId(
                rcl.getStreamid(), rcl);

            HashMap<Integer, Object> newMessage = new HashMap<Integer, Object>();
            newMessage.put(0, "updateDrawStatus");
            newMessage.put(1, rcl);
            this.scopeApplicationAdapter
View Full Code Here

    public Boolean setCanGiveAudio(String SID, String publicSID, boolean canGiveAudio) {
    try {
            log.debug("[setCanGiveAudio] " + SID + ", " + publicSID + ", " + canGiveAudio);
      IConnection current = Red5.getConnectionLocal();
      String streamid = current.getClient().getId();
      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);

      Long users_id = sessionManagement.checkSession(SID);
      Long user_level = userManagement.getUserLevelByID(users_id);

      if (authLevelManagement.checkUserLevel(user_level)) {
        if (currentClient.getIsMod()) {
          RoomClient rcl = this.clientListManager
              .getClientByPublicSID(publicSID, false);

          if (rcl != null) {
            rcl.setCanGiveAudio(canGiveAudio);
                this.clientListManager.updateClientByStreamId(
                        rcl.getStreamid(), rcl);

                HashMap<Integer, Object> newMessage = new HashMap<Integer, Object>();
                newMessage.put(0, "updateGiveAudioStatus");
                newMessage.put(1, rcl);
                this.scopeApplicationAdapter
View Full Code Here

  public synchronized Map screenSharerAction(Map map) {
    try {

      IConnection current = Red5.getConnectionLocal();

      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(current.getClient().getId());

      Map returnMap = new HashMap();
      returnMap.put("result", "stopAll");

      log.debug("-----------  ");

      if (currentClient != null) {

        if (Boolean.valueOf(map.get("stopStreaming").toString())) {
          log.debug("start streamPublishStart Is Screen Sharing -- Stop ");
         
          //Send message to all users
          syncMessageToCurrentScope("stopRed5ScreenSharing", currentClient, false);

          if (currentClient.isStartRecording()) {
            returnMap.put("result", "stopSharingOnly");
          }

          currentClient.setStartStreaming(false);
          currentClient.setScreenPublishStarted(false);

          clientListManager.updateClientByStreamId(
              currentClient.getStreamid(), currentClient);
        }
        if (Boolean.valueOf(map.get("stopRecording").toString())) {
          if (currentClient.isStartStreaming()) {
            returnMap.put("result", "stopRecordingOnly");
          }
         
          //Send message to all users
          syncMessageToCurrentScope("stopRecordingMessage", currentClient, false);

          flvRecorderService.stopRecordAndSave(
              current.getScope(), currentClient, null);

          currentClient.setStartRecording(false);
          currentClient.setIsRecording(false);

          clientListManager.updateClientByStreamId(
              currentClient.getStreamid(), currentClient);
        }
        if (Boolean.valueOf(map.get("stopPublishing").toString())) {
          streamPublishingStop();
          if (currentClient.getIsScreenClient() && currentClient.isStartStreaming()) {
            returnMap.put("result", "stopPublishingOnly");
          }
        }
      }
      return returnMap;
View Full Code Here

  public WhiteboardSyncLockObject startNewSyncprocess() {
    try {

      IConnection current = Red5.getConnectionLocal();
      String streamid = current.getClient().getId();
      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);
      Long room_id = currentClient.getRoom_id();

      WhiteboardSyncLockObject wSyncLockObject = new WhiteboardSyncLockObject();
      wSyncLockObject.setAddtime(new Date());
      wSyncLockObject.setPublicSID(currentClient.getPublicSID());
      wSyncLockObject.setInitialLoaded(true);

      Map<String, WhiteboardSyncLockObject> syncListRoom = this.whiteBoardObjectListManager
          .getWhiteBoardSyncListByRoomid(room_id);

      wSyncLockObject.setCurrentLoadingItem(true);
      wSyncLockObject.setStarttime(new Date());

      syncListRoom.put(currentClient.getPublicSID(), wSyncLockObject);
      this.whiteBoardObjectListManager.setWhiteBoardSyncListByRoomid(
          room_id, syncListRoom);
     
      //Sync to clients
      this.scopeApplicationAdapter.syncMessageToCurrentScope("sendSyncFlag", wSyncLockObject, true);
View Full Code Here

  public void sendCompletedSyncEvent() {
    try {

      IConnection current = Red5.getConnectionLocal();
      String streamid = current.getClient().getId();
      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);
      Long room_id = currentClient.getRoom_id();

      Map<String, WhiteboardSyncLockObject> syncListRoom = this.whiteBoardObjectListManager
          .getWhiteBoardSyncListByRoomid(room_id);

      WhiteboardSyncLockObject wSyncLockObject = syncListRoom
          .get(currentClient.getPublicSID());

      if (wSyncLockObject == null) {
        log.error("WhiteboardSyncLockObject not found for this Client "
            + syncListRoom);
        return;
      } else if (!wSyncLockObject.isCurrentLoadingItem()) {
        log.warn("WhiteboardSyncLockObject was not started yet "
            + syncListRoom);
        return;
      } else {
        syncListRoom.remove(currentClient.getPublicSID());
        this.whiteBoardObjectListManager.setWhiteBoardSyncListByRoomid(
            room_id, syncListRoom);

        int numberOfInitial = this
            .getNumberOfInitialLoaders(syncListRoom);
View Full Code Here

TOP

Related Classes of org.openmeetings.app.conference.session.RoomClient

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.