org.apache.cocoon.bean
Interface BeanListener

All Known Implementing Classes:
OutputStreamListener

public interface BeanListener

Interface allowing caller to install a listener so that it can be informed as the bean makes progress through the links to be called.

Version:
CVS $Id: BeanListener.html 1304258 2012-03-23 10:09:27Z ilgrosso $
Author:
Upayavira

Method Summary
 void brokenLinkFound(String uri, String parentURI, String message, Throwable t)
          Report a broken link
 void complete()
          Signals completion of the generation process.
 void messageGenerated(String msg)
          Report a general message about operation of the bean
 void pageGenerated(String sourceURI, String destinationURI, int pageSize, int linksInPage, int newLinksinPage, int pagesRemaining, int pagesComplete, long timeTaken)
          Report a page as successfully generated
 void pageSkipped(String uri, String message)
          Report a that was skipped because its URI matched an include/exclude pattern.
 void warningGenerated(String uri, String warning)
          Report a warning about something non-fatal that happened within the bean.
 

Method Detail

pageGenerated

void pageGenerated(String sourceURI,
                   String destinationURI,
                   int pageSize,
                   int linksInPage,
                   int newLinksinPage,
                   int pagesRemaining,
                   int pagesComplete,
                   long timeTaken)
Report a page as successfully generated

Parameters:
sourceURI -
destinationURI -
pageSize -
linksInPage - Number of links found in this page
newLinksinPage -
pagesRemaining - Number of pages still to be generated
pagesComplete -
timeTaken -

pageSkipped

void pageSkipped(String uri,
                 String message)
Report a that was skipped because its URI matched an include/exclude pattern.

Parameters:
uri -
message -

messageGenerated

void messageGenerated(String msg)
Report a general message about operation of the bean

Parameters:
msg - The message to be reported

warningGenerated

void warningGenerated(String uri,
                      String warning)
Report a warning about something non-fatal that happened within the bean.

Parameters:
uri - The page being generated when warning was triggered
warning - The warning to be reported

brokenLinkFound

void brokenLinkFound(String uri,
                     String parentURI,
                     String message,
                     Throwable t)
Report a broken link

Parameters:
uri - The URI that failed to be generated
message - A reason why the link was not generated

complete

void complete()
Signals completion of the generation process. This method can be used to write out reports, display time generation duration, etc.



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