org.apache.cocoon.mail.command
Class AbstractMailCommand

java.lang.Object
  extended byorg.apache.cocoon.util.AbstractLogEnabled
      extended byorg.apache.cocoon.mail.command.AbstractMailCommand
All Implemented Interfaces:
MailCommand
Direct Known Subclasses:
MailCommandManager.MailCatAttachmentMessageByIdCommand, MailCommandManager.MailCatMessageByIdCommand, MailCommandManager.MailCatMessageByUIDCommand, MailCommandManager.MailFolderCatCommand, MailCommandManager.MailListFolderCommand, MailCommandManager.MailListMessagesCommand, MailCommandManager.MailRefreshFolderCommand, MailCommandManager.MailSearchMessagesCommand, MailCommands

public abstract class AbstractMailCommand
extends org.apache.cocoon.util.AbstractLogEnabled
implements MailCommand

An abstract MailCommand template

Since:
23 October 2002
Version:
$Id: AbstractMailCommand.html 1304280 2012-03-23 11:18:01Z ilgrosso $

Constructor Summary
AbstractMailCommand()
          Constructor for the AbstractMailCommand object
 
Method Summary
 void addResult(Object o)
          Adds a result to the Result attribute of the AbstractMailCommand object
 void addResults(List list)
          Adds a list of results to the Results attribute of the AbstractMailCommand object
abstract  void execute()
          Execute this command
 List getResults()
          Gets the results attribute of the AbstractMailCommand object
 Iterator iterator()
          Return an iterator over the results
 
Methods inherited from class org.apache.cocoon.util.AbstractLogEnabled
getLogger, setLogger
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractMailCommand

public AbstractMailCommand()
Constructor for the AbstractMailCommand object

Method Detail

getResults

public List getResults()
Gets the results attribute of the AbstractMailCommand object

Returns:
The results value

addResult

public void addResult(Object o)
Adds a result to the Result attribute of the AbstractMailCommand object

Parameters:
o - The result to be added to the Result attribute

addResults

public void addResults(List list)
Adds a list of results to the Results attribute of the AbstractMailCommand object

Parameters:
list - The list of results to be added to the Results attribute

iterator

public Iterator iterator()
Return an iterator over the results

Returns:
result iterator

execute

public abstract void execute()
                      throws MessagingException
Execute this command

Specified by:
execute in interface MailCommand
Throws:
MessagingException - thrown if executing of this MailCommand fails


Copyright © 1999-2008 The Apache Software Foundation. All Rights Reserved.