Package org.jboss.aop.joinpoint

Examples of org.jboss.aop.joinpoint.MethodInvocation


      return producerDelegate;
   }

   public Object handleCreateBrowserDelegate(Invocation invocation) throws Throwable
   {
      MethodInvocation mi = (MethodInvocation)invocation;

      ClientBrowserDelegate browserDelegate = (ClientBrowserDelegate)invocation.invokeNext();
      DelegateSupport delegate = (DelegateSupport)browserDelegate;

      SessionState sessionState = (SessionState)getState(invocation);

      JBossDestination destination = (JBossDestination)mi.getArguments()[0];
      String selector = (String)mi.getArguments()[1];

      BrowserState state =
         new BrowserState(sessionState, browserDelegate, destination, selector);

      delegate.setState(state);
View Full Code Here


      if (type==NULL)
      {
         return invocation.invokeNext();
      }
     
      MethodInvocation mi = (MethodInvocation)invocation;
      String methodName = mi.getMethod().getName();
      Object target = mi.getTargetObject();

      log.info("Invoke target=" + target.getClass().getName() + " method = " + methodName);

      if (target instanceof ConnectionAdvised && "createSessionDelegate".equals(methodName)
             && type == TYPE_CREATE_SESSION)
      {
         // Used by the failover tests to kill server in the middle of an invocation.

         log.info("##### Crashing on createSessionDelegate!!");
        
         crash(target);
      }
      else if (target instanceof ConnectionAdvised && "sendTransaction".equals(methodName))
      {
         TransactionRequest request = (TransactionRequest)mi.getArguments()[0];
        
         if (request.getRequestType() == TransactionRequest.TWO_PHASE_COMMIT_REQUEST
             && type == TYPE_2PC_COMMIT)
         {
            //Crash before 2pc commit (after prepare)- used in message bridge tests
View Full Code Here

      System.out.println("--- ScopedInterceptor intercepting " + getClass().getClassLoader());
      intercepted++;
     
      if (invocation instanceof MethodInvocation)
      {
         MethodInvocation mi = (MethodInvocation)invocation;
         if (mi.getMethod().getName().equals("testMethod"))
         {
            return null;
         }
      }
     
View Full Code Here

//      System.out.println("--- ScopedPCInterceptor intercepting " + getClass().getClassLoader());
      intercepted++;
     
      if (invocation instanceof MethodInvocation)
      {
         MethodInvocation mi = (MethodInvocation)invocation;
         if (mi.getMethod().getName().equals("testMethod"))
         {
            return null;
         }
      }
     
View Full Code Here

//      System.out.println("--- ScopedInterceptor intercepting " + getClass().getClassLoader());
      intercepted++;
     
      if (invocation instanceof MethodInvocation)
      {
         MethodInvocation mi = (MethodInvocation)invocation;
         if (mi.getMethod().getName().equals("testMethod"))
         {
            return null;
         }
      }
     
View Full Code Here

//      System.out.println("--- ScopedPJInterceptor intercepting " + getClass().getClassLoader());
      intercepted++;
     
      if (invocation instanceof MethodInvocation)
      {
         MethodInvocation mi = (MethodInvocation)invocation;
         if (mi.getMethod().getName().equals("testMethod"))
         {
            return null;
         }
      }
     
View Full Code Here

//      System.out.println("--- ScopedPCJInterceptor intercepting " + getClass().getClassLoader());
      intercepted++;
     
      if (invocation instanceof MethodInvocation)
      {
         MethodInvocation mi = (MethodInvocation)invocation;
         if (mi.getMethod().getName().equals("testMethod"))
         {
            return null;
         }
      }
     
View Full Code Here

  
   public static SimpleMetaData metaData;
  
   public Object invoke(Invocation invocation) throws Throwable
   {
      MethodInvocation mi = (MethodInvocation) invocation;
      invoked = mi.getMethod();
      metaData = mi.getMetaData();
      return null;
   }
View Full Code Here

  
   public static SimpleMetaData metaData;
  
   public Object invoke(Invocation invocation) throws Throwable
   {
      MethodInvocation mi = (MethodInvocation) invocation;
      invoked = mi.getMethod();
      metaData = mi.getMetaData();
      return invocation.invokeNext();
   }
View Full Code Here

      // Get the invocation the handler set
      Invocation inv = activeInvocation.get();
      if(inv instanceof MethodInvocation)
      {
         // Need to set the target since this is not a true aop proxy
         MethodInvocation mi = (MethodInvocation) inv;
         mi.setTargetObject(target);
         // Override the method to the poji proxy method to return the invocation method
         inv = new PojiMethodInvocation(mi, method);
      }

      // run through the interceptors
View Full Code Here

TOP

Related Classes of org.jboss.aop.joinpoint.MethodInvocation

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.