|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.mina.core.service.IoHandlerAdapter
org.mailster.pop3.Pop3ProtocolHandler
public class Pop3ProtocolHandler
---
Mailster (C) 2007-2009 De Oliveira Edouard
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
See Mailster
Web Site
---
Pop3ProtocolHandler.java - Handles POP3 protocol communications.
| Field Summary | |
|---|---|
protected static java.lang.String |
CONNECTION
|
static int |
DEFAULT_TIMEOUT_SECONDS
|
private static java.lang.String |
LAST_INCOMPLETE_COMMAND
|
private static org.slf4j.Logger |
log
|
private static java.lang.String |
PEER_IS_CLOSING_SESSION
|
private boolean |
secureAuthRequired
|
private static java.lang.String |
SECURED_AUTH_REQUIRED
|
private static int |
timeout
|
private UserManager |
userManager
|
private static java.lang.String |
USING_APOP_AUTH
|
private boolean |
usingAPOPAuthMethod
|
| Constructor Summary | |
|---|---|
Pop3ProtocolHandler(UserManager userManager)
|
|
| Method Summary | |
|---|---|
void |
exceptionCaught(org.apache.mina.core.session.IoSession session,
java.lang.Throwable cause)
|
static int |
getTimeout()
Get the reader timeout in seconds. |
boolean |
isSecureAuthRequired(AbstractPop3Connection conn)
|
boolean |
isUsingAPOPAuthMethod(AbstractPop3Connection conn)
|
void |
messageReceived(org.apache.mina.core.session.IoSession session,
java.lang.Object message)
|
void |
quit(AbstractPop3Connection conn)
|
private void |
sendGreetings(MinaPop3Connection conn)
|
void |
sessionClosed(org.apache.mina.core.session.IoSession session)
|
void |
sessionCreated(org.apache.mina.core.session.IoSession session)
|
void |
sessionIdle(org.apache.mina.core.session.IoSession session,
org.apache.mina.core.session.IdleStatus status)
|
void |
setSecureAuthRequired(boolean secureAuthRequired)
|
static void |
setTimeout(int timeout)
Set the reader timeout for the new sessions. |
void |
setUsingAPOPAuthMethod(boolean usingAPOPAuthMethod)
|
| Methods inherited from class org.apache.mina.core.service.IoHandlerAdapter |
|---|
messageSent, sessionOpened |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final java.lang.String CONNECTION
private static final java.lang.String PEER_IS_CLOSING_SESSION
private static final java.lang.String USING_APOP_AUTH
private static final java.lang.String SECURED_AUTH_REQUIRED
private static final java.lang.String LAST_INCOMPLETE_COMMAND
public static final int DEFAULT_TIMEOUT_SECONDS
private static int timeout
private static final org.slf4j.Logger log
private UserManager userManager
private boolean usingAPOPAuthMethod
private boolean secureAuthRequired
| Constructor Detail |
|---|
public Pop3ProtocolHandler(UserManager userManager)
| Method Detail |
|---|
public void sessionCreated(org.apache.mina.core.session.IoSession session)
sessionCreated in interface org.apache.mina.core.service.IoHandlersessionCreated in class org.apache.mina.core.service.IoHandlerAdapter
public void sessionClosed(org.apache.mina.core.session.IoSession session)
throws java.lang.Exception
sessionClosed in interface org.apache.mina.core.service.IoHandlersessionClosed in class org.apache.mina.core.service.IoHandlerAdapterjava.lang.Exceptionprivate void sendGreetings(MinaPop3Connection conn)
public void sessionIdle(org.apache.mina.core.session.IoSession session,
org.apache.mina.core.session.IdleStatus status)
sessionIdle in interface org.apache.mina.core.service.IoHandlersessionIdle in class org.apache.mina.core.service.IoHandlerAdapter
public void exceptionCaught(org.apache.mina.core.session.IoSession session,
java.lang.Throwable cause)
exceptionCaught in interface org.apache.mina.core.service.IoHandlerexceptionCaught in class org.apache.mina.core.service.IoHandlerAdapter
public void messageReceived(org.apache.mina.core.session.IoSession session,
java.lang.Object message)
throws java.lang.Exception
messageReceived in interface org.apache.mina.core.service.IoHandlermessageReceived in class org.apache.mina.core.service.IoHandlerAdapterjava.lang.Exceptionpublic boolean isUsingAPOPAuthMethod(AbstractPop3Connection conn)
isUsingAPOPAuthMethod in interface AbstractPop3Handlerpublic boolean isSecureAuthRequired(AbstractPop3Connection conn)
isSecureAuthRequired in interface AbstractPop3Handlerpublic void setUsingAPOPAuthMethod(boolean usingAPOPAuthMethod)
public void setSecureAuthRequired(boolean secureAuthRequired)
public void quit(AbstractPop3Connection conn)
quit in interface AbstractPop3Handlerpublic static int getTimeout()
public static void setTimeout(int timeout)
timeout - timeout in seconds
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||