Package org.openmeetings.app.persistence.beans.rooms

Examples of org.openmeetings.app.persistence.beans.rooms.Rooms


            log.error("Executing asterisk originate error: ", e);
        }
    }

    public synchronized String getSipNumber(Long room_id) {
        Rooms rooms = roommanagement.getRoomById(room_id);
        if(rooms != null) {
            log.debug("getSipNumber: room_id: {}, sipNumber: {}", new Object[]{room_id, rooms.getSipNumber()});
            return rooms.getSipNumber();
        }
        return null;
    }
View Full Code Here


            Boolean isTrash = importBooleanType(unformatString(pmObject
                .element("isTrash").getText()));
            Users owner = userManagement.getUserById(getNewId(
                importLongType(unformatString(pmObject.element(
                    "owner").getText())), Maps.USERS));
            Rooms room = roommanagement.getRoomById(getNewId(
                importLongType(unformatString(pmObject.element(
                    "room").getText())), Maps.ROOMS));

            PrivateMessages pm = new PrivateMessages();
            pm.setMessage(message);
View Full Code Here

        if (roomObject.element("hideWhiteboard") != null) {
          hideTopBar = importBooleanType(unformatString(roomObject
              .element("hideWhiteboard").getText()));
        }

        Rooms room = new Rooms();
        room.setRooms_id(rooms_id);
        room.setOwnerId(ownerId);
        room.setName(name);
        room.setDeleted(deleted);
        room.setComment(comment);
        room.setNumberOfPartizipants(numberOfPartizipants);
        room.setAppointment(appointment);
        room.setExternalRoomId(externalRoomId);
        room.setExternalRoomType(externalRoomType);
        room.setRoomtype(roommanagement
            .getRoomTypesById(roomtypes_id));
        room.setIsDemoRoom(isDemoRoom);
        room.setDemoTime(demoTime);
        room.setIsModeratedRoom(isModeratedRoom);
        room.setAllowUserQuestions(allowUserQuestions);
        room.setIsAudioOnly(isAudioOnly);
        room.setSipNumber(sipNumber);
        room.setConferencePin(conferencePin);
        room.setIspublic(ispublic);
        room.setIsClosed(isClosed);
        room.setRedirectURL(redirectURL);
        room.setWaitForRecording(waitForRecording);
        room.setHideTopBar(hideTopBar);
        room.setAllowRecording(allowRecording);
        room.setShowMicrophoneStatus(showMicrophoneStatus);           
        room.setHideActionsMenu(hideActionsMenu);
        room.setHideActivitiesAndActions(hideActivitiesAndActions);
        room.setHideChat(hideChat);
        room.setHideFilesExplorer(hideFilesExplorer);
        room.setHideScreenSharing(hideScreenSharing);
        room.setHideWhiteboard(hideWhiteboard);

        Long roomId = room.getRooms_id();

        // We need to reset this as openJPA reject to store them
        // otherwise
        room.setRooms_id(null);

        Long newRoomId = roommanagement.addRoom(room);
        roomsMap.put(roomId, newRoomId);

        for (Iterator<Element> iterMods = roomObject
View Full Code Here

      Boolean allowRecording, Boolean hideTopBar) {

    log.debug("addExternalRoom");

    try {
      Rooms r = new Rooms();
      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.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 (authLevelManagement.checkModLevel(user_level)) {

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

          Rooms r = this.getRoomById(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 hideActionsMenu, Boolean hideScreenSharing, Boolean hideWhiteboard,
      Boolean showMicrophoneStatus) {
    try {
      log.debug("*** updateRoom numberOfPartizipants: "
          + numberOfPartizipants);
      Rooms r = this.getRoomById(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.setIsDemoRoom(isDemoRoom);
      r.setDemoTime(demoTime);

      r.setAppointment(appointment);

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

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

      r.setSipNumber(sipNumber);
      r.setConferencePin(conferencePin);
      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);

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

      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 (authLevelManagement.checkModLevel(user_level)) {
        Rooms r = this.getRoomById(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 {

      Rooms room = this.getRoomById(rooms_id);

      room.setIsClosed(status);

      this.updateRoomObject(room);

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

      String hql = "select c from Rooms as c "
          + "where c.ownerId = :ownerId "
          + "AND c.roomtype.roomtypes_id = :roomtypesId "
          + "AND c.deleted <> :deleted";

      Rooms room = null;

      TypedQuery<Rooms> query = em.createQuery(hql, Rooms.class);
      query.setParameter("ownerId", ownerId);
      query.setParameter("roomtypesId", roomtypesId);
      query.setParameter("deleted", "true");
View Full Code Here

   */
  // --------------------------------------------------------------------------------------------
  public Appointment getAppointmentByRoom(Long room_id) throws Exception {
    log.debug("getAppointmentByRoom");

    Rooms room = roommanagement.getRoomById(room_id);

    if (room == null)
      throw new Exception("Room does not exist in database!");

    if (!room.getAppointment())
      throw new Exception("Room " + room.getName()
          + " isnt part of an appointed meeting");

    return appointmentDao.getAppointmentByRoom(room_id);
  }
View Full Code Here

TOP

Related Classes of org.openmeetings.app.persistence.beans.rooms.Rooms

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.