Package com.sun.jersey.api.core

Examples of com.sun.jersey.api.core.DefaultResourceConfig


                    && (originalApp.getSingletons() == null || originalApp.getSingletons().isEmpty())) {

                LOGGER.info("Instantiated the Application class " + appClass.getName() +
                        ". The following root resource and provider classes are registered: " + defaultClasses);

                this.adaptedApp = new DefaultResourceConfig(defaultClasses);
                adaptedApp.add(originalApp);
            } else {
                LOGGER.info("Instantiated the Application class " + appClass.getName());
                adaptedApp = null;
            }
View Full Code Here


            return Response.ok("SUCCESS:  All tests passed").build();
        }
    }

    public void testConsumesFormDataResource() {
        ResourceConfig rc = new DefaultResourceConfig(ConsumesFormDataResource.class,
                MultiPartBeanProvider.class);
        List l = rc.getContainerRequestFilters();
        l.add(MyFilter.class);
        startServer(rc);

        WebResource.Builder builder = client.resource(getUri()).
                accept("text/plain").type("multipart/form-data");
View Full Code Here

        context = new ServiceDetailsDiscoveryContext(new MockServiceDiscovery<ServiceDetails>(), new RandomStrategy<ServiceDetails>(), 1000);
        serviceNamesMarshaller = new JsonServiceNamesMarshaller();
        serviceInstanceMarshaller = new JsonServiceInstanceMarshaller<ServiceDetails>(context);
        serviceInstancesMarshaller = new JsonServiceInstancesMarshaller<ServiceDetails>(context);

        Application                                     application = new DefaultResourceConfig()
        {
            @Override
            public Set<Class<?>> getClasses()
            {
                Set<Class<?>>       classes = Sets.newHashSet();
View Full Code Here

        context = new MapDiscoveryContext(new MockServiceDiscovery<Map<String, String>>(), new RandomStrategy<Map<String, String>>(), 1000);
        serviceNamesMarshaller = new JsonServiceNamesMarshaller();
        serviceInstanceMarshaller = new JsonServiceInstanceMarshaller<Map<String, String>>(context);
        serviceInstancesMarshaller = new JsonServiceInstancesMarshaller<Map<String, String>>(context);

        Application                                     application = new DefaultResourceConfig()
        {
            @Override
            public Set<Class<?>> getClasses()
            {
                Set<Class<?>>       classes = Sets.newHashSet();
View Full Code Here

        context = new StringDiscoveryContext(new MockServiceDiscovery<String>(), new RandomStrategy<String>(), 1000);
        serviceNamesMarshaller = new JsonServiceNamesMarshaller();
        serviceInstanceMarshaller = new JsonServiceInstanceMarshaller<String>(context);
        serviceInstancesMarshaller = new JsonServiceInstancesMarshaller<String>(context);

        Application                                     application = new DefaultResourceConfig()
        {
            @Override
            public Set<Class<?>> getClasses()
            {
                Set<Class<?>>       classes = Sets.newHashSet();
View Full Code Here

    }

    @Override
    protected ResourceConfig getDefaultResourceConfig(Map<String, Object> props, ServletConfig servletConfig)
            throws ServletException {
        DefaultResourceConfig rc = new DefaultResourceConfig();
        rc.setPropertiesAndFeatures(props);
        return rc;
    }
View Full Code Here

  public long submit(Command cmd) {
    return cmdman.submit(cmd);
  }

  ServletContainer jerseyMasterServlet() {
    Application app = new DefaultResourceConfig(FlumeMasterResource
        .getResources());
    ServletContainer sc = new ServletContainer(app);

    return sc;
  }
View Full Code Here

    }
    return webPath;
  }

  ServletContainer jerseyNodeServlet() {
    Application app = new DefaultResourceConfig(NodeReportResource.class);
    ServletContainer sc = new ServletContainer(app);
    return sc;
  }
View Full Code Here

    @Override
    protected ResourceConfig getDefaultResourceConfig(
        Map<String, Object> props, WebConfig webConfig
    ) throws ServletException
    {
      return new DefaultResourceConfig(resources);
    }
View Full Code Here

    }

    @Override
    protected ResourceConfig getDefaultResourceConfig(Map<String, Object> props, WebConfig webConfig)
            throws ServletException {
        return new DefaultResourceConfig();
    }
View Full Code Here

TOP

Related Classes of com.sun.jersey.api.core.DefaultResourceConfig

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.