public class IncludeMechanism extends Object implements Mechanism, ConfigurationEnabled, LogEnabled, SPFCheckEnabled, MacroExpandEnabled
Modifier and Type | Field and Description |
---|---|
protected String |
host |
protected Logger |
log |
static String |
REGEX
ABNF: include = "include" ":" domain-spec
|
Constructor and Description |
---|
IncludeMechanism() |
Modifier and Type | Method and Description |
---|---|
DNSLookupContinuation |
checkSPF(SPFSession spfData)
Run check for SPF with the given values.
|
void |
config(Configuration params)
Configuration
|
void |
enableLogging(Logger logger)
Provide component with a logger.
|
void |
enableMacroExpand(MacroExpand macroExpand)
Provide component with a DNSService.
|
void |
enableSPFChecking(SPFChecker checker)
Provide component with an SPF Checker.
|
protected String |
getHost() |
String |
toString() |
public static final String REGEX
protected String host
protected Logger log
public DNSLookupContinuation checkSPF(SPFSession spfData) throws PermErrorException, TempErrorException, NoneException, NeutralException
SPFChecker
checkSPF
in interface SPFChecker
spfData
- The SPF1Data which should be used to run the checkPermErrorException
- Get thrown if an error was detectedTempErrorException
- Get thrown if a DNS problem was detectedNoneException
- Get thrown if no Record was foundNeutralException
- Get thrown if the result should be neutralSPFChecker.checkSPF(org.apache.james.jspf.core.SPFSession)
public void config(Configuration params) throws PermErrorException
ConfigurationEnabled
config
in interface ConfigurationEnabled
params
- the ConfigurationMatch which should usedPermErrorException
- get thrown if a PermError should returnedConfigurationEnabled.config(Configuration)
protected String getHost()
public void enableLogging(Logger logger)
LogEnabled
enableLogging
in interface LogEnabled
logger
- the logger. Must not be null
.LogEnabled.enableLogging(org.apache.james.jspf.core.Logger)
public String toString()
toString
in class Object
Object.toString()
public void enableSPFChecking(SPFChecker checker)
SPFCheckEnabled
enableSPFChecking
in interface SPFCheckEnabled
checker
- the checker. Must not be null
.SPFCheckEnabled.enableSPFChecking(org.apache.james.jspf.core.SPFChecker)
public void enableMacroExpand(MacroExpand macroExpand)
MacroExpandEnabled
enableMacroExpand
in interface MacroExpandEnabled
macroExpand
- the macroExpand service. Must not be null
.MacroExpandEnabled.enableMacroExpand(org.apache.james.jspf.core.MacroExpand)
Copyright © 2006–2016 The Apache Software Foundation. All rights reserved.