Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.mockobjects.jms
Class MockConnection  view MockConnection download MockConnection.java

java.lang.Object
  extended bycom.mockobjects.MockObject
      extended bycom.mockobjects.jms.MockConnection
All Implemented Interfaces:
javax.jms.Connection, com.mockobjects.Verifiable
Direct Known Subclasses:
MockQueueConnection, MockTopicConnection

public class MockConnection
extends com.mockobjects.MockObject
implements javax.jms.Connection


Field Summary
protected  com.mockobjects.ExpectationCounter myCloseCalls
           
private  javax.jms.JMSException myException
           
protected  com.mockobjects.ExpectationCounter myStartCalls
           
protected  com.mockobjects.ExpectationCounter myStopCalls
           
 
Constructor Summary
MockConnection()
           
 
Method Summary
 void close()
           
 java.lang.String getClientID()
           
 javax.jms.ExceptionListener getExceptionListener()
           
 javax.jms.ConnectionMetaData getMetaData()
           
 void setClientID(java.lang.String clientID)
           
 void setExceptionListener(javax.jms.ExceptionListener listener)
           
 void setExpectedCloseCalls(int callCount)
           
 void setExpectedStartCalls(int callCount)
           
 void setExpectedStopCalls(int callCount)
           
 void setupThrowException(javax.jms.JMSException e)
           
 void start()
           
 void stop()
           
protected  void throwExceptionIfAny()
           
 
Methods inherited from class com.mockobjects.MockObject
assertEquals, assertEquals, assertTrue, fail, notImplemented, notYetImplemented, notYetImplemented, verify
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.jms.Connection
createConnectionConsumer, createDurableConnectionConsumer, createSession
 

Field Detail

myCloseCalls

protected com.mockobjects.ExpectationCounter myCloseCalls

myStartCalls

protected com.mockobjects.ExpectationCounter myStartCalls

myStopCalls

protected com.mockobjects.ExpectationCounter myStopCalls

myException

private javax.jms.JMSException myException
Constructor Detail

MockConnection

public MockConnection()
Method Detail

close

public void close()
           throws javax.jms.JMSException
Specified by:
close in interface javax.jms.Connection

getClientID

public java.lang.String getClientID()
                             throws javax.jms.JMSException
Specified by:
getClientID in interface javax.jms.Connection

getExceptionListener

public javax.jms.ExceptionListener getExceptionListener()
                                                 throws javax.jms.JMSException
Specified by:
getExceptionListener in interface javax.jms.Connection

getMetaData

public javax.jms.ConnectionMetaData getMetaData()
                                         throws javax.jms.JMSException
Specified by:
getMetaData in interface javax.jms.Connection

setClientID

public void setClientID(java.lang.String clientID)
                 throws javax.jms.JMSException
Specified by:
setClientID in interface javax.jms.Connection

setExceptionListener

public void setExceptionListener(javax.jms.ExceptionListener listener)
                          throws javax.jms.JMSException
Specified by:
setExceptionListener in interface javax.jms.Connection

start

public void start()
           throws javax.jms.JMSException
Specified by:
start in interface javax.jms.Connection

stop

public void stop()
          throws javax.jms.JMSException
Specified by:
stop in interface javax.jms.Connection

setExpectedCloseCalls

public void setExpectedCloseCalls(int callCount)

setExpectedStartCalls

public void setExpectedStartCalls(int callCount)

setExpectedStopCalls

public void setExpectedStopCalls(int callCount)

setupThrowException

public void setupThrowException(javax.jms.JMSException e)

throwExceptionIfAny

protected void throwExceptionIfAny()
                            throws javax.jms.JMSException