Examples of RoomClient


Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

        for (Iterator<String> iter = MyUserList.keySet().iterator(); iter
            .hasNext();) {
          String key = (String) iter.next();

          RoomClient rcl = MyUserList.get(key);

          if (rcl == null) {
            return true;
          }
          String scopeName = "hibernate";
          if (rcl.getRoom_id() != null) {
            scopeName = rcl.getRoom_id().toString();
          }
          IScope currentScope = ScopeApplicationAdapter.getInstance()
              .getRoomScope(scopeName);
          ScopeApplicationAdapter.getInstance().roomLeaveByScope(rcl,
              currentScope);

          HashMap<Integer, String> messageObj = new HashMap<Integer, String>();
          messageObj.put(0, "kick");
          ScopeApplicationAdapter.getInstance().sendMessageById(
              messageObj, rcl.getStreamid(), currentScope);

        }

        return true;
      }
View Full Code Here

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

          users_id);

      // admins only
      if (AuthLevelmanagement.getInstance().checkAdminLevel(user_level)) {

        RoomClient rcl = ClientListManager.getInstance()
            .getClientByPublicSID(publicSID);

        if (rcl == null) {
          return true;
        }

        String scopeName = "hibernate";
        if (rcl.getRoom_id() != null) {
          scopeName = rcl.getRoom_id().toString();
        }
        IScope currentScope = ScopeApplicationAdapter.getInstance()
            .getRoomScope(scopeName);
        ScopeApplicationAdapter.getInstance().roomLeaveByScope(rcl,
            currentScope);

        HashMap<Integer, String> messageObj = new HashMap<Integer, String>();
        messageObj.put(0, "kick");
        ScopeApplicationAdapter.getInstance().sendMessageById(
            messageObj, rcl.getStreamid(), currentScope);

        return true;
      }

    } catch (Exception err) {
View Full Code Here

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

      String streamid = current.getClient().getId();

      log.debug("getCurrentRoomClient -1- " + SID);
      log.debug("getCurrentRoomClient -2- " + streamid);

      RoomClient currentClient = this.clientListManager
          .getClientByStreamId(streamid);
      return currentClient;
    } catch (Exception err) {
      log.error("[getCurrentRoomClient]", err);
    }
View Full Code Here

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

  }

  public Users loginByRemember(String SID, String remoteHashId) {
    try {

      RoomClient currentClient;
      IConnection current = Red5.getConnectionLocal();

      Users o = null;

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

      o = Usermanagement.getInstance().loginUserByRemoteHash(SID,
          remoteHashId);

      if (o == null)
        return null;

      if (o.getOrganisation_users() == null) {
        throw new Exception("Users has no organization assigned");
      }

      o.setSessionData(Sessionmanagement.getInstance().getSessionByHash(
          remoteHashId));

      if (currentClient.getUser_id() != null
          && currentClient.getUser_id() > 0) {

        currentClient.setFirstname(o.getFirstname());
        currentClient.setLastname(o.getLastname());

        Collection<Set<IConnection>> conCollection = current.getScope()
            .getConnections();
        for (Set<IConnection> conset : conCollection) {
          for (IConnection cons : conset) {
            if (cons != null) {
              RoomClient rcl = this.clientListManager
                  .getClientByStreamId(cons.getClient()
                      .getId());
              if (rcl == null) {
                // continue;
              } else if (rcl.getIsScreenClient() != null
                  && rcl.getIsScreenClient()) {
                // continue;
              } else {
                if (cons instanceof IServiceCapableConnection) {
                  if (!cons.equals(current)) {
                    // log.error("sending roomDisconnect to "
View Full Code Here

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

    }

    try {
      log.warn("loginUser: " + SID + " " + usernameOrEmail);

      RoomClient currentClient;
      IConnection current = Red5.getConnectionLocal();

      Object o;

      if (withLdap) {
        log.debug("Ldap Login");

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

        // LDAP Loggedin Users cannot use the permanent Login Flag

        LdapConfig ldapConfig = LdapConfigDaoImpl.getInstance()
            .getLdapConfigById(ldapConfigId);

        String ldapLogin = usernameOrEmail;
        if (ldapConfig.getAddDomainToUserName() != null
            && ldapConfig.getAddDomainToUserName()) {
          ldapLogin = usernameOrEmail + "@" + ldapConfig.getDomain();
        }

        o = LdapLoginManagement.getInstance().doLdapLogin(ldapLogin,
            Userpass, currentClient, SID,
            ldapConfig.getConfigFileName());
      } else {

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

        o = Usermanagement.getInstance().loginUser(SID,
            usernameOrEmail, Userpass, currentClient,
            storePermanent);
      }

      if (o == null)
        return null;

      if (!o.getClass().isAssignableFrom(Users.class))
        return o;

      if (currentClient.getUser_id() != null
          && currentClient.getUser_id() > 0) {

        Users u = (Users) o;
        currentClient.setFirstname(u.getFirstname());
        currentClient.setLastname(u.getLastname());

        Collection<Set<IConnection>> conCollection = current.getScope()
            .getConnections();
        for (Set<IConnection> conset : conCollection) {
          for (IConnection cons : conset) {
            if (cons != null) {
              RoomClient rcl = this.clientListManager
                  .getClientByStreamId(cons.getClient()
                      .getId());
              if (rcl != null && rcl.getIsScreenClient() != null
                  && rcl.getIsScreenClient()) {
                // continue;
              } else {
                if (cons instanceof IServiceCapableConnection) {
                  if (!cons.equals(current)) {
                    // log.error("sending roomDisconnect to "
View Full Code Here

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

      Long loginReturn = this.loginUserByRemote(soapLogin
          .getSessionHash());

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

      if (currentClient.getUser_id() != null) {
        Sessionmanagement.getInstance().updateUser(SID,
            currentClient.getUser_id());
      }

      currentClient.setAllowRecording(soapLogin.getAllowRecording());
      this.clientListManager.updateClientByStreamId(streamId,
          currentClient);

      if (loginReturn == null) {
View Full Code Here

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

  public Long setUserNickName(String firstname, String lastname, String email) {
    try {

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

      currentClient.setFirstname(firstname);
      currentClient.setLastname(lastname);
      currentClient.setMail(email);

      // Log the User
      ConferenceLogDaoImpl.getInstance().addConferenceLog(
          "nicknameEnter", currentClient.getUser_id(), streamId,
          null, currentClient.getUserip(), currentClient.getScope(),
          currentClient.getExternalUserId(),
          currentClient.getExternalUserType(),
          currentClient.getMail(), currentClient.getFirstname(),
          currentClient.getLastname());

      this.clientListManager.updateClientByStreamId(streamId,
          currentClient);

      return 1L;
View Full Code Here

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

              + ", "
              + userObject.getLastname());

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

          // Check if this User is simulated in the OpenMeetings
          // Database

          log.debug("userObject.getExternalUserId() -1- "
              + userObject.getExternalUserId());

          if (userObject.getExternalUserId() != null
              && userObject.getExternalUserId() > 0) {

            // If so we need to check that we create this user in
            // OpenMeetings and update its record

            Users user = Usermanagement.getInstance()
                .getUserByExternalIdAndType(
                    userObject.getExternalUserId(),
                    userObject.getExternalUserType());

            if (user == null) {

              Configuration conf = Configurationmanagement
                  .getInstance().getConfKey(3L,
                      "default.timezone");
              String jName_timeZone = "";

              if (conf != null) {
                jName_timeZone = conf.getConf_value();
              }

              long userId = Usermanagement.getInstance()
                  .addUserWithExternalKey(1, 0, 0,
                      userObject.getFirstname(),
                      userObject.getUsername(),
                      userObject.getLastname(), 1L, "",
                      null, null, "",
                      userObject.getExternalUserId(),
                      userObject.getExternalUserType(),
                      true, userObject.getEmail(),
                      jName_timeZone,
                      userObject.getPictureUrl());

              currentClient.setUser_id(userId);
            } else {

              user.setPictureuri(userObject.getPictureUrl());

              Usermanagement.getInstance().updateUser(user);

              currentClient.setUser_id(user.getUser_id());
            }
          }

          log.debug("userObject.getExternalUserId() -2- "
              + currentClient.getUser_id());

          currentClient
              .setUserObject(userObject.getUsername(),
                  userObject.getFirstname(),
                  userObject.getLastname());
          currentClient.setPicture_uri(userObject.getPictureUrl());
          currentClient.setMail(userObject.getEmail());

          log.debug("UPDATE USER BY STREAMID " + streamId);

          if (currentClient.getUser_id() != null) {
            Sessionmanagement.getInstance().updateUser(SID,
                currentClient.getUser_id());
          }

          this.clientListManager.updateClientByStreamId(streamId,
              currentClient);
View Full Code Here

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

      String swfURL = "";
      if (conn.getConnectParams().get("swfUrl") != null) {
        swfURL = conn.getConnectParams().get("swfUrl").toString();
      }
     
      RoomClient rcm = this.clientListManager.addClientListItem(streamId, room.getName(), conn.getRemotePort(),
          conn.getRemoteAddress(), swfURL);
     
      //Log the User
      ConferenceLogDaoImpl.getInstance().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

Examples of org.openmeetings.app.persistence.beans.recording.RoomClient

   * @return string value if completed
   */
  public Long logoutUser(String SID) {
    Long users_id = Sessionmanagement.getInstance().checkSession(SID);
    IConnection current = Red5.getConnectionLocal();
    RoomClient currentClient = this.clientListManager
        .getClientByStreamId(current.getClient().getId());
    currentClient.setUserObject(null, null, null, null);
    return Usermanagement.getInstance().logout(SID, users_id);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.