Package com.mockobjects.mail

# Class MockService

java.lang.Object
com.mockobjects.MockObject
com.mockobjects.mail.MockService

All Implemented Interfaces:
  `Service`, `Verifiable`

Direct Known Subclasses:
  `MockTransport`

public class MockService extends MockObject implements Service

## Constructor Summary

Constructors
Constructor
Description
`MockService()`

## Method Summary

Modifier and Type
Method
Description
`void`
`addConnectionListener(ConnectionListener connectionListener)`
`void`
`close()`
`void`
`connect()`
`void`
`connect(String aHost, int aPort, String aUser, String aPassword)`
`void`
`connect(String aHost, String aUser, String aPassword)`
`URLName`
`getURLName()`
`boolean`
`isConnected()`
`void`
`removeConnectionListener(ConnectionListener connectionListener)`
`void`
`setExpectedCloseCalls(int aNumberOfCalls)`

### Methods inherited from class com.mockobjects.MockObject

`notImplemented, notYetImplemented, verify`

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface alt.javax.mail.Service

`toString`

## Constructor Details

### MockService

public MockService()

## Method Details

### setExpectedCloseCalls

public void setExpectedCloseCalls(int aNumberOfCalls)

### close

public void close()

Specified by:
  `close` in interface `Service`

### connect

public void connect()

Specified by:
  `connect` in interface `Service`

### connect

public void connect(String aHost, int aPort, String aUser, String aPassword)

Specified by:
  `connect` in interface `Service`

### connect

public void connect(String aHost, String aUser, String aPassword)

Specified by:
  `connect` in interface `Service`

### isConnected

public boolean isConnected()

Specified by:
  `isConnected` in interface `Service`

### getURLName

public URLName getURLName()

Specified by:
  `getURLName` in interface `Service`

### addConnectionListener

public void addConnectionListener(ConnectionListener connectionListener)

Specified by:
  `addConnectionListener` in interface `Service`

### removeConnectionListener

public void removeConnectionListener(ConnectionListener connectionListener)

Specified by:
  `removeConnectionListener` in interface `Service`