com.arsdigita.cms.publishToFile
Interface PublishToFileListener

All Known Implementing Classes:
PublishToFile

public interface PublishToFileListener

The listener that does the actual work of writing and removing files. The queue manager calls the listener during queue processing and notifies it of all the tasks that have been queued. The package documentation describes how to set the concrete listener to use.

The queue manager processes queue entries in blocks, following these steps:

   Iterator block = get block of queue entries from DB;
   start DB transaction
   listener.transactionStart();
   while (block.hasNext()) {
     listener.doTask(block.next());
   }
   listener.transactionEnd();
   commit DB transaction
 
If the call to doTask throws an exception, the entry is marked as failing in the queue and the next entry is processed. If the call to transactionStart() or transactionEnd() causes an exception, the whole transaction is rolled back.

Version:
$Revision: #6 $ $DateTime: 2004/04/07 16:07:11 $
Author:
Jeff Teeters (teeters@arsdigita.com)
See Also:
Configuration information

Method Summary
 boolean doTask(QueueEntry qe)
          Process one queued task.
 void transactionEnd()
          Queue manager finished processing one block and is about to commit the transaction.
 void transactionStart()
          Queue manager just started the processing of a new block.
 

Method Detail

doTask

public boolean doTask(QueueEntry qe)
Process one queued task.

Parameters:
qe - QueueEntry describing the task that should be performed

transactionStart

public void transactionStart()
Queue manager just started the processing of a new block.


transactionEnd

public void transactionEnd()
Queue manager finished processing one block and is about to commit the transaction.



Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 19 2004:2352 UTC