org.ploin.pmf.impl
Class MailReader

java.lang.Object
  extended by org.ploin.pmf.impl.MailReader
All Implemented Interfaces:
Serializable, IMailReader

public class MailReader
extends Object
implements Serializable, IMailReader

Description: Implementation of the IMailReader interface. This class offers methods for reading the template files.

$LastChangedBy: r.reiz $
$Revision: 77 $
$Date: 2010-03-15 13:13:45 +0100 (Mon, 15 Mar 2010) $

See Also:
Serialized Form

Constructor Summary
MailReader()
           
 
Method Summary
 String getDirectory()
          Returns the directory where the email-templates and the clients are in.
 String getHtmlExtension()
          returns the html extension.
 String getHtmlMail(TemplateConfig templateConfig)
          This method returns the html-mail-template to the mailName as String.
 String getPlainExtension()
          returns the plain extension.
 String getPlainMail(TemplateConfig templateConfig)
          This method returns the plain-mail template as String for a given mailName.
 void setDirectory(String directory)
          Set teh directory where the email-templates and the clients are in.
 void setHtmlExtension(String htmlExtension)
          Set the html extension.
 void setPlainExtension(String plainExtendsion)
          Set the plain extension.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MailReader

public MailReader()
Method Detail

getHtmlMail

public String getHtmlMail(TemplateConfig templateConfig)
                   throws MailFactoryException
Description copied from interface: IMailReader
This method returns the html-mail-template to the mailName as String. If there is no html-mail-template the method returns null.

Specified by:
getHtmlMail in interface IMailReader
Parameters:
templateConfig - containing client, locale, template-name and map.
Returns:
String or NULL
Throws:
MailFactoryException

getPlainMail

public String getPlainMail(TemplateConfig templateConfig)
                    throws MailFactoryException
Description copied from interface: IMailReader
This method returns the plain-mail template as String for a given mailName. If there is no plain-mail-template, the method returns null.

Specified by:
getPlainMail in interface IMailReader
Parameters:
templateConfig - containing client, locale, template-name and map.
Returns:
String or NULL
Throws:
MailFactoryException

getDirectory

public String getDirectory()
Description copied from interface: IMailReader
Returns the directory where the email-templates and the clients are in.

Specified by:
getDirectory in interface IMailReader
Returns:
String

setDirectory

public void setDirectory(String directory)
Description copied from interface: IMailReader
Set teh directory where the email-templates and the clients are in.

Specified by:
setDirectory in interface IMailReader

getHtmlExtension

public String getHtmlExtension()
Description copied from interface: IMailReader
returns the html extension.

Specified by:
getHtmlExtension in interface IMailReader
Returns:

setHtmlExtension

public void setHtmlExtension(String htmlExtension)
Description copied from interface: IMailReader
Set the html extension. The standard is ".html"

Specified by:
setHtmlExtension in interface IMailReader

getPlainExtension

public String getPlainExtension()
Description copied from interface: IMailReader
returns the plain extension.

Specified by:
getPlainExtension in interface IMailReader
Returns:

setPlainExtension

public void setPlainExtension(String plainExtendsion)
Description copied from interface: IMailReader
Set the plain extension. The standard is ".txt"

Specified by:
setPlainExtension in interface IMailReader


Copyright © 2012 PLOIN GmbH. All Rights Reserved.