public class EhloCmdHandler extends AbstractHookableCmdHandler<HeloHook> implements EhloExtension
Constructor and Description |
---|
EhloCmdHandler() |
Modifier and Type | Method and Description |
---|---|
protected HookResult |
callHook(HeloHook rawHook,
SMTPSession session,
String parameters)
Must be implemented by hookable cmd handlers to make the effective call to an hook.
|
protected Response |
doCoreCmd(SMTPSession session,
String command,
String parameters)
Execute the core commandHandling.
|
protected Response |
doFilterChecks(SMTPSession session,
String command,
String parameters)
Execute Syntax checks and return a SMTPResponse if a syntax error was
detected, otherwise null.
|
protected Class<HeloHook> |
getHookInterface()
Return the interface which hooks need to implement to hook in
|
Collection<String> |
getImplCommands()
Return a Collection of implemented commands
|
List<String> |
getImplementedEsmtpFeatures(SMTPSession session) |
List<Class<?>> |
getMarkerInterfaces()
Return a List of interfaces of plugins that will
extend this.
|
void |
wireExtensions(Class<?> interfaceName,
List<?> extension)
Method called during initialization after all the handlers have been declared
in the ProtocolHandlerChain.
|
calcDefaultSMTPResponse, getHooks, onCommand
public Collection<String> getImplCommands()
CommandHandler
getImplCommands
in interface CommandHandler<SMTPSession>
CommandHandler.getImplCommands()
public List<Class<?>> getMarkerInterfaces()
ExtensibleHandler
getMarkerInterfaces
in interface ExtensibleHandler
getMarkerInterfaces
in class AbstractHookableCmdHandler<HeloHook>
ExtensibleHandler.getMarkerInterfaces()
public void wireExtensions(Class<?> interfaceName, List<?> extension)
ExtensibleHandler
wireExtensions
in interface ExtensibleHandler
wireExtensions
in class AbstractHookableCmdHandler<HeloHook>
extension
- a list of objects implementing the marker interfaceExtensibleHandler.wireExtensions(java.lang.Class,
java.util.List)
protected Response doCoreCmd(SMTPSession session, String command, String parameters)
AbstractHookableCmdHandler
doCoreCmd
in class AbstractHookableCmdHandler<HeloHook>
AbstractHookableCmdHandler.doCoreCmd(org.apache.james.protocols.smtp.SMTPSession,
java.lang.String, java.lang.String)
protected Response doFilterChecks(SMTPSession session, String command, String parameters)
AbstractHookableCmdHandler
doFilterChecks
in class AbstractHookableCmdHandler<HeloHook>
null
AbstractHookableCmdHandler.doFilterChecks(org.apache.james.protocols.smtp.SMTPSession,
java.lang.String, java.lang.String)
protected Class<HeloHook> getHookInterface()
AbstractHookableCmdHandler
getHookInterface
in class AbstractHookableCmdHandler<HeloHook>
AbstractHookableCmdHandler.getHookInterface()
protected HookResult callHook(HeloHook rawHook, SMTPSession session, String parameters)
callHook
in class AbstractHookableCmdHandler<HeloHook>
rawHook
- the hooksession
- the sessionparameters
- the parameterspublic List<String> getImplementedEsmtpFeatures(SMTPSession session)
getImplementedEsmtpFeatures
in interface EhloExtension
EhloExtension.getImplementedEsmtpFeatures(org.apache.james.protocols.smtp.SMTPSession)
Copyright © 2010-2012 The Apache Software Foundation. All Rights Reserved.