Examples of createContext()


Examples of com.sun.net.httpserver.HttpServer.createContext()

        Authenticator authenticator = new Authenticator(this.getClass().getCanonicalName(), webroot + "/authentication");

        server.setExecutor(Executors.newCachedThreadPool());
        server.createContext("/", fileserver);
        server.createContext("/ui", fileserver).setAuthenticator(authenticator);
        server.createContext("/qpid/connection", qpidserver).setAuthenticator(authenticator);
        server.start();
    }

    /**
 
View Full Code Here

Examples of com.sun.net.httpserver.HttpServer.createContext()

        Authenticator authenticator = new Authenticator(this.getClass().getCanonicalName(), webroot + "/authentication");

        server.setExecutor(Executors.newCachedThreadPool());
        server.createContext("/", fileserver);
        server.createContext("/ui", fileserver).setAuthenticator(authenticator);
        server.createContext("/qpid/connection", qpidserver).setAuthenticator(authenticator);
        server.start();
    }

    /**
     * Runs QpidRestAPI.
View Full Code Here

Examples of com.sun.net.httpserver.HttpsServer.createContext()

      httpsServer.start();

      Endpoint endpoint = Endpoint.create(new BrownBagServiceImpl());

      endpoint.publish(httpsServer.createContext("/BrownBagService"));
    }
  }

}
View Full Code Here

Examples of hermes.JNDIConnectionFactory.createContext()

    public HermesAdmin createSession(Hermes hermes, ConnectionFactory connectionFactory) throws JMSException, NamingException
    {
       if (connectionFactory instanceof JNDIConnectionFactory)
       {
          JNDIConnectionFactory jndiCF = (JNDIConnectionFactory) connectionFactory ;
          return new ArjunaMSAdmin(hermes, this, jndiCF.createContext()) ;
       }
       else
       {
          throw new HermesException("Provider is not ArjunaMS") ;
       }
View Full Code Here

Examples of hermes.JNDIContextFactory.createContext()

      
       contextBean._setDelegateClassLoader(classLoaderManager.getClassLoader(namingConfig.getClasspathId())) ;
     
       LoaderSupport.populateBean(contextBean, namingConfig.getProperties()) ;
      
       Context rootContext = contextBean.createContext() ;
      
       ContextTreeNode rootNode = new ContextTreeNode(namingConfig.getId(), namingConfig, rootContext) ;
       ContextTreeModel model = new ContextTreeModel(contextBean, rootNode) ;
      
       Hermes.ui.getDefaultMessageSink().add("Finished searching InitialContext "+ namingConfig.getId()) ;
View Full Code Here

Examples of io.crate.executor.transport.distributed.DistributedRequestContextManager.createContext()


        contextManager.addToContext(requestReceiver);
        final SettableFuture<Object[][]> result = SettableFuture.create();

        contextManager.createContext(dummyMergeNode, new ActionListener<NodeMergeResponse>() {
            @Override
            public void onResponse(NodeMergeResponse nodeMergeResponse) {
                result.set(nodeMergeResponse.rows());
            }
View Full Code Here

Examples of javax.jms.ConnectionFactory.createContext()

            log.info("Found destination \"" + destinationString + "\" in JNDI");

            int count = Integer.parseInt(System.getProperty("message.count", DEFAULT_MESSAGE_COUNT));
            String content = System.getProperty("message.content", DEFAULT_MESSAGE);

            try (JMSContext context = connectionFactory.createContext(userName, password)) {
                log.info("Sending " + count + " messages with content: " + content);
                // Send the specified number of messages
                for (int i = 0; i < count; i++) {
                    context.createProducer().send(destination, content);
                }
View Full Code Here

Examples of javax.media.opengl.GLDrawable.createContext()

      GLDrawable  glDrawable   = null;
      GLContext   glContext  = null;

      if (offScreen) {
        glDrawable = drawable(cv.drawable); // cv.drawable != null, set in 'createOffScreenBuffer'
      glContext = glDrawable.createContext(context(shareCtx));
        }
      else {
        // determined in 'getBestConfiguration'
      GraphicsConfigInfo gcInf0 = Canvas3D.graphicsConfigTable.get(cv.graphicsConfiguration);
      AWTGraphicsConfiguration awtConfig = (AWTGraphicsConfiguration)gcInf0.getPrivateData();
View Full Code Here

Examples of org.apache.batik.ext.awt.image.SVGComposite.createContext()

        Iterator i = srcs.iterator();
        Rectangle myBounds = null;
        while (i.hasNext()) {
            CachableRed cr = (CachableRed)i.next();

            contexts[idx++] = comp.createContext(cr.getColorModel(), cm, null);

            Rectangle newBound = cr.getBounds();
            if (myBounds == null) {
                myBounds = newBound;
                continue;
View Full Code Here

Examples of org.apache.camel.osgi.CamelContextFactory.createContext()

        LOG.info("Creating the CamelContext ...");
        setThreadContextClassLoader();
        CamelContextFactory factory = new CamelContextFactory();
        factory.setBundleContext(bundleContext);
        LOG.info("Get the bundleContext is " + bundleContext);
        return factory.createContext();
    }

    protected void setThreadContextClassLoader() {
        // set the thread context classloader current bundle classloader
        Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());
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.