Package org.apache.openmeetings.persistence.beans.room

Examples of org.apache.openmeetings.persistence.beans.room.Room


  }

  public Room getRoomWithCurrentUsersById(long user_level, long rooms_id) {
    try {
      if (authLevelUtil.checkUserLevel(user_level)) {
        Room room = roomDao.get(rooms_id);

        if (room != null) {
          room.setCurrentusers(sessionManager.getClientListByRoom(room.getRooms_id()));

          return room;
        }
      }
    } catch (Exception ex2) {
View Full Code Here


     * Returns number of SIP conference participants
     * @param rooms_id id of room
     * @return number of participants
     */
    public Integer getSipConferenceMembersNumber(Long rooms_id) {
      Room r = roomDao.get(rooms_id);
      return r == null || r.getConfno() == null ? null : sipDao.countUsers(r.getConfno());
    }
View Full Code Here

      , boolean filesOpened, boolean autoVideoSelect, boolean sipEnabled) {

    try {
      if (authLevelUtil.checkAdminLevel(user_level)) {

        Room r = new Room();
        r.setName(name);
        r.setComment(comment);
        r.setStarttime(new Date());
        r.setNumberOfPartizipants(numberOfPartizipants);
        r.setRoomtype(this.getRoomTypesById(roomtypes_id));
        r.setIspublic(ispublic);
        r.setAllowUserQuestions(allowUserQuestions);
        r.setIsAudioOnly(isAudioOnly);
        r.setAllowFontStyles(allowFontStyles);

        r.setAppointment(appointment);

        r.setIsDemoRoom(isDemoRoom);
        r.setDemoTime(demoTime);

        r.setIsModeratedRoom(isModeratedRoom);
        r.setHideTopBar(hideTopBar);

        r.setDeleted(false);

        r.setIsClosed(isClosed);
        r.setRedirectURL(redirectURL);

        r.setOwnerId(ownerId);

        r.setWaitForRecording(waitForRecording);
        r.setAllowRecording(allowRecording);
       
        r.setHideChat(hideChat);
        r.setHideActivitiesAndActions(hideActivitiesAndActions);
        r.setHideActionsMenu(hideActionsMenu);
        r.setHideFilesExplorer(hideFilesExplorer);
        r.setHideScreenSharing(hideScreenSharing)
        r.setHideWhiteboard(hideWhiteboard);
        r.setShowMicrophoneStatus(showMicrophoneStatus);
        r.setChatModerated(chatModerated);
        r.setChatOpened(chatOpened);
        r.setFilesOpened(filesOpened);
        r.setAutoVideoSelect(autoVideoSelect);
        r.setSipEnabled(sipEnabled);
        r.setPin(conferencePin);
       
        r = roomDao.update(r, ownerId);

        if (organisations != null) {
          Long t = this.updateRoomOrganisations(organisations, r);
          if (t == null)
            return null;
        }

        if (roomModerators != null) {
          roomModeratorsDao.addRoomModeratorByUserList(
              roomModerators, r.getRooms_id());
        }

        return r.getRooms_id();
      }
    } catch (Exception ex2) {
      log.error("[addRoom] ", ex2);
    }
    return null;
View Full Code Here

    log.debug("addRoom");

    try {
      if (authLevelUtil.checkModLevel(user_level)) {
        Room r = new Room();
        r.setName(name);
        r.setComment(comment);
        r.setStarttime(new Date());
        r.setNumberOfPartizipants(numberOfPartizipants);
        r.setRoomtype(this.getRoomTypesById(roomtypes_id));
        r.setIspublic(ispublic);

        r.setAllowUserQuestions(allowUserQuestions);
        r.setAppointment(appointment);

        r.setIsDemoRoom(isDemoRoom);
        r.setDemoTime(demoTime);

        r.setIsModeratedRoom(isModeratedRoom);

        r.setDeleted(false);
        r = em.merge(r);
        long returnId = r.getRooms_id();

        this.addRoomToOrganisation(3, returnId, organisation_id);

        if (roomModerators != null) {
          roomModeratorsDao.addRoomModeratorByUserList(
              roomModerators, r.getRooms_id());
        }

        return returnId;
      }
    } catch (Exception ex2) {
View Full Code Here

      Boolean allowRecording, Boolean hideTopBar) {

    log.debug("addExternalRoom");

    try {
      Room r = new Room();
      r.setName(name);
      r.setComment(comment);
      r.setStarttime(new Date());
      r.setNumberOfPartizipants(numberOfPartizipants);
      r.setRoomtype(this.getRoomTypesById(roomtypes_id));
      r.setIspublic(ispublic);

      r.setAllowUserQuestions(allowUserQuestions);
      r.setIsAudioOnly(isAudioOnly);
      r.setAllowFontStyles(allowFontStyles);

      r.setAppointment(appointment);

      r.setIsDemoRoom(isDemoRoom);
      r.setDemoTime(demoTime);

      r.setIsModeratedRoom(isModeratedRoom);

      r.setDeleted(false);

      r.setExternalRoomId(externalRoomId);
      r.setExternalRoomType(externalRoomType);

      r.setIsClosed(isClosed);
      r.setRedirectURL(redirectURL);

      r.setWaitForRecording(waitForRecording);
      r.setAllowRecording(allowRecording);

      r.setHideTopBar(hideTopBar);

      r = em.merge(r);

      long returnId = r.getRooms_id();

      if (organisations != null) {
        Long t = this.updateRoomOrganisations(organisations, r);
        if (t == null)
          return null;
      }

      if (roomModerators != null) {
        roomModeratorsDao.addRoomModeratorByUserList(roomModerators,
            r.getRooms_id());
      }

      return returnId;
    } catch (Exception ex2) {
      log.error("[addExternalRoom] ", ex2);
View Full Code Here

    try {
      if (authLevelUtil.checkModLevel(user_level)) {

        if (this.checkUserOrgRoom(user_id, rooms_id)) {

          Room r = roomDao.get(rooms_id);
          r.setComment(comment);
          r.setIspublic(ispublic);
          r.setName(name);
          r.setRoomtype(this.getRoomTypesById(roomtypes_id));
          r.setUpdatetime(new Date());

          if (r.getRooms_id() == null) {
            em.persist(r);
          } else {
            if (!em.contains(r)) {
              em.merge(r);
            }
View Full Code Here

      Boolean showMicrophoneStatus, Boolean chatModerated, boolean chatOpened, boolean filesOpened
      , boolean autoVideoSelect, boolean sipEnabled) {
    try {
      log.debug("*** updateRoom numberOfPartizipants: "
          + numberOfPartizipants);
      Room r = roomDao.get(rooms_id);
      r.setComment(comment);

      r.setIspublic(ispublic);
      r.setNumberOfPartizipants(numberOfPartizipants);
      r.setName(name);
      r.setRoomtype(this.getRoomTypesById(roomtypes_id));
      r.setUpdatetime(new Date());
      r.setAllowUserQuestions(allowUserQuestions);
      r.setIsAudioOnly(isAudioOnly);
      r.setAllowFontStyles(allowFontStyles);

      r.setIsDemoRoom(isDemoRoom);
      r.setDemoTime(demoTime);

      r.setAppointment(appointment);

      r.setIsModeratedRoom(isModeratedRoom);
      r.setHideTopBar(hideTopBar);

      r.setIsClosed(isClosed);
      r.setRedirectURL(redirectURL);
      r.setOwnerId(ownerId);
      r.setWaitForRecording(waitForRecording);
      r.setAllowRecording(allowRecording);
     
      r.setHideChat(hideChat);
      r.setHideActivitiesAndActions(hideActivitiesAndActions);
      r.setHideActionsMenu(hideActionsMenu);
      r.setHideFilesExplorer(hideFilesExplorer);
      r.setHideScreenSharing(hideScreenSharing);
      r.setHideWhiteboard(hideWhiteboard);
      r.setShowMicrophoneStatus(showMicrophoneStatus);
      r.setChatModerated(chatModerated);
      r.setChatOpened(chatOpened);
      r.setFilesOpened(filesOpened);
      r.setAutoVideoSelect(autoVideoSelect);
      r.setPin(conferencePin);
      r.setSipEnabled(sipEnabled);
      roomDao.update(r, ownerId);

      if (organisations != null) {
        Long t = this.updateRoomOrganisations(organisations, r);
        if (t == null)
          return null;
      }
      if (roomModerators != null) {
        roomModeratorsDao.updateRoomModeratorByUserList(roomModerators,
            r.getRooms_id());
      }

      return r.getRooms_id();
    } catch (Exception ex2) {
      log.error("[updateRoom] ", ex2);
    }
    return null;
  }
View Full Code Here

      List<Map<String, Object>> roomModerators, Boolean allowUserQuestions) {
    try {
      log.debug("*** updateRoom numberOfPartizipants: "
          + numberOfPartizipants);
      if (authLevelUtil.checkModLevel(user_level)) {
        Room r = roomDao.get(rooms_id);
        r.setComment(comment);

        r.setIspublic(ispublic);
        r.setNumberOfPartizipants(numberOfPartizipants);
        r.setName(name);
        r.setRoomtype(this.getRoomTypesById(roomtypes_id));
        r.setUpdatetime(new Date());
        r.setAllowUserQuestions(allowUserQuestions);

        r.setIsDemoRoom(isDemoRoom);
        r.setDemoTime(demoTime);

        r.setAppointment(appointment);

        r.setIsModeratedRoom(isModeratedRoom);

        if (r.getRooms_id() == null) {
          em.persist(r);
        } else {
          if (!em.contains(r)) {
            em.merge(r);
          }
        }

        // FIXME: Organizations will not be changed when you do an
        // update as Moderator

        if (roomModerators != null) {
          roomModeratorsDao.updateRoomModeratorByUserList(
              roomModerators, r.getRooms_id());
        }

        return r.getRooms_id();
      }
    } catch (Exception ex2) {
      log.error("[updateRoom] ", ex2);
    }
    return null;
View Full Code Here

  // --------------------------------------------------------------------------------------------

  public void closeRoom(Long rooms_id, Boolean status) {
    try {

      Room room = roomDao.get(rooms_id);

      room.setIsClosed(status);

      roomDao.update(room, -1L);

    } catch (Exception e) {
      log.error("Error updateRoomObject : ", e);
View Full Code Here

      if (roomtypesId == null || roomtypesId == 0) {
        return null;
      }
      log.debug("getRoomByOwnerAndTypeId : " + ownerId + " || "
          + roomtypesId);
      Room room = null;
      TypedQuery<Room> query = em.createNamedQuery("getRoomByOwnerAndTypeId", Room.class);
      query.setParameter("ownerId", ownerId);
      query.setParameter("roomtypesId", roomtypesId);
      query.setParameter("deleted", true);
      List<Room> ll = query.getResultList();
View Full Code Here

TOP

Related Classes of org.apache.openmeetings.persistence.beans.room.Room

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.