|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.mule.providers.AbstractMessageDispatcher
org.mule.providers.email.Pop3MessageDispatcher
Pop3MessageDispatcher For Pop3 connections the dispatcher can only
be used to receive message (as opposed to listening for them). Trying to send or
dispatch will throw an UnsupportedOperationException.
| Field Summary |
| Fields inherited from class org.mule.providers.AbstractMessageDispatcher |
connected, connectionStrategy, disposed, doThreading, endpoint, logger, workManager |
| Fields inherited from interface org.mule.umo.provider.UMOMessageDispatcher |
RECEIVE_NO_WAIT, RECEIVE_WAIT_INDEFINITELY |
| Constructor Summary | |
Pop3MessageDispatcher(UMOImmutableEndpoint endpoint)
|
|
| Method Summary | |
protected void |
doConnect(UMOImmutableEndpoint endpoint)
|
protected void |
doDisconnect()
|
protected void |
doDispatch(UMOEvent event)
|
protected void |
doDispose()
|
protected UMOMessage |
doReceive(UMOImmutableEndpoint endpoint,
long timeout)
Make a specific request to the underlying transport Endpoint can be in the form of pop3://username:password@pop3.lotsofmail.org |
protected UMOMessage |
doSend(UMOEvent event)
|
protected void |
flagMessage(Folder folder,
Message message)
There seems to be som variation on pop3 implementation so it may be preferrable to mark messages as seen here and alos overload the getMessages method to grab only new messages |
UMOConnector |
getConnector()
Gets the connector for this dispatcher |
Object |
getDelegateSession()
If the underlying transport has the notion of a client session when writing to it, the session should be obtainable using this method. |
protected int |
getMessageCount(Folder folder)
|
protected Message |
getNextMessage(Folder folder)
|
protected boolean |
hasMessages(Folder folder)
Optimised check to se whether to return the message count and retrieve the messages. |
| Methods inherited from class org.mule.providers.AbstractMessageDispatcher |
connect, disconnect, dispatch, dispose, exceptionThrown, getConnectEventId, getConnectionDescription, getOutputStream, isConnected, isDisposed, isTransactionRollback, receive, receive, reconnect, send, useRemoteSync |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public Pop3MessageDispatcher(UMOImmutableEndpoint endpoint)
| Method Detail |
protected void doConnect(UMOImmutableEndpoint endpoint)
throws Exception
doConnect in class AbstractMessageDispatcherException
protected void doDisconnect()
throws Exception
doDisconnect in class AbstractMessageDispatcherException
protected void doDispatch(UMOEvent event)
throws Exception
doDispatch in class AbstractMessageDispatcherevent -
UnsupportedOperationException
Exception
protected UMOMessage doSend(UMOEvent event)
throws Exception
doSend in class AbstractMessageDispatcherevent -
UnsupportedOperationException
Exception
protected UMOMessage doReceive(UMOImmutableEndpoint endpoint,
long timeout)
throws Exception
doReceive in class AbstractMessageDispatcherendpoint - the endpoint to use when connecting to the resourcetimeout - the maximum time the operation should block before returning.
The call should return immediately if there is data available. If
no data becomes available before the timeout elapses, null will be
returned
Exception - if the call to the underlying protocal cuases an exception
protected void flagMessage(Folder folder,
Message message)
throws MessagingException
message -
MessagingException
protected Message getNextMessage(Folder folder)
throws MessagingException
MessagingException
protected int getMessageCount(Folder folder)
throws MessagingException
MessagingException
protected boolean hasMessages(Folder folder)
throws MessagingException
folder -
MessagingException
public Object getDelegateSession()
throws UMOException
UMOMessageDispatcher
UMOExceptionpublic UMOConnector getConnector()
UMOMessageDispatcher
getConnector in interface UMOMessageDispatchergetConnector in class AbstractMessageDispatcherprotected void doDispose()
doDispose in class AbstractMessageDispatcher
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||