Examples of createSession()


Examples of javax.jms.XAConnection.createSession()

         // Step 6. Create a JMS XASession
         XASession xaSession = connection.createXASession();

         // Step 7. Create a normal session
         Session normalSession = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);

         // Step 8. Create a normal Message Consumer
         MessageConsumer normalConsumer = normalSession.createConsumer(queue);
         normalConsumer.setMessageListener(new SimpleMessageListener());
View Full Code Here

Examples of net.rim.blackberry.api.bbm.platform.service.MessagingService.createSession()

                return connObj;
            } else if(type.equals(TYPE_SESSION)) {
                final ConnectionListenerImpl connListenerImpl = new ConnectionListenerImpl();
                final BBMPlatformSessionListener sessionListener = new SessionListener(connListenerImpl);
               
                final BBMPlatformSession session = msgService.createSession(sessionListener);
                SessionObject connObj = new SessionObject(session, true);
                connListenerImpl.setConnectionObject(connObj);
               
                return connObj;
            } else {
View Full Code Here

Examples of net.sourceforge.squirrel_sql.client.session.SessionManager.createSession()

    private ISession createSession(ISQLDriver sqlDriver,
                        SQLConnection conn)
    {
      SessionManager sm = _app.getSessionManager();
      final ISession session = sm.createSession(_app, sqlDriver,
                        _alias, conn, _user, _password);
      _callback.sessionCreated(session);
      SwingUtilities.invokeLater(new Runner(session, _connSheet));
      return session;
    }
View Full Code Here

Examples of oracle.jms.AQjmsConnection.createSession()

        // AQjmsConsumer
        // if session is null or if the sessions is not open
        // create a new session
        // if (session == null || !session.isOpen()) {
        session = (AQjmsSession) aqJMS.createSession(false,
                Session.AUTO_ACKNOWLEDGE);
        LOG.debug("Creating AQjmsSession session " + session);

        LOG.debug("Underlying database connection is "
                + session.getDBConnection());
View Full Code Here

Examples of org.activemq.ActiveMQConnection.createSession()

   
    public void XtestSendNotify() throws Exception {
       
        ActiveMQNotificationBroker broker = new ActiveMQNotificationBroker();
        ActiveMQConnection connection = broker.getConnection();
        Session session = connection.createSession(false, 0);
        ActiveMQTopic topic = new ActiveMQTopic("Test");
        MessageConsumer consumer = session.createConsumer(topic);
       
        NotifyDocument request = NotifyDocument.Factory.newInstance();
        Notify notify = request.addNewNotify();
View Full Code Here

Examples of org.apache.activemq.ActiveMQConnection.createSession()

      // Create the connection.
      ActiveMQConnectionFactory connectionFactory = new ActiveMQConnectionFactory(user, password, url);
      connection = (ActiveMQConnection) connectionFactory.createConnection();
      connection.start();
      // Create the session
      Session session = connection.createSession(transacted, Session.AUTO_ACKNOWLEDGE);
      if (topic) {
        destination = session.createTopic(subject);
      }
      else {
        destination = session.createQueue(subject);
View Full Code Here

Examples of org.apache.archiva.metadata.repository.RepositorySessionFactory.createSession()

        RepositorySession repositorySession = mock( RepositorySession.class );
        when( repositorySession.getRepository() ).thenReturn( metadataRepository );

        RepositorySessionFactory repositorySessionFactory = mock( RepositorySessionFactory.class );
        when( repositorySessionFactory.createSession() ).thenReturn( repositorySession );

        listenerControl = MockControl.createControl( RepositoryListener.class );
        listener = (RepositoryListener) listenerControl.getMock();

        roleManagerControl = MockControl.createControl( RoleManager.class );
View Full Code Here

Examples of org.apache.catalina.Manager.createSession()

      Manager mgr = manager;
      Session sess = mgr.findSession(id);
      assertNull("session does not exist", sess);
      try
      {
         sess = mgr.createSession(id);
         if (!canCreate)
            fail("Could not create session" + id);
      }
      catch (IllegalStateException ise)
      {
View Full Code Here

Examples of org.apache.chemistry.opencmis.client.api.Repository.createSession()

        Map<String, String> parameter = new HashMap<String, String>();
        parameter.put(SessionParameter.ATOMPUB_URL, CMIS_ENDPOINT_TEST_SERVER);
        parameter.put(SessionParameter.BINDING_TYPE, BindingType.ATOMPUB.value());

        Repository repository = sessionFactory.getRepositories(parameter).get(0);
        return repository.createSession();
    }

    protected String getDocumentContentAsString(String nodeId) throws Exception {
        CmisObject cmisObject = retrieveCMISObjectByIdFromServer(nodeId);
        Document doc = (Document)cmisObject;
View Full Code Here

Examples of org.apache.chemistry.opencmis.client.api.SessionFactory.createSession()

        System.out.println("Connecting to a repository ...");

        // Create a SessionFactory and set up the SessionParameter map
        SessionFactory sessionFactory = SessionFactoryImpl.newInstance();

        session = sessionFactory.createSession(parameters);

        LOG.debug("Got a connection to repository.");
    }
       
    public void copyRecursive(String folderName, String folderId) {
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.