Interface DependencyRetriever
-
- All Superinterfaces:
Retriever<DataObject,DependencyQuery>
- All Known Implementing Classes:
DependencyRetrieverImpl
public interface DependencyRetriever extends Retriever<DataObject,DependencyQuery>
Interface for the dependency specific retriever, that implements the approach of dependency-guided retrieval. This follows a brute force approach like theLinearRetrieverImpl, but deals with a dependency specific query, consisting of several data objects, and outputs a dependency specific retrieval result list with several elements. For more information, see paper.- Author:
- Rahol Kumar, Alexander Schultheis
-
-
Field Summary
Fields Modifier and Type Field Description static doubleDEFAULT_ALPHAThe default value for the weighting parameter alpha, that enables adjusting both parts of the similarity computation to individual needs of the use case.static intDEFAULT_RESULT_NUMBERThe default value for the result number is 10.static StringNAMEValue is "DependencyRetriever".-
Fields inherited from interface de.uni_trier.wi2.procake.retrieval.Retriever
DEFAULT_ADDQUERYTORESULTS
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description doublegetAlpha()Method, that returns the parameter alpha, which is a weighting factor, that enables adjusting both parts of the similarity computation to individual needs of the use case.intgetResultsNumber()Method, that returns the parameter k for the result numbers, that defines, how many dependency full matches must be found.DependencyQuerynewQuery()Method, that overrides super method, to return a dependency specific query.DependencyRetrievalResultListperform(DependencyQuery dependencyQuery)Method, that overrides super method, to return a dependency specific retrieval result list.voidsetAlpha(double alpha)Method, to set the parameter alpha, which is a weighting factor, that enables adjusting both parts of the similarity computation to individual needs of the use case.voidsetResultsNumber(int resultsNumber)Method, to set the parameter k for the result numbers, that defines, how many dependency full matches must be found.-
Methods inherited from interface de.uni_trier.wi2.procake.retrieval.Retriever
isAddQueryToResults, setAddQueryToResults, setInternalSimilarityMeasure, setObjectPool, setSimilarityCache, setSimilarityModel
-
-
-
-
Field Detail
-
NAME
static final String NAME
Value is "DependencyRetriever".- See Also:
- Constant Field Values
-
DEFAULT_RESULT_NUMBER
static final int DEFAULT_RESULT_NUMBER
The default value for the result number is 10. In the paper, this value is referred to as k.- See Also:
- Constant Field Values
-
DEFAULT_ALPHA
static final double DEFAULT_ALPHA
The default value for the weighting parameter alpha, that enables adjusting both parts of the similarity computation to individual needs of the use case. The default value is 0.5. For this value, both, the dependency similarity and the computed similarity are weighted equally.- See Also:
- Constant Field Values
-
-
Method Detail
-
newQuery
DependencyQuery newQuery()
Method, that overrides super method, to return a dependency specific query.- Specified by:
newQueryin interfaceRetriever<DataObject,DependencyQuery>- Returns:
- A dependency query object.
-
perform
DependencyRetrievalResultList perform(DependencyQuery dependencyQuery)
Method, that overrides super method, to return a dependency specific retrieval result list.- Specified by:
performin interfaceRetriever<DataObject,DependencyQuery>- Parameters:
dependencyQuery- A query that can be created withRetriever.newQuery()- Returns:
- A dependency retrieval result list.
-
setResultsNumber
void setResultsNumber(int resultsNumber)
Method, to set the parameter k for the result numbers, that defines, how many dependency full matches must be found. If not at least k such case combinations were detected, a search of combined cases using dependency similarities is performed.- Parameters:
resultsNumber- The parameter k defines, how many dependency full matches must be found.
-
getResultsNumber
int getResultsNumber()
Method, that returns the parameter k for the result numbers, that defines, how many dependency full matches must be found. If not at least k such case combinations were detected, a search of combined cases using dependency similarities is performed.- Returns:
- The parameter k defines, how many dependency full matches must be found.
-
setAlpha
void setAlpha(double alpha)
Method, to set the parameter alpha, which is a weighting factor, that enables adjusting both parts of the similarity computation to individual needs of the use case. The default weight isDEFAULT_ALPHA.- Parameters:
alpha- The weighting parameter alpha, that should be used.
-
getAlpha
double getAlpha()
Method, that returns the parameter alpha, which is a weighting factor, that enables adjusting both parts of the similarity computation to individual needs of the use case.- Returns:
- The weighting parameter alpha, that is used.
-
-