org.apache.james.smtpserver.core.filter.fastfail
Class MaxRcptHandler

java.lang.Object
  extended by org.apache.avalon.framework.logger.AbstractLogEnabled
      extended by org.apache.james.smtpserver.core.filter.fastfail.AbstractJunkHandler
          extended by org.apache.james.smtpserver.core.filter.fastfail.MaxRcptHandler
All Implemented Interfaces:
org.apache.avalon.framework.configuration.Configurable, org.apache.avalon.framework.logger.LogEnabled, CommandHandler

public class MaxRcptHandler
extends AbstractJunkHandler
implements CommandHandler, org.apache.avalon.framework.configuration.Configurable


Constructor Summary
MaxRcptHandler()
           
 
Method Summary
protected  boolean check(SMTPSession session)
          All checks must be done in this method
 void configure(org.apache.avalon.framework.configuration.Configuration handlerConfiguration)
           
 java.util.Collection getImplCommands()
          Return a Collection of implemented commands
 JunkHandlerData getJunkHandlerData(SMTPSession session)
          Get the JunkHandlerData to work with
 void onCommand(SMTPSession session)
          Handle the command
 void setMaxRcpt(int maxRcpt)
          Set the max rcpt for wich should be accepted
 
Methods inherited from class org.apache.james.smtpserver.core.filter.fastfail.AbstractJunkHandler
doProcessing, getAction, getJunkScore, getScore, setAction, setScore
 
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MaxRcptHandler

public MaxRcptHandler()
Method Detail

configure

public void configure(org.apache.avalon.framework.configuration.Configuration handlerConfiguration)
               throws org.apache.avalon.framework.configuration.ConfigurationException
Specified by:
configure in interface org.apache.avalon.framework.configuration.Configurable
Overrides:
configure in class AbstractJunkHandler
Throws:
org.apache.avalon.framework.configuration.ConfigurationException
See Also:
Configurable.configure(Configuration)

setMaxRcpt

public void setMaxRcpt(int maxRcpt)
Set the max rcpt for wich should be accepted

Parameters:
maxRcpt - The max rcpt count

onCommand

public void onCommand(SMTPSession session)
Description copied from interface: CommandHandler
Handle the command

Specified by:
onCommand in interface CommandHandler
See Also:
CommandHandler.onCommand(SMTPSession)

getImplCommands

public java.util.Collection getImplCommands()
Description copied from interface: CommandHandler
Return a Collection of implemented commands

Specified by:
getImplCommands in interface CommandHandler
Returns:
Collection which contains implemented commands
See Also:
CommandHandler.getImplCommands()

check

protected boolean check(SMTPSession session)
Description copied from class: AbstractJunkHandler
All checks must be done in this method

Specified by:
check in class AbstractJunkHandler
Parameters:
session - the SMTPSession
Returns:
true if the check match
See Also:
AbstractJunkHandler.check(org.apache.james.smtpserver.SMTPSession)

getJunkHandlerData

public JunkHandlerData getJunkHandlerData(SMTPSession session)
Description copied from class: AbstractJunkHandler
Get the JunkHandlerData to work with

Specified by:
getJunkHandlerData in class AbstractJunkHandler
Parameters:
session - the SMTPSession
Returns:
junkHandlerData
See Also:
AbstractJunkHandler.getJunkHandlerData(org.apache.james.smtpserver.SMTPSession)


Copyright ? 2002-2009 The Apache Software Foundation. All Rights Reserved.