org.archive.crawler.framework
Class ProcessorChainList

java.lang.Object
  extended by org.archive.crawler.framework.ProcessorChainList

public class ProcessorChainList
extends java.lang.Object

A list of all the ProcessorChains.

Author:
John Erik Halse

Constructor Summary
ProcessorChainList(CrawlOrder order)
          Constructs a new ProcessorChainList.
 
Method Summary
 void addProcessorMap(java.lang.String name, MapType processorMap)
          Add a new chain of processors to the chain list.
 ProcessorChain getFirstChain()
          Get the first processor chain.
 ProcessorChain getLastChain()
          Get the last processor chain.
 ProcessorChain getProcessorChain(int index)
          Get a processor chain by its index in the list of chains.
 ProcessorChain getProcessorChain(java.lang.String name)
          Get a processor chain by its name.
 java.util.Iterator iterator()
          Get an iterator over the processor chains.
 void kickUpdate()
           
 int processorCount()
          Get the total number of all processors in all the chains.
 int size()
          Get the number of processor chains.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProcessorChainList

public ProcessorChainList(CrawlOrder order)
                   throws FatalConfigurationException
Constructs a new ProcessorChainList.

Parameters:
order - the Crawl Order to get configuration from.
Throws:
FatalConfigurationException - is thrown if chains could not be set up properly.
Method Detail

addProcessorMap

public void addProcessorMap(java.lang.String name,
                            MapType processorMap)
Add a new chain of processors to the chain list. This method takes a map of processors and wraps it in a ProcessorChain object and adds it to the list of chains.

Parameters:
processorMap - the processor map to be added.

getFirstChain

public ProcessorChain getFirstChain()
Get the first processor chain.

Returns:
the first processor chain.

getLastChain

public ProcessorChain getLastChain()
Get the last processor chain. The last processor chain should contain processors that should always be run for a URI that has started its way through the processors.

Returns:
the last processor chain.

processorCount

public int processorCount()
Get the total number of all processors in all the chains.

Returns:
the total number of all processors in all the chains.

iterator

public java.util.Iterator iterator()
Get an iterator over the processor chains.

Returns:
an iterator over the processor chains.

size

public int size()
Get the number of processor chains.

Returns:
the number of processor chains.

getProcessorChain

public ProcessorChain getProcessorChain(int index)
Get a processor chain by its index in the list of chains.

Parameters:
index - the chains index in the list of chains.
Returns:
the requested processor chain.

getProcessorChain

public ProcessorChain getProcessorChain(java.lang.String name)
Get a processor chain by its name.

Parameters:
name - name of the processor chain to get.
Returns:
the requested processor chain.

kickUpdate

public void kickUpdate()


Copyright © 2003-2011 Internet Archive. All Rights Reserved.