no.sesat.search.mode
Class SearchModeFactory

java.lang.Object
  extended by no.sesat.search.site.config.AbstractDocumentFactory
      extended by no.sesat.search.mode.SearchModeFactory
All Implemented Interfaces:
SiteKeyedFactory

public final class SearchModeFactory
extends AbstractDocumentFactory
implements SiteKeyedFactory

Controlling class around the deserialisation of modes.xml into all the SearchModes. This in turn deserialises all SearchConfigurations, QueryTransformers, QueryBuilders, and ResultHandlers.

Version:
$Id: SearchModeFactory.java 7225 2009-04-09 00:32:20Z ssmiweve $

Nested Class Summary
static interface SearchModeFactory.Context
          The context any SearchModeFactory must work against.
 
Nested classes/interfaces inherited from class no.sesat.search.site.config.AbstractDocumentFactory
AbstractDocumentFactory.ParseType
 
Field Summary
static String MODES_XMLFILE
          The name of the modes configuration file.
 
Method Summary
 SearchMode getMode(String id)
          Returns the mode with given identifier.
static SearchModeFactory instanceOf(SearchModeFactory.Context cxt)
          Returns the factory for the site in the context.
 boolean remove(Site site)
          Removes mode factory associated with site causing configuration to be reloaded.
 
Methods inherited from class no.sesat.search.site.config.AbstractDocumentFactory
beanToXmlName, fillBeanProperty, parseBoolean, parseFloat, parseInt, parseString, xmlToBeanName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MODES_XMLFILE

public static final String MODES_XMLFILE
The name of the modes configuration file.

See Also:
Constant Field Values
Method Detail

instanceOf

public static SearchModeFactory instanceOf(SearchModeFactory.Context cxt)
Returns the factory for the site in the context.

Parameters:
cxt - The context.
Returns:
the factory for the context.

remove

public boolean remove(Site site)
Removes mode factory associated with site causing configuration to be reloaded.

Specified by:
remove in interface SiteKeyedFactory
Parameters:
site - The site to remove.
Returns:
true if the site existed.

getMode

public SearchMode getMode(String id)
Returns the mode with given identifier.

Parameters:
id - The mode identifier.
Returns:
The mode.


Copyright © 2005-2009 Schibsted ASA. All Rights Reserved.