com.mockrunner.mock.connector.cci
Class ConnectorMockObjectFactory

java.lang.Object
  extended by com.mockrunner.mock.connector.cci.ConnectorMockObjectFactory

public class ConnectorMockObjectFactory
extends java.lang.Object

Used to create all types of JCA mock objects. Maintains the necessary dependencies between the mock objects. If you use the mock objects returned by this factory in your tests you can be sure that they are all up to date. If you are using JNDI for obtaining the MockConnectionFactory you have to bind them to the mock JNDI context with EJBTestModule.bindToContext(java.lang.String, java.lang.Object).


Constructor Summary
ConnectorMockObjectFactory()
           
 
Method Summary
 MockConnection createMockConnection()
          Creates the MockConnection using new.
 MockConnectionFactory createMockConnectionFactory()
          Creates the MockConnectionFactory using new.
 InteractionHandler getInteractionHandler()
          Returns the InteractionHandler.
 MockConnection getMockConnection()
          Returns the MockConnection.
 MockConnectionFactory getMockConnectionFactory()
          Returns the MockConnectionFactory.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConnectorMockObjectFactory

public ConnectorMockObjectFactory()
Method Detail

createMockConnection

public MockConnection createMockConnection()
Creates the MockConnection using new. This method can be overridden to return a subclass of MockConnection.

Returns:
the MockConnection

createMockConnectionFactory

public MockConnectionFactory createMockConnectionFactory()
Creates the MockConnectionFactory using new. This method can be overridden to return a subclass of MockConnectionFactory.

Returns:
the MockConnectionFactory

getMockConnection

public MockConnection getMockConnection()
Returns the MockConnection.

Returns:
the MockConnection

getMockConnectionFactory

public MockConnectionFactory getMockConnectionFactory()
Returns the MockConnectionFactory.

Returns:
the MockConnectionFactory

getInteractionHandler

public InteractionHandler getInteractionHandler()
Returns the InteractionHandler.

Returns:
the InteractionHandler