DLESE Tools
v1.6.0

org.dlese.dpc.index
Class SimpleFileIndexingObserver

java.lang.Object
  extended by org.dlese.dpc.index.SimpleFileIndexingObserver
All Implemented Interfaces:
FileIndexingObserver

public class SimpleFileIndexingObserver
extends Object
implements FileIndexingObserver

A FileIndexingObserver that simply outputs messages to System out. Can be turned off by calling the static debug(false) method.

Author:
John Weatherley

Field Summary
 
Fields inherited from interface org.dlese.dpc.index.FileIndexingObserver
INDEXING_COMPLETED_ABORTED, INDEXING_COMPLETED_DIR_DOES_NOT_EXIST, INDEXING_COMPLETED_DIR_READ_ERROR, INDEXING_COMPLETED_ERROR, INDEXING_COMPLETED_ITEM_ERROR, INDEXING_COMPLETED_SUCCESS
 
Constructor Summary
SimpleFileIndexingObserver()
          Constructor for the SimpleFileIndexingObserver object
SimpleFileIndexingObserver(String startUpMessage)
          Constructor for the SimpleFileIndexingObserver object
SimpleFileIndexingObserver(String messagePrefix, String startUpMessage)
          Constructor for the SimpleFileIndexingObserver object
 
Method Summary
 void indexingCompleted(int status, String message)
          Outputs a message when indexing is complete.
static void setDebug(boolean db)
          Sets the debug attribute of the object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleFileIndexingObserver

public SimpleFileIndexingObserver()
Constructor for the SimpleFileIndexingObserver object


SimpleFileIndexingObserver

public SimpleFileIndexingObserver(String startUpMessage)
Constructor for the SimpleFileIndexingObserver object

Parameters:
startUpMessage - A message that gets is sent to System out when this Object is created.

SimpleFileIndexingObserver

public SimpleFileIndexingObserver(String messagePrefix,
                                  String startUpMessage)
Constructor for the SimpleFileIndexingObserver object

Parameters:
messagePrefix - A identifier String that is inserted at the beginning of all messages output by this SimpleFileIndexingObserver
startUpMessage - A message that gets is set to System out when this Object is created.
Method Detail

indexingCompleted

public void indexingCompleted(int status,
                              String message)
Outputs a message when indexing is complete.

Specified by:
indexingCompleted in interface FileIndexingObserver
Parameters:
status - The status code upon completion
message - A message describing how the indexer completed

setDebug

public static void setDebug(boolean db)
Sets the debug attribute of the object

Parameters:
db - The new debug value

DLESE Tools
v1.6.0