org.apache.james.jspf.terms
Class GenericModifier

java.lang.Object
  extended by org.apache.james.jspf.terms.GenericModifier
All Implemented Interfaces:
LogEnabled, SPFChecker, ConfigurationEnabled, Modifier
Direct Known Subclasses:
ExpModifier, RedirectModifier

public abstract class GenericModifier
extends java.lang.Object
implements Modifier, ConfigurationEnabled, LogEnabled

This abstract class represent a gerneric modifier


Field Summary
protected  Logger log
           
 
Constructor Summary
GenericModifier()
           
 
Method Summary
 DNSLookupContinuation checkSPF(SPFSession spfData)
          Run check for SPF with the given values.
protected abstract  DNSLookupContinuation checkSPFLogged(SPFSession spfData)
           
 void config(Configuration params)
          Configuration
 void enableLogging(Logger logger)
          Provide component with a logger.
 boolean enforceSingleInstance()
          Return true if the Modifier is only allowed once
protected  java.lang.String getHost()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected Logger log
Constructor Detail

GenericModifier

public GenericModifier()
Method Detail

checkSPF

public DNSLookupContinuation checkSPF(SPFSession spfData)
                               throws PermErrorException,
                                      TempErrorException,
                                      NeutralException,
                                      NoneException
Description copied from interface: SPFChecker
Run check for SPF with the given values.

Specified by:
checkSPF in interface SPFChecker
Parameters:
spfData - The SPF1Data which should be used to run the check
Throws:
PermErrorException - Get thrown if an error was detected
TempErrorException - Get thrown if a DNS problem was detected
NeutralException - Get thrown if the result should be neutral
NoneException - Get thrown if no Record was found
See Also:
SPFChecker.checkSPF(org.apache.james.jspf.core.SPFSession)

checkSPFLogged

protected abstract DNSLookupContinuation checkSPFLogged(SPFSession spfData)
                                                 throws PermErrorException,
                                                        TempErrorException,
                                                        NeutralException,
                                                        NoneException
Throws:
PermErrorException
TempErrorException
NeutralException
NoneException

enforceSingleInstance

public boolean enforceSingleInstance()
Description copied from interface: Modifier
Return true if the Modifier is only allowed once

Specified by:
enforceSingleInstance in interface Modifier
Returns:
true if only one instance of this modifier is allowed
See Also:
Modifier.enforceSingleInstance()

config

public void config(Configuration params)
            throws PermErrorException
Description copied from interface: ConfigurationEnabled
Configuration

Specified by:
config in interface ConfigurationEnabled
Parameters:
params - the ConfigurationMatch which should used
Throws:
PermErrorException - get thrown if a PermError should returned
See Also:
ConfigurationEnabled.config(Configuration)

getHost

protected java.lang.String getHost()
Returns:
Returns the host.

enableLogging

public void enableLogging(Logger logger)
Description copied from interface: LogEnabled
Provide component with a logger.

Specified by:
enableLogging in interface LogEnabled
Parameters:
logger - the logger. Must not be null.
See Also:
LogEnabled.enableLogging(org.apache.james.jspf.core.Logger)


Copyright © 2006-2009 The Apache Software Foundation. All Rights Reserved.