Examples of SessionConfig


Examples of hermes.config.SessionConfig

        passwordTF.setText(connectionConfig.getPassword());
        clientIDTF.setText(connectionConfig.getClientID()) ;

        if (connectionConfig.getSession().size() == 0)
        {
            connectionConfig.getSession().add(new SessionConfig());
        }
    }
View Full Code Here

Examples of hermes.config.SessionConfig

               connectionConfigPanel.setConnectionConfig(connectionConfig);

               for (Iterator iter4 = connectionConfig.getSession().iterator(); iter4.hasNext();)
               {
                  SessionConfig sessionConfig = (SessionConfig) iter4.next();

                  if (firstSessionId == null)
                  {
                     firstSessionId = sessionConfig.getId();
                  }

                  sessionConfigPanel.addSessionConfig(sessionConfig);
                  sessionToFactoryMap.put(sessionConfig.getId(), factoryConfig);
               }
            }
         }

         sessionPanel.setLayout(new BorderLayout());
View Full Code Here

Examples of hermes.config.SessionConfig

               ConnectionConfig cConfig = (ConnectionConfig) fConfig.getConnection().get(0);

               for (Iterator iter2 = cConfig.getSession().iterator(); iter2.hasNext();)
               {
                  SessionConfig sConfig = (SessionConfig) iter2.next();

                  if (sConfig.getId() == null || sConfig.getId().equals(""))
                  {
                     iter2.remove();
                  }
               }
            }
View Full Code Here

Examples of hermes.config.SessionConfig

  private JTextField sessionName;

  public BasicConnectionPanel(String serverUrlProperty, FactoryConfig factoryConfig, HermesConfig config) {
    this.factoryConfig = factoryConfig;
    ConnectionConfig connectionConfig = factoryConfig.getConnection().get(0) ;
    SessionConfig sessionConfig = connectionConfig.getSession().get(0) ;
    setLayout(new FormLayout(new ColumnSpec[] {
        FormFactory.RELATED_GAP_COLSPEC,
        ColumnSpec.decode("max(41dlu;default)"),
        FormFactory.RELATED_GAP_COLSPEC,
        ColumnSpec.decode("118dlu:grow"),
View Full Code Here

Examples of hermes.config.SessionConfig

    return !TextUtils.isEmpty(sessionName.getText()) ;
  }
 
  public void setValues(FactoryConfig config) {
    ConnectionConfig connectionConfig = HermesBrowser.getConfigDAO().getFactory().createConnectionConfig() ;
    SessionConfig sessionConfig = HermesBrowser.getConfigDAO().getFactory().createSessionConfig() ;
   
    connectionConfig.setUsername(getUsername()) ;
    connectionConfig.setPassword(getPassword()) ;
    connectionConfig.setClientID(getClientID()) ;
   
    sessionConfig.setId(sessionName.getText()) ;
   
    connectionConfig.getSession().add(sessionConfig) ;
    config.getConnection().add(connectionConfig) ;
  }
View Full Code Here

Examples of io.undertow.server.session.SessionConfig

    }

    public void initDone() {
        initialized = true;
        Set<SessionTrackingMode> trackingMethods = sessionTrackingModes;
        SessionConfig sessionConfig = sessionCookieConfig;
        if (trackingMethods != null && !trackingMethods.isEmpty()) {
            if (sessionTrackingModes.contains(SessionTrackingMode.SSL)) {
                sessionConfig = new SslSessionConfig(deployment.getSessionManager());
            } else {
                if (sessionTrackingModes.contains(SessionTrackingMode.COOKIE) && sessionTrackingModes.contains(SessionTrackingMode.URL)) {
View Full Code Here

Examples of io.undertow.server.session.SessionConfig

        }
        return null;
    }

    public HttpSessionImpl getSession(final ServletContextImpl originalServletContext, final HttpServerExchange exchange, boolean create) {
        SessionConfig c = originalServletContext.getSessionConfig();
        HttpSessionImpl httpSession = exchange.getAttachment(sessionAttachmentKey);
        if (httpSession != null && httpSession.isInvalid()) {
            exchange.removeAttachment(sessionAttachmentKey);
            httpSession = null;
        }
        if (httpSession == null) {
            final SessionManager sessionManager = deployment.getSessionManager();
            Session session = sessionManager.getSession(exchange, c);
            if (session != null) {
                httpSession = SecurityActions.forSession(session, this, false);
                exchange.putAttachment(sessionAttachmentKey, httpSession);
            } else if (create) {

                String existing = c.findSessionId(exchange);
                if (originalServletContext != this) {
                    //this is a cross context request
                    //we need to make sure there is a top level session
                    originalServletContext.getSession(originalServletContext, exchange, true);
                } else if (existing != null) {
                    c.clearSession(exchange, existing);
                }

                final Session newSession = sessionManager.createSession(exchange, c);
                httpSession = SecurityActions.forSession(newSession, this, true);
                exchange.putAttachment(sessionAttachmentKey, httpSession);
View Full Code Here

Examples of io.undertow.server.session.SessionConfig

        return result;
    }

    @Override
    public String getRequestedSessionId() {
        SessionConfig config = originalServletContext.getSessionConfig();
        return config.findSessionId(exchange);
    }
View Full Code Here

Examples of io.undertow.server.session.SessionConfig

     * @param exchange The exchange
     * @return The session
     */
    public static Session getSession(final HttpServerExchange exchange) {
        SessionManager sessionManager = exchange.getAttachment(SessionManager.ATTACHMENT_KEY);
        SessionConfig sessionConfig = exchange.getAttachment(SessionConfig.ATTACHMENT_KEY);
        if(sessionManager == null) {
            throw UndertowMessages.MESSAGES.sessionManagerNotFound();
        }
        return sessionManager.getSession(exchange, sessionConfig);
    }
View Full Code Here

Examples of io.undertow.server.session.SessionConfig

     * @param exchange The exchange
     * @return The session
     */
    public static Session getOrCreateSession(final HttpServerExchange exchange) {
        SessionManager sessionManager = exchange.getAttachment(SessionManager.ATTACHMENT_KEY);
        SessionConfig sessionConfig = exchange.getAttachment(SessionConfig.ATTACHMENT_KEY);
        if(sessionManager == null) {
            throw UndertowMessages.MESSAGES.sessionManagerNotFound();
        }
        Session session = sessionManager.getSession(exchange, sessionConfig);
        if(session == null) {
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.