1 22 package org.jboss.test.jmx.eardeployment.b.ejb; 24 25 26 import java.rmi.RemoteException ; 27 import javax.ejb.SessionBean ; 28 import javax.ejb.SessionContext ; 29 import javax.naming.InitialContext ; 30 import org.jboss.logging.Logger; 31 import org.jboss.test.jmx.eardeployment.a.interfaces.SessionA; 32 import org.jboss.test.jmx.eardeployment.a.interfaces.SessionAHome; 33 34 51 52 public class SessionBBean implements SessionBean { 53 54 59 public boolean callA() 60 { 61 try 62 { 63 SessionAHome ahome = (SessionAHome)new InitialContext ().lookup("eardeployment/SessionA"); 64 SessionA a = ahome.create(); 65 a.doNothing(); 66 return true; 67 } 68 catch (Exception e) 69 { 70 Logger.getLogger(getClass()).error("error in callA", e); 71 return false; 72 } 73 } 74 75 80 public void doNothing() 81 { 82 } 83 84 89 public void ejbCreate() 90 { 91 } 92 93 94 public void ejbActivate() throws RemoteException 95 { 96 } 97 98 public void ejbPassivate() throws RemoteException 99 { 100 } 101 102 public void ejbRemove() throws RemoteException 103 { 104 } 105 106 public void setSessionContext(SessionContext ctx) throws RemoteException 107 { 108 } 109 110 public void unsetSessionContext() throws RemoteException 111 { 112 } 113 114 } 115 116 | Popular Tags |