|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectgov.nih.nlm.umls.io.RichMRFilesIndexLookup
public class RichMRFilesIndexLookup
Peforms a lookup in the index files to locate the
Concepts that contain given words.
| Field Summary | |
|---|---|
protected boolean |
null_value_flag
|
protected String |
regex_null_value
|
| Constructor Summary | |
|---|---|
RichMRFilesIndexLookup(String dir)
Instantiates an RichMRFilesIndexLookup from the
specified input directory. |
|
| Method Summary | |
|---|---|
void |
close()
Release resources being used by this class. |
int |
countChildContexts(Context cxt)
Looks up the given Context in the appropriate index files and returns
the count of Contexts whose ptr matches the given one + the aui. |
int |
countSiblingContexts(Context cxt)
Looks up the given Context in the appropriate index files and returns
the count of Contexts whose ptr matches the given one. |
Context |
findAncestorContext(Context cxt,
String ptr)
Looks up the given ptr in the appropriate index files and returns the matching ancestor. |
Atom |
findAtomByAui(String aui)
Looks up the given aui in the AUI_MRCONSO.x index file and returns the Atom that contains the given aui. |
Context[] |
findChildContexts(Context cxt)
Looks up the given Context's ptr + aui in the appropriate
index files and returns the Contexts with matching ptrs. |
Concept |
findConceptByAui(String aui)
Looks up the given aui in the AUI_MRCONSO.x index file and returns the Concept that contains the given aui. |
Concept |
findConceptByCui(String cui)
Looks up the given cui in MRCONSO and returns the Concept associated with the given cui. |
Context[] |
findSiblingContexts(Context cxt)
Looks up the given Context's ptr in the appropriate
index files and returns the Contexts with matching ptrs. |
String |
getLanguage()
Returns the language of the index file that should be searched. |
String |
getNullValue()
Returns the null value. |
int |
getPreviousTotalResultCount()
Returns the total number of concept matches found on the previous search. |
double |
getThreshold()
Returns the rank threshold value for searching. |
int |
getWordCountThreshold()
Returns the rank threshold value for searching. |
boolean |
isEmptyValue(String token)
Indicates whether or not the specified token is null or contains a null value as defined by being either zero length or a value equal to the null value. |
protected String |
resolveNull(String line)
Replaces all "null value" characters in the line. |
void |
setLanguage(String lat)
Sets the language of the index file that should be searched. |
void |
setMaxResults(int max_results)
Sets the maximum number of results that should be returned. |
void |
setNullValue(String null_value)
Sets the null value to use. |
void |
setThreshold(double threshold)
Sets the rank threshold value for searching. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected String regex_null_value
protected boolean null_value_flag
| Constructor Detail |
|---|
public RichMRFilesIndexLookup(String dir)
throws IOException
RichMRFilesIndexLookup from the
specified input directory.
dir - subset directory where index files can be found
IOException| Method Detail |
|---|
public void setNullValue(String null_value)
setNullValue in interface LocalNullValueSupportnull_value - the new null string valuepublic String getNullValue()
getNullValue in interface LocalNullValueSupportpublic boolean isEmptyValue(String token)
isEmptyValue in interface LocalNullValueSupportprotected String resolveNull(String line)
line - input line
public void close()
throws IOException
IOExceptionpublic int getPreviousTotalResultCount()
public Context[] findChildContexts(Context cxt)
throws IOException
Context's ptr + aui in the appropriate
index files and returns the Contexts with matching ptrs.
cxt - Context
Context[] children
IOException
public Context[] findSiblingContexts(Context cxt)
throws IOException
Context's ptr in the appropriate
index files and returns the Contexts with matching ptrs.
cxt - Context
Context[] children
IOException
public Context findAncestorContext(Context cxt,
String ptr)
throws IOException
cxt - Contextptr - String
Context[]
IOException
public int countChildContexts(Context cxt)
throws IOException
Context in the appropriate index files and returns
the count of Contexts whose ptr matches the given one + the aui.
cxt - Context parent
int children
IOException
public int countSiblingContexts(Context cxt)
throws IOException
Context in the appropriate index files and returns
the count of Contexts whose ptr matches the given one.
cxt - Context parent
int siblings
IOException
public Concept findConceptByCui(String cui)
throws IOException
Concept associated with the given cui.
cui - to be searched for
Concept
IOException
public Concept findConceptByAui(String aui)
throws IOException
Concept that contains the given aui.
aui - to be searched for
Concept containing the aui
IOException
public Atom findAtomByAui(String aui)
throws IOException
Atom that contains the given aui.
aui - to be searched for
Atom containing the aui
IOExceptionpublic void setLanguage(String lat)
lat - language abbreviationpublic String getLanguage()
public void setMaxResults(int max_results)
max_results - number of resultspublic void setThreshold(double threshold)
threshold - the rank threshold valud for searchingpublic double getThreshold()
public int getWordCountThreshold()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||