com.raritantechnologies.utils.tagging
Class CachedTermExtractor

java.lang.Object
  extended bycom.raritantechnologies.utils.tagging.CachedTermExtractor
All Implemented Interfaces:
IConfigurable, ITermExtractor

public class CachedTermExtractor
extends java.lang.Object
implements ITermExtractor

Returns an extracted term map previously cached for a given string pattern by a delegate (proxy) ITermExtractor.

XML Configuration Template:
  <TermExtractor class="com.raritantechnologies.utils.tagging.CachedTermExtractor"
                    cacheKey="[ key to use to store string sample ]"
                    cacheStringLength="[ optional limiter of cache string (-1 == no limit ) ]" >

    <!-- Proxy Term Extractor to use if cache is not valid: -->
    <TermExtractor class="[ class of com.raritantechnologies.utils.tagging.ITermExtractor ]" >

    </TermExtractor>

  </TermExtractor>
 

Developed by Raritan Technologies Inc..

Author:
Ted Sullivan

Constructor Summary
CachedTermExtractor()
           
 
Method Summary
 java.util.Map extractTerms(java.lang.String sessionID, java.lang.String fromString)
          returns a map of terms - key is the term, value is either an AttributeWordsTagger or an Attribute string
 void initialize(org.w3c.dom.Element elem)
          Initializes the object from an XML tag or element.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CachedTermExtractor

public CachedTermExtractor()
Method Detail

extractTerms

public java.util.Map extractTerms(java.lang.String sessionID,
                                  java.lang.String fromString)
Description copied from interface: ITermExtractor
returns a map of terms - key is the term, value is either an AttributeWordsTagger or an Attribute string

Specified by:
extractTerms in interface ITermExtractor

initialize

public void initialize(org.w3c.dom.Element elem)
Description copied from interface: IConfigurable
Initializes the object from an XML tag or element. This method is called by the Framework as part of the application initializtion. see ConfigurationManager, XMLConfigurationManager, XMLSearchFieldMapFactory, XMLSearchSourceFactory. Configurable objects that are owned or contained by other configurable objects will be initialized in by the parent object.

Specified by:
initialize in interface IConfigurable