org.wdssii.core
Class IndexFactory

java.lang.Object
  extended by org.wdssii.core.IndexFactory

public abstract class IndexFactory
extends Object

Creates index objects from Index URLs such as xml:/tmp/testindex.xml

Version:
$Id: IndexFactory.java,v 1.2 2006/12/28 22:23:29 lakshman Exp $
Author:
Lakshman
See Also:
IndexRecord

Field Summary
private static org.apache.commons.logging.Log log
           
private static PrototypeFactory<Index> myFactory
           
private static TimerTask timerTask
           
private static List<Index> toUpdate
           
 
Constructor Summary
IndexFactory()
           
 
Method Summary
static Index createIndex(String url)
          Creates an index.
static Index createIndex(String url, IndexRecordListener listener)
          convenience function when only one listener needs to be provided.
static Index createIndex(String url, Set<IndexRecordListener> listeners)
          Creates an index.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

private static org.apache.commons.logging.Log log

myFactory

private static PrototypeFactory<Index> myFactory

toUpdate

private static List<Index> toUpdate

timerTask

private static TimerTask timerTask
Constructor Detail

IndexFactory

public IndexFactory()
Method Detail

createIndex

public static Index createIndex(String url)
                         throws IllegalArgumentException,
                                DataUnavailableException
Creates an index. Add listeners using addIndexRecordListener

Throws:
IllegalArgumentException
DataUnavailableException

createIndex

public static Index createIndex(String url,
                                IndexRecordListener listener)
                         throws IllegalArgumentException,
                                DataUnavailableException
convenience function when only one listener needs to be provided.

Throws:
IllegalArgumentException
DataUnavailableException

createIndex

public static Index createIndex(String url,
                                Set<IndexRecordListener> listeners)
                         throws IllegalArgumentException,
                                DataUnavailableException
Creates an index. Existing records are supplied to the list of listeners

Throws:
IllegalArgumentException
DataUnavailableException