Package org.jboss.resteasy.cdi

Examples of org.jboss.resteasy.cdi.ResteasyCdiExtension


   private ResteasyCdiExtension extension;
  
   @Before
   public void prepare()
   {
      extension = new ResteasyCdiExtension();
   }
View Full Code Here


                        final ClassLoader classLoader = SecurityActions.getContextClassLoader();
                        try {
                            //MASSIVE HACK
                            //the resteasy Logger throws a NPE if the TCCL is null
                            SecurityActions.setContextClassLoader(ResteasyCdiExtension.class.getClassLoader());
                            final ResteasyCdiExtension ext = new ResteasyCdiExtension();
                            Metadata<Extension> metadata = new Metadata<Extension>() {
                                @Override
                                public Extension getValue() {
                                    return ext;
                                }
View Full Code Here

                        final ClassLoader classLoader = SecurityActions.getContextClassLoader();
                        try {
                            //MASSIVE HACK
                            //the resteasy Logger throws a NPE if the TCCL is null
                            SecurityActions.setContextClassLoader(ResteasyCdiExtension.class.getClassLoader());
                            final ResteasyCdiExtension ext = new ResteasyCdiExtension();
                            Metadata<Extension> metadata = new Metadata<Extension>() {
                                @Override
                                public Extension getValue() {
                                    return ext;
                                }
View Full Code Here

                        final ClassLoader classLoader = SecurityActions.getContextClassLoader();
                        try {
                            //MASSIVE HACK
                            //the resteasy Logger throws a NPE if the TCCL is null
                            SecurityActions.setContextClassLoader(ResteasyCdiExtension.class.getClassLoader());
                            final ResteasyCdiExtension ext = new ResteasyCdiExtension();
                            Metadata<Extension> metadata = new Metadata<Extension>() {
                                @Override
                                public Extension getValue() {
                                    return ext;
                                }
View Full Code Here

    }

    @Before
    public void init() {
        this.port = (int)((new Random().nextDouble() * 4000) + 1000);
        ResteasyCdiExtension cdiExtension = CDI.current().select(ResteasyCdiExtension.class).get();
        CdiNettyJaxrsServer netty = new CdiNettyJaxrsServer();
        ResteasyDeployment rd = new ResteasyDeployment();
        rd.setActualResourceClasses(cdiExtension.getResources());
        rd.setInjectorFactoryClass(CdiInjectorFactory.class.getName());
        rd.getActualProviderClasses().addAll(cdiExtension.getProviders());
        netty.setDeployment(rd);
        netty.setPort(port);
        netty.setRootResourcePath("/api");
        netty.start();
        this.server = netty;
View Full Code Here

   private ResteasyCdiExtension extension;
  
   @Before
   public void prepare()
   {
      extension = new ResteasyCdiExtension();
   }
View Full Code Here

TOP

Related Classes of org.jboss.resteasy.cdi.ResteasyCdiExtension

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.