Java Doc for BasicEjbHome.java in  » Testing » MockEJB » org » mockejb » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Testing » MockEJB » org.mockejb 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.mockejb.BasicEjbHome

All known Subclasses:   org.mockejb.EntityBeanHome,  org.mockejb.MDBHome,  org.mockejb.SessionBeanHome,
BasicEjbHome
abstract class BasicEjbHome implements InvocationHandler,Serializable(Code)
Base class for concrete Home implementations. Creates proxy for home interface and calls "create" method. "create" must be defined by the subclasses.
author:
   Alexander Ananiev


Field Summary
protected  InterceptorInvokerinterceptorInvoker
    

Constructor Summary
 BasicEjbHome(BasicEjbDescriptor descriptor)
    

Method Summary
abstract public  Objectcreate(BasicEjbDescriptor descriptor, MockEjbObject ejbObject, Method homeMethod, Object[] paramVals)
     Implementors of this method must create an instance of a bean (if needed) and call the required EJB lifecycle methods.
protected  ObjectcreateBean(BasicEjbDescriptor descriptor)
     Helper method to create a bean instance.
public  ObjectcreateProxy()
    
public  booleanequals(Object obj)
     If the object is a proxy, the pointer equality is used.
public  EJBMetaDatagetEJBMetaData()
    
public  HomeHandlegetHomeHandle()
    
protected  ObjectgetHomeProxy()
    
public  inthashCode()
    
public  Objectinvoke(Object thisProxy, Method homeMethod, Object[] paramVals)
    
protected  ObjectinvokeBeanCreateMethod(Object bean, Method createMethod, Object[] paramVals)
     Invokes "ejbCreate" method of a bean.
protected  ObjectinvokeBeanMethod(Object bean, Method homeMethod, String methodName, Class[] paramTypes, Object[] paramVals)
     Finds a method of the bean using reflection and calls InterceptorInvoker to find interceptors and call the target.
 ObjectinvokeBeanMethod(Object bean, Method homeMethod, String methodName)
    
protected  ObjectinvokeBeanMethodWithPrefix(String prefix, Object bean, Method homeMethod, Object[] paramVals)
    
abstract public  ObjectinvokeHomeMethod(BasicEjbDescriptor descriptor, Method homeMethod, Object[] paramVals)
     Implementors of this method can invoke home methods other than create and remove suitable for their EJB type, such as ejbFind for entity bean. If the EJB type only supports create and remove methods, this method must throw exception.
protected  ObjectinvokeNewInstance(Class beanClass)
    
public  voidremove(Object obj)
     This method is not implemented by this class.
protected  voidthrowMethodNotImplemented(String methodName)
    
public  StringtoString()
    

Field Detail
interceptorInvoker
protected InterceptorInvoker interceptorInvoker(Code)




Constructor Detail
BasicEjbHome
BasicEjbHome(BasicEjbDescriptor descriptor)(Code)




Method Detail
create
abstract public Object create(BasicEjbDescriptor descriptor, MockEjbObject ejbObject, Method homeMethod, Object[] paramVals) throws Exception(Code)
Implementors of this method must create an instance of a bean (if needed) and call the required EJB lifecycle methods.
Parameters:
  descriptor -
Parameters:
  ejbObject -
Parameters:
  homeMethod -
Parameters:
  paramVals - Proxy created by the EjbObject ready to be returned to the client.



createBean
protected Object createBean(BasicEjbDescriptor descriptor)(Code)
Helper method to create a bean instance. If the bean object is passed in the descriptor simply returns it, otherwise calls newInstance.
Parameters:
  descriptor - EJB descriptor bean object



createProxy
public Object createProxy()(Code)
Creates a new instance



equals
public boolean equals(Object obj)(Code)
If the object is a proxy, the pointer equality is used. Otherwise, super.equals is called.



getEJBMetaData
public EJBMetaData getEJBMetaData() throws RemoteException(Code)



getHomeHandle
public HomeHandle getHomeHandle() throws RemoteException(Code)



getHomeProxy
protected Object getHomeProxy()(Code)



hashCode
public int hashCode()(Code)



invoke
public Object invoke(Object thisProxy, Method homeMethod, Object[] paramVals) throws Throwable(Code)
Handles calls to Home methods



invokeBeanCreateMethod
protected Object invokeBeanCreateMethod(Object bean, Method createMethod, Object[] paramVals) throws Exception(Code)
Invokes "ejbCreate" method of a bean. Translate the name of the home create method to the appropriate "ejbCreate".
Parameters:
  bean - target bean object
Parameters:
  createMethod - create method of the home interface
Parameters:
  paramVals - parameters of the create method (for entity and stateful beans)



invokeBeanMethod
protected Object invokeBeanMethod(Object bean, Method homeMethod, String methodName, Class[] paramTypes, Object[] paramVals) throws Exception(Code)
Finds a method of the bean using reflection and calls InterceptorInvoker to find interceptors and call the target.
Parameters:
  bean - target bean object
Parameters:
  homeMethod - home method being callese
Parameters:
  methodName - name of the method of the target bean to call
Parameters:
  paramTypes - types of the parameters of the target method
Parameters:
  paramVals - parameters of the target method



invokeBeanMethod
Object invokeBeanMethod(Object bean, Method homeMethod, String methodName) throws Exception(Code)



invokeBeanMethodWithPrefix
protected Object invokeBeanMethodWithPrefix(String prefix, Object bean, Method homeMethod, Object[] paramVals) throws Exception(Code)



invokeHomeMethod
abstract public Object invokeHomeMethod(BasicEjbDescriptor descriptor, Method homeMethod, Object[] paramVals) throws Exception(Code)
Implementors of this method can invoke home methods other than create and remove suitable for their EJB type, such as ejbFind for entity bean. If the EJB type only supports create and remove methods, this method must throw exception.
Parameters:
  descriptor -
Parameters:
  ejbObject -
Parameters:
  homeMethod -
Parameters:
  paramVals - return value of the home method



invokeNewInstance
protected Object invokeNewInstance(Class beanClass)(Code)
Create an instance of a bean



remove
public void remove(Object obj) throws RemoveException(Code)
This method is not implemented by this class.



throwMethodNotImplemented
protected void throwMethodNotImplemented(String methodName)(Code)
Helper method to throw NotImplementedException for this class
Parameters:
  methodName -



toString
public String toString()(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.