Package org.jboss.proxy

Examples of org.jboss.proxy.IClientContainer


   {
      log.info("+++ testClientContainer");
      InitialContext ctx = new InitialContext();
      BusinessObjectHome home = (BusinessObjectHome)ctx.lookup("BusinessSession");
      // Check the IClientContainer interface
      IClientContainer container = (IClientContainer) home;
      ArrayList interceptors = container.getInterceptors();
      for(int n = 0; n < interceptors.size(); n ++)
      {
         log.info(interceptors.get(n));
      }
      BusinessObject bean = home.create();
      container = (IClientContainer) bean;
      interceptors = container.getInterceptors();
      for(int n = 0; n < interceptors.size(); n ++)
      {
         log.info(interceptors.get(n));
      }
      // Replace the default InvokerInterceptor
      int last = interceptors.size() - 1;
      interceptors.set(last, new InvokerInterceptor());
      container.setInterceptors(interceptors);

      // Invoke over the rpc transport
      bean.doSomething();
      // Invoker over the jms transport
      String reply = bean.doSomethingSlowly("arg1", "arg2");
View Full Code Here


   {
      log.info("+++ testClientContainer");
      InitialContext ctx = new InitialContext();
      BusinessObjectHome home = (BusinessObjectHome)ctx.lookup("BusinessSession");
      // Check the IClientContainer interface
      IClientContainer container = (IClientContainer) home;
      ArrayList interceptors = container.getInterceptors();
      for(int n = 0; n < interceptors.size(); n ++)
      {
         log.info(interceptors.get(n));
      }
      BusinessObject bean = home.create();
      container = (IClientContainer) bean;
      interceptors = container.getInterceptors();
      for(int n = 0; n < interceptors.size(); n ++)
      {
         log.info(interceptors.get(n));
      }
      // Replace the default InvokerInterceptor
      int last = interceptors.size() - 1;
      interceptors.set(last, new InvokerInterceptor());
      container.setInterceptors(interceptors);

      // Invoke over the rpc transport
      bean.doSomething();
      // Invoker over the jms transport
      String reply = bean.doSomethingSlowly("arg1", "arg2");
View Full Code Here

TOP

Related Classes of org.jboss.proxy.IClientContainer

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.