org.apache.james.transport.mailets
Class CommandListservFooter

java.lang.Object
  extended by org.apache.mailet.GenericMailet
      extended by org.apache.james.transport.mailets.AbstractAddFooter
          extended by org.apache.james.transport.mailets.CommandListservFooter
All Implemented Interfaces:
Mailet, MailetConfig

public class CommandListservFooter
extends AbstractAddFooter

CommandListservFooter is based on the AddFooter mailet. It is used by the CommandListservProcessor to inject a footer into mailing list.

Since:
2.2.0
Version:
CVS $Revision: 413813 $ $Date: 2006-06-13 06:09:36 +0000 (mar, 13 giu 2006) $
See Also:
XMLResources

Field Summary
protected  ICommandListservManager commandListservManager
          The list serv manager
protected  java.lang.String footerHtml
           
protected  java.lang.String footerText
           
protected  org.apache.oro.text.regex.Pattern insertPattern
           
protected  org.apache.oro.text.regex.Pattern newlinePattern
           
protected  org.apache.oro.text.regex.Perl5Compiler perl5Compiler
          For matching
protected static int TEXT_HTML
           
protected static int TEXT_PLAIN
           
protected  XMLResources[] xmlResources
           
 
Constructor Summary
CommandListservFooter(ICommandListservManager commandListservManager)
           
 
Method Summary
protected  java.lang.String getFooterHTML()
          Get and cache the footer html text
protected  java.lang.String getFooterText()
          Get and cache the footer text
protected  java.lang.String getFormattedText(int index)
           
 java.lang.String getMailetInfo()
          Return a string describing this mailet.
 void init()
          Initialize the mailet
 
Methods inherited from class org.apache.james.transport.mailets.AbstractAddFooter
addToHTML, addToText, attachFooter, service
 
Methods inherited from class org.apache.mailet.GenericMailet
destroy, getInitParameter, getInitParameter, getInitParameterNames, getMailetConfig, getMailetContext, getMailetName, init, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

footerText

protected java.lang.String footerText

footerHtml

protected java.lang.String footerHtml

commandListservManager

protected ICommandListservManager commandListservManager
The list serv manager


perl5Compiler

protected org.apache.oro.text.regex.Perl5Compiler perl5Compiler
For matching


insertPattern

protected org.apache.oro.text.regex.Pattern insertPattern

newlinePattern

protected org.apache.oro.text.regex.Pattern newlinePattern

xmlResources

protected XMLResources[] xmlResources

TEXT_PLAIN

protected static final int TEXT_PLAIN
See Also:
Constant Field Values

TEXT_HTML

protected static final int TEXT_HTML
See Also:
Constant Field Values
Constructor Detail

CommandListservFooter

public CommandListservFooter(ICommandListservManager commandListservManager)
Method Detail

init

public void init()
          throws javax.mail.MessagingException
Initialize the mailet

Overrides:
init in class GenericMailet
Throws:
javax.mail.MessagingException - if an exception occurs that interrupts the mailet's normal operation

getMailetInfo

public java.lang.String getMailetInfo()
Return a string describing this mailet.

Specified by:
getMailetInfo in interface Mailet
Overrides:
getMailetInfo in class GenericMailet
Returns:
a string describing this mailet

getFooterText

protected java.lang.String getFooterText()
Get and cache the footer text

Specified by:
getFooterText in class AbstractAddFooter
Returns:
the footer text
See Also:
XMLResources

getFooterHTML

protected java.lang.String getFooterHTML()
Get and cache the footer html text

Specified by:
getFooterHTML in class AbstractAddFooter
Returns:
the footer text
See Also:
XMLResources

getFormattedText

protected java.lang.String getFormattedText(int index)
Parameters:
index - either TEXT_PLAIN or TEXT_HTML
Returns:
a formatted text with the proper list and domain
See Also:
XMLResources.getString(java.lang.String)


Copyright © 2002-2007 The Apache Software Foundation. All Rights Reserved.