|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.james.protocols.smtp.core.AbstractHookableCmdHandler<Hook>
public abstract class AbstractHookableCmdHandler<Hook>
Abstract class which Handle hook-aware CommanHandler.
| Constructor Summary | |
|---|---|
AbstractHookableCmdHandler()
|
|
| Method Summary | |
|---|---|
static SMTPResponse |
calcDefaultSMTPResponse(HookResult result)
Convert the HookResult to SMTPResponse using default values. |
protected abstract HookResult |
callHook(Hook rawHook,
SMTPSession session,
java.lang.String parameters)
Must be implemented by hookable cmd handlers to make the effective call to an hook. |
protected abstract SMTPResponse |
doCoreCmd(SMTPSession session,
java.lang.String command,
java.lang.String parameters)
Execute the core commandHandling. |
protected abstract SMTPResponse |
doFilterChecks(SMTPSession session,
java.lang.String command,
java.lang.String parameters)
Execute Syntax checks and return a SMTPResponse if a syntax error was detected, otherwise null. |
protected abstract java.lang.Class<Hook> |
getHookInterface()
Return the interface which hooks need to implement to hook in |
protected java.util.List<Hook> |
getHooks()
Return a list which holds all hooks for the cmdHandler |
java.util.List<java.lang.Class<?>> |
getMarkerInterfaces()
|
Response |
onCommand(SMTPSession session,
Request request)
Handle command processing |
void |
wireExtensions(java.lang.Class interfaceName,
java.util.List extension)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.james.protocols.api.CommandHandler |
|---|
getImplCommands |
| Constructor Detail |
|---|
public AbstractHookableCmdHandler()
| Method Detail |
|---|
public Response onCommand(SMTPSession session,
Request request)
onCommand in interface CommandHandler<SMTPSession>org.apache.james.smtpserver.protocol.CommandHandler#onCommand(org.apache.james.protocols.smtp.SMTPSession,
java.lang.String, java.lang.String)
protected abstract HookResult callHook(Hook rawHook,
SMTPSession session,
java.lang.String parameters)
rawHook - the hooksession - the sessionparameters - the parameters
public static SMTPResponse calcDefaultSMTPResponse(HookResult result)
result - HookResult
protected abstract SMTPResponse doFilterChecks(SMTPSession session,
java.lang.String command,
java.lang.String parameters)
session - command - parameters -
protected abstract SMTPResponse doCoreCmd(SMTPSession session,
java.lang.String command,
java.lang.String parameters)
session - command - parameters -
public java.util.List<java.lang.Class<?>> getMarkerInterfaces()
getMarkerInterfaces in interface ExtensibleHandlerExtensibleHandler.getMarkerInterfaces()protected abstract java.lang.Class<Hook> getHookInterface()
public void wireExtensions(java.lang.Class interfaceName,
java.util.List extension)
wireExtensions in interface ExtensibleHandlerExtensibleHandler.wireExtensions(java.lang.Class,
java.util.List)protected java.util.List<Hook> getHooks()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||