jcolibri.method.retrieve.NNretrieval.similarity
Class InContextLocalSimilarityFunction

java.lang.Object
  extended by jcolibri.method.retrieve.NNretrieval.similarity.InContextLocalSimilarityFunction
All Implemented Interfaces:
LocalSimilarityFunction
Direct Known Subclasses:
LuceneTextSimilarity

public abstract class InContextLocalSimilarityFunction
extends java.lang.Object
implements LocalSimilarityFunction

Extension of the LocalSimilarityFunction for measures that need data about other attributes of the case or current CaseComponent.
Through the inherited class-attributes subclasses can use information about the "context" (other neighbour attributes) of the compared attribute.
The context information is set by the StandardGlobalSimilarityFunction in a transparent way.
An example is jcolibri.method.retrieve.NNretrieval.similarity.local.textual.LuceneTextSimilarity

Version:
1.0
Author:
Juan A. Recio-Garcia
See Also:
StandardGlobalSimilarityFunction, LuceneTextSimilarity

Field Summary
protected  CBRCase _case
          case that this attribute belongs to
protected  CBRQuery _query
          query that this attribute belongs to
protected  java.lang.String attribute
          name of the attribute
protected  CaseComponent componentOfCase
          component of the case that this attribute belongs to
protected  CaseComponent componentOfQuery
          component of the query that this attribute belongs to
 
Constructor Summary
InContextLocalSimilarityFunction()
           
 
Method Summary
 void setContext(CaseComponent componentOfCase, CaseComponent componentOfQuery, CBRCase _case, CBRQuery _query, java.lang.String attributeName)
          Method used by the StandardGlobalSimilarityFunction (or any other future implementation of the GlobalSimilarityFunction) to set the context of this LocalSimilarityFunction.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface jcolibri.method.retrieve.NNretrieval.similarity.LocalSimilarityFunction
compute, isApplicable
 

Field Detail

componentOfCase

protected CaseComponent componentOfCase
component of the case that this attribute belongs to


componentOfQuery

protected CaseComponent componentOfQuery
component of the query that this attribute belongs to


_case

protected CBRCase _case
case that this attribute belongs to


_query

protected CBRQuery _query
query that this attribute belongs to


attribute

protected java.lang.String attribute
name of the attribute

Constructor Detail

InContextLocalSimilarityFunction

public InContextLocalSimilarityFunction()
Method Detail

setContext

public void setContext(CaseComponent componentOfCase,
                       CaseComponent componentOfQuery,
                       CBRCase _case,
                       CBRQuery _query,
                       java.lang.String attributeName)
Method used by the StandardGlobalSimilarityFunction (or any other future implementation of the GlobalSimilarityFunction) to set the context of this LocalSimilarityFunction.

Parameters:
componentOfCase - that this attribute belongs to
componentOfQuery - that this attribute belongs to
_case - that this attribute belongs to
_query - that this attribute belongs to
attributeName - is the name of the attribute

GAIA - Group for Artificial Intelligence Applications
http://gaia.fdi.ucm.es