org.ow2.weblab.services.crawler.folder.impl
Class FolderCrawlerService

java.lang.Object
  extended by org.ow2.weblab.services.crawler.folder.impl.FolderCrawlerService
All Implemented Interfaces:
org.ow2.weblab.core.services.Configurable, org.ow2.weblab.core.services.QueueManager, org.ow2.weblab.core.services.SourceReader

public class FolderCrawlerService
extends java.lang.Object
implements org.ow2.weblab.core.services.Configurable, org.ow2.weblab.core.services.QueueManager, org.ow2.weblab.core.services.SourceReader

Author:
jdoucy, ymombrun
Date:
5 juin 08

Field Summary
protected  org.ow2.weblab.content.ContentManager contentManager
          ContentManager
static java.lang.String DEFAULT_FOLDER
          The default folder to crawl
static java.lang.String FOLDERS_FILE
          The file defining the folder to crawl, in a one-a-row style
protected  java.util.Map<java.lang.String,java.lang.String> props
           
protected  java.util.Map<java.lang.String,java.util.List<org.ow2.weblab.crawler.FolderCrawler>> usContextAndFolderCrawler
           
protected  java.util.Map<java.lang.String,java.util.List<java.lang.String>> usContextAndFolderToCrawl
           
 
Constructor Summary
FolderCrawlerService()
           
 
Method Summary
 org.ow2.weblab.core.services.configurable.ConfigureReturn configure(org.ow2.weblab.core.services.configurable.ConfigureArgs args)
           
 org.ow2.weblab.core.services.sourcereader.GetResourceReturn getResource(org.ow2.weblab.core.services.sourcereader.GetResourceArgs args)
           
protected  void loadProps()
           
 org.ow2.weblab.core.services.queuemanager.NextResourceReturn nextResource(org.ow2.weblab.core.services.queuemanager.NextResourceArgs args)
           
 org.ow2.weblab.core.services.configurable.ResetConfigurationReturn resetConfiguration(org.ow2.weblab.core.services.configurable.ResetConfigurationArgs args)
           
protected  void startCrawl(java.lang.String uc, boolean alreadyConfigured)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

contentManager

protected org.ow2.weblab.content.ContentManager contentManager
ContentManager


DEFAULT_FOLDER

public static final java.lang.String DEFAULT_FOLDER
The default folder to crawl

See Also:
Constant Field Values

FOLDERS_FILE

public static final java.lang.String FOLDERS_FILE
The file defining the folder to crawl, in a one-a-row style

See Also:
Constant Field Values

props

protected java.util.Map<java.lang.String,java.lang.String> props

usContextAndFolderToCrawl

protected java.util.Map<java.lang.String,java.util.List<java.lang.String>> usContextAndFolderToCrawl

usContextAndFolderCrawler

protected java.util.Map<java.lang.String,java.util.List<org.ow2.weblab.crawler.FolderCrawler>> usContextAndFolderCrawler
Constructor Detail

FolderCrawlerService

public FolderCrawlerService()
Method Detail

startCrawl

protected void startCrawl(java.lang.String uc,
                          boolean alreadyConfigured)

nextResource

public org.ow2.weblab.core.services.queuemanager.NextResourceReturn nextResource(org.ow2.weblab.core.services.queuemanager.NextResourceArgs args)
                                                                          throws org.ow2.weblab.core.services.AccessDeniedException,
                                                                                 org.ow2.weblab.core.services.ContentNotAvailableException,
                                                                                 org.ow2.weblab.core.services.EmptyQueueException,
                                                                                 org.ow2.weblab.core.services.InsufficientResourcesException,
                                                                                 org.ow2.weblab.core.services.InvalidParameterException,
                                                                                 org.ow2.weblab.core.services.ServiceNotConfiguredException,
                                                                                 org.ow2.weblab.core.services.UnexpectedException,
                                                                                 org.ow2.weblab.core.services.UnsupportedRequestException
Specified by:
nextResource in interface org.ow2.weblab.core.services.QueueManager
Throws:
org.ow2.weblab.core.services.AccessDeniedException
org.ow2.weblab.core.services.ContentNotAvailableException
org.ow2.weblab.core.services.EmptyQueueException
org.ow2.weblab.core.services.InsufficientResourcesException
org.ow2.weblab.core.services.InvalidParameterException
org.ow2.weblab.core.services.ServiceNotConfiguredException
org.ow2.weblab.core.services.UnexpectedException
org.ow2.weblab.core.services.UnsupportedRequestException

getResource

public org.ow2.weblab.core.services.sourcereader.GetResourceReturn getResource(org.ow2.weblab.core.services.sourcereader.GetResourceArgs args)
                                                                        throws org.ow2.weblab.core.services.AccessDeniedException,
                                                                               org.ow2.weblab.core.services.ContentNotAvailableException,
                                                                               org.ow2.weblab.core.services.InsufficientResourcesException,
                                                                               org.ow2.weblab.core.services.InvalidParameterException,
                                                                               org.ow2.weblab.core.services.ServiceNotConfiguredException,
                                                                               org.ow2.weblab.core.services.UnexpectedException,
                                                                               org.ow2.weblab.core.services.UnsupportedRequestException
Specified by:
getResource in interface org.ow2.weblab.core.services.SourceReader
Throws:
org.ow2.weblab.core.services.AccessDeniedException
org.ow2.weblab.core.services.ContentNotAvailableException
org.ow2.weblab.core.services.InsufficientResourcesException
org.ow2.weblab.core.services.InvalidParameterException
org.ow2.weblab.core.services.ServiceNotConfiguredException
org.ow2.weblab.core.services.UnexpectedException
org.ow2.weblab.core.services.UnsupportedRequestException

loadProps

protected void loadProps()

configure

public org.ow2.weblab.core.services.configurable.ConfigureReturn configure(org.ow2.weblab.core.services.configurable.ConfigureArgs args)
                                                                    throws org.ow2.weblab.core.services.AccessDeniedException,
                                                                           org.ow2.weblab.core.services.ContentNotAvailableException,
                                                                           org.ow2.weblab.core.services.InsufficientResourcesException,
                                                                           org.ow2.weblab.core.services.InvalidParameterException,
                                                                           org.ow2.weblab.core.services.UnexpectedException,
                                                                           org.ow2.weblab.core.services.UnsupportedRequestException
Specified by:
configure in interface org.ow2.weblab.core.services.Configurable
Throws:
org.ow2.weblab.core.services.AccessDeniedException
org.ow2.weblab.core.services.ContentNotAvailableException
org.ow2.weblab.core.services.InsufficientResourcesException
org.ow2.weblab.core.services.InvalidParameterException
org.ow2.weblab.core.services.UnexpectedException
org.ow2.weblab.core.services.UnsupportedRequestException

resetConfiguration

public org.ow2.weblab.core.services.configurable.ResetConfigurationReturn resetConfiguration(org.ow2.weblab.core.services.configurable.ResetConfigurationArgs args)
                                                                                      throws org.ow2.weblab.core.services.AccessDeniedException,
                                                                                             org.ow2.weblab.core.services.ContentNotAvailableException,
                                                                                             org.ow2.weblab.core.services.InsufficientResourcesException,
                                                                                             org.ow2.weblab.core.services.InvalidParameterException,
                                                                                             org.ow2.weblab.core.services.UnexpectedException,
                                                                                             org.ow2.weblab.core.services.UnsupportedRequestException
Specified by:
resetConfiguration in interface org.ow2.weblab.core.services.Configurable
Throws:
org.ow2.weblab.core.services.AccessDeniedException
org.ow2.weblab.core.services.ContentNotAvailableException
org.ow2.weblab.core.services.InsufficientResourcesException
org.ow2.weblab.core.services.InvalidParameterException
org.ow2.weblab.core.services.UnexpectedException
org.ow2.weblab.core.services.UnsupportedRequestException


Copyright © 2004-2011. All Rights Reserved.