NIH | National Cancer Institute | NCI Wiki  

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Please view the LexEVS 5.1 Scope Documentdocument.

GForge items

Please view the LexEVS 5.1 GForge items.

...

An interface to LexEVS Value Domain and Pick List Services could be obtained using an instance of LexBigService.

 

Information

getValueDomainService()

Description:

Returns an interface to LexEVS Value Domain API.

Input:

none

Output:

org.lexgrid.valuedomain.LexEVSValueDomainServices

Exception:

LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexBIG Service instance.
Sample Call:
Using LexBIGService instance :
org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
 



Information

getPickListService()

Description:

Returns an interface to LexEVS Pick List API.

Input:

none

Output:

org.lexgrid valuedomain.LexEVSPickListServices

Exception:

LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexBIG Service instance.
Sample Call:
Using LexBIGService instance :
_ _org.lexgrid.valuedomain.LexEVSPickListServices vds = lbs.getPickListService();

LexEVS Value Domain Service API

...

- Loading Value Domain

There are three methods that could be used to load Value Domain Definitions :

 

Information

loadValueDomain(ValueDomainDefinition vddef, String systemReleaseURI)

Description:

Loads supplied valueDomainDefinition object

Input:

org.LexGrid.emf.valueDomains.ValueDomainDefinition,
String

Output:

none

Exception:

LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to load a Value Domain Definition object and the System Release URI this definition belongs to.
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface :
org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Create and populate the ValueDomainDefinition object
ValueDomainDefinition can be created using :
org.LexGrid.emf.valueDomains.ValueDomainDefinition valueDomain = org.LexGrid.emf.valueDomains.ValuedomainsFactory.eINSTANCE.createValueDomainDefinition();
And data for valueDomain object can be populated by using set methods :
valueDomain.setValueDomainURI(uri);
valueDomain.setValueDomainName(name);
valueDomain.setDefaultCodingScheme(cs);
valueDomain.setEntityDescription(ed);
Similarly, DefinitionEntry, Property, Mapping objects can be created and assign to the valueDomain object.
valueDomain.getDefinitionEntry.add(vdEntry);
valueDomain.setProperties(propertisObject);
valueDomain.setMappings(mappingsObject);
Step 3 : call the load method by passing the Value Domain Definition object and the System Release URI :
vds.loadvalueDomain(valueDomain,"Release 2009");
 



Information

loadValueDomain(InputStream inputStream,boolean failOnAllErrors))

Description:

Loads valueDomainDefinitions found in inputStream

Input:

java.io.InputStream
boolean

Output:

none

Exception:

Exception

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to load all Value Domain Definitions from the inputstream.
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call load method by passing the inputSteam and boolean flag whether to stop on load errors. :
vds.loadvalueDomain(inputStream, true);
 



Information

loadValueDomain(String xmlFileLocation, boolean failOnAllErrors)

Description:

Loads valueDomainDefinitions found in input xml file

Input:

java.lang.String
boolean

Output:

none

Exception:

Exception

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to load all Value Domain Definitions found in an XML file that is in LexGrid format.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call load method by passing the inputfile location and boolean flag whether to stop on load errors. :
vds.loadvalueDomain(inputXMLFile, true);


Validate XML resources
 

Information

validate(URI uri, int valicationLevel) throws LBParameterException

Description:

Perform validation of the candidate resource without loading data.

Input:

java.net.URI
int

Output:

none

Exception:

Org.LexGrid.LexBIG.Exceptions.LBParameterException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to validate the XML file that is in LexGrid format. This call will not load the data in XML file.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call validate method for validation by supplying URI of the XML file and validation level:
Supported validationLevels includes :
0 = Verify document is well-formed
1 = Verify document is valid
 vds.validaten(uriOfXMLFile, true);

Query Value Domain
 

Information

isConceptInDomain(String entityCode, URI valueDomainURI)

Description:

Determine if the supplied entity code is a valid result for the supplied value domain and, if it is, return the particular codingSchemeVersion that was used.

Input:

java.lang.String,
java.net.URI

Output:

org.LexGrid.LexBIG.DataModel.Core. AbsoluteCodingSchemeVersionReference

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to determine if the supplied entity code is a valid in the supplied Value Domain URI. If it is, return Coding Scheme URI and the Version that was used to resolve, other wise, returns null.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call isConceptInComdin method:
AbsoluteCodingSchemeVersionReference acsvr =  vds.isConceptInDomain("conceptA","valueDomainURI");
 

Information

isConceptInDomain(String entityCode, URI entityCodeNamespace, CodingSchemeVersionOrTag csvt, URI valueDomainURI)

Description:

Similar to previous method, this method determine if the supplied entity code and entity namespace is a valid result for the supplied value domain when resolved against supplied Coding Scheme Version or Tag.

Input:

java.lang.String,
java.net.URI,
org.LexGrid.LexBIG.DataModel.Core. CodingSchemeVersionOrTag
java.net.URI

Output:

org.LexGrid.LexBIG.DataModel.Core. AbsoluteCodingSchemeVersionReference

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to determine if the supplied entity code and its entity namespace is a valid in the supplied Value Domain URI when resolved against supplied Coding Scheme Version or Tag. If it is, return Coding Scheme URI and the Version that was used to resolve, other wise, returns null.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call isConceptInDomain method:
AbsoluteCodingSchemeVersionReference acsvr =  vds.isConceptInDomain("conceptA","conceptAEntityNamespace",
"codingSchemeVersion","valueDomainURI");
 



Information

resolveValueDomain(URI valueDomainURI, AbsoluteCodingSchemeVersionReferenceList csVersionList)

Description:

Resolve a value domain using the supplied set of coding scheme versions.

Input:

java.net.URI,
org.LexGrid.LexBIG.DataModel.Core. AbsoluteCodingSchemeVersionReferenceList

Output:

org.lexgrid.valuedomain.dto.ResolvedValueDomainDefinition

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to resolve supplied value domain against list of Coding Scheme versions if supplied. If Coding Scheme Versions list is not supplied, API will resolve against any version of the loaded Coding Scheme that is referenced by the Value Domain.  Returns, object ResolvedValueDomainDefinition which contains AbsoluteCodingSchemeVersionReferenceList which tells which all Coding Scheme and the versions were used for this resolve, plus the ResolvedConceptReferencesIterator, which is an iterator for all the valid concepts that belongs to the Value Domain and Value Domain Definition itself.
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Create AbsoluteCodingSchemeVersionReferenceList:
AbsoluteCodingSchemeVersionReferenceList csvList = new AbsoluteCodingSchemeVersionReferenceList();
csvList.addAbsoluteCodingSchemeVersionReference(Constructors.
createAbsoluteCodingSchemeVersionReference("Automobiles", "2.0"));
csvList.addAbsoluteCodingSchemeVersionReference(Constructors.
createAbsoluteCodingSchemeVersionReference("AutomobilesParts", "2.0"));
Step 3 :Call resolveValueDomain method:
ResolvedValueDomainDefinition rvdDef =  vds.resolveValueDomain ("valueDomainURI",csvList);
 



Information

isSubDomain(URI childValueDomainURI, URI parentValueDomainURI)

Description:

Check whether childValueDomainURI is a child of parentValueDomainURI.

Input:

java.net.URI,
java.net.URI

Output:

boolean

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to determine if all the concepts that gets resolved from supplied Child Value Domain URI is children of concepts that gets resolved from Parent Value Domain URI. Return true, if it is otherwise return false.
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call isSubDomain method:
boolean isSubDomain =  vds.isSubDomain (childValueDomainURI, parentValueDomainURI);
 



Information

getValueDomainDefinition(URI valueDomainURI)

Description:

Returns value domain definition for supplied value domain URI.

Input:

java.net.URI

Output:

org.LexGrid.emf.valueDomains.ValueDomainDefinition

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to get the Value Domain Definition of supplied Value Domain URI.
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call getValueDomainDefinition  method:
ValueDomainDefinition vdDef  =  vds.getValueDomainDefinition (valueDomainURI);
 



Information

listValueDomains(String valueDomainName)

Description:

Return the URI's for the value domain definition(s) for the supplied domain name. If the name is null, returns everything. If the name is not null, returns the value domain(s) that have the assigned name.
Note: plural because there is no guarantee of valueDomain uniqueness. If the name is the empty string "", returns all unnamed valueDomains.

Input:

java.lang.String

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="aac2d579dfb06325-f123ab91-448e477c-9178b32b-fc81658f808e7dd58baef84f"><ac:plain-text-body><![CDATA[

Output:

java.net.URI[]

]]></ac:plain-text-body></ac:structured-macro>

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to get the list of Value Domain URI that matches the supplied name.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call listValueDomains  method:
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="d801ee0218564798-e7b457f6-4cd74c2a-bd03a72f-d379e33c2044da77dd60aef9"><ac:plain-text-body><![CDATA[URI[] uris  =  vds.listValueDomains("someValueDomainName");

]]></ac:plain-text-body></ac:structured-macro> 



Information

getAllValueDomainsWithNoNames()

Description:

Return the URI's of all unnamed value domain definition(s).

Input:

none

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="d4c57cfd0f6f2b0e-87d05c70-485244d6-b9119922-5248badee14c5f22030edbf4"><ac:plain-text-body><![CDATA[

Output:

java.net.URI[]

]]></ac:plain-text-body></ac:structured-macro>

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to get the list of Value Domain URI that have no names.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call getAllValueDomainsWithNoNames  method:
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="5495489808d6467a-37d8392d-41404045-9fffae70-c8db0b087fc0487aff60573b"><ac:plain-text-body><![CDATA[URI[] uris  =  vds.getAllValueDomainsWithNoNames();

]]></ac:plain-text-body></ac:structured-macro> 



Information

getValueDomainEntitiesForTerm(String term, URI valueDomainURI, String matchAlgorithm)

Description:

Resolves the value domain supplied and restricts to the term and matchAlgorith supplied. Return object ResolvedValueDomainCodedNodeSet contains the codingScheme URI and Version that was used to resolve and the CodedNodeSet.
Note : the CodedNodeSet is unresolved

Input:

java.lang.String,
java.net.URI,
java.lang.String

Output:

org.lexgrid.valuedomain.dto.ResolvedValueDomainCodedNodeSet

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to get the resolved Value Domain Entries as CodedNodeSet that is restricted to supplied term and the match algorithm.  Returned CodedNodeSet is not resolved.
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call getValueDomainEntriesForTerm  method:
ResolvedValueDomainCodedNodeSet vdvns  =  vds.getValueDomainEntriesForTerm("General Motors", new URI("AUTO:AllDomesticANDGM"), MatchAlgorithms.exactMatch.name());
 



Information

getCodingSchemesInValueDomain(URI valueDomainURI)

Description:

Returns list of coding scheme summary that is referenced by the supplied value domain.

Input:

java.net.URI

Output:

org.LexGrid.LexBIG.DataModel.Collections. AbsoluteCodingSchemeVersionReferenceList

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to get List of all Coding Scheme URI and Versions the supplied Value Domain URI references.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call getCodingSchemesInValueDomain  method:
AbsoluteCodingSchemeVersionReferenceList csvList  =  vds.getCodingSchemesInValueDomain( new URI("AUTO:AllDomesticANDGM"));  



Information

isDomain(String entityCode, String codingSchemeName, CodingSchemeVersionOrTag csvt)

Description:

Determine if the supplied entity code is of type valueDomain in supplied coding scheme and, if it is, return the true, otherwise return false.

Input:

java.lang.String,
java.lang.String
org.LexGrid.LexBIG.DataModel.Core. CodingSchemeVersionOrTag

Output:

boolean

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to check if supplied entity code is of type valueDomain in supplied Coding Scheme.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call isDomain  method:
boolean isDomain  =  vds.isDomain ("VD005", "Automobiles", Constructors.createCodingSchemeVersionOrTag(null, "2.0")));

Remove Value Domain Definition


 

Information

removeValueDomain(URI valueDomainURI)

Description:

Removes supplied value domain definition from the system.

Input:

java.net.URI

Output:

none

Exception:

org.LexGrid.LexBIG.Exceptions.LBException,
org.LexGrid.managedobj.RemoveException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to remove Value Domain Definition from the system that matches the supplied URI.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call removeValueDomain  method:
vds.removeValueDomain ( new URI("AUTO:AllDomesticANDGM"));
 



Information

removeAllValueDomains()

Description:

Removes all value domain definitions from the system.

Input:

none

Output:

none

Exception:

org.LexGrid.LexBIG.Exceptions.LBException,
org.LexGrid.managedobj.RemoveException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to remove all the Value Domain Definitions that are loaded in the system.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call removeAllValueDomains  method:
vds.removeAllValueDomains();

Drop Value Domain tables
 

Information

dropValueDomainTables()

Description:

Drops value domain tables only if there are no value domain and pick list entries.

Input:

none

Output:

none

Exception:

org.LexGrid.LexBIG.Exceptions.LBException,
org.LexGrid.managedobj.RemoveException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Value Domain Service instance to drop both Value Domain and Pick List tables. The tables will be dropped only if there are no entries in both Value Domain and Pick List tables.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSValueDomainServices interface org.lexgrid.valuedomain.LexEVSValueDomainServices vds = lbs.getValueDomainService();
Step 2 :Call dropValueDomainTables  method:
vds.dropValueDomainTables();

LexEVS Pick List Service API

Loading Pick List

There are three methods that could be used to load Pick List Definitions :

...

 

getPickListDefinitionsForDomain(URI valueDomainURI)

Description:

Returns all the pickList definitions that represents supplied valueDomain URI.

Input:

java.net.URI

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="346446de746f3a3e-d5183f1b-4f684b6d-964b8a86-26ada647482533a2628a8f61"><ac:plain-text-body><![CDATA[

Output:

org.LexGrid.emf.valueDomains.PickListDefinition[]

]]></ac:plain-text-body></ac:structured-macro>

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Pick List Service instance to get all the Pick List Definitions that are represented by supplied Value Domain URI.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSPickListServices interface org.lexgrid.valuedomain.LexEVSPickListServices pls = lbs.getPickListService();
Step 2 :Call getPickListDefinitionsForDomain method:
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="e49bdda3a68f0656-517b305d-4017402d-a6c38cef-4778921bdeb2b750b9731faf"><ac:plain-text-body><![CDATA[PickListDefinition[] plDefs  =  pls.getPickListDefinitionsForDomain(valueDomainURI);

]]></ac:plain-text-body></ac:structured-macro>

...

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="174d873914dc0c18-560beeb7-4aae45c8-b055b7b5-9d8010c94a029457ac23b705"><ac:plain-text-body><![CDATA[

 

resolvePickListForTerm(String pickListId, String term, String matchAlgorithm, String language, String[] context, boolean sortByText)

]]></ac:plain-text-body></ac:structured-macro>

Description:

Resolves pickList definition by applying  supplied arguments.

Input:

java.lang.String,
java.lang.String,
java.lang.String,
java.lang.String,
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="71bcb89918e6bf63-88e31dd1-47f64d64-bb61b01a-502b97e6a17f8f72753dabf2"><ac:plain-text-body><![CDATA[java.lang.String[],
]]></ac:plain-text-body></ac:structured-macro>
boolean

Output:

org.lexgrid.valuedomain.dto.ResolvedPickListEntryList

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Implementation Details:

Implementation:
Step 1: Call this method on the associated LexEVS Pick List Service instance to get list of Pick List Entries that  matches the term supplied and meets other supplied restrictions.
 
Sample Call:
Step 1 : Using LexBIGService instance, get the LexEVSPickListServices interface org.lexgrid.valuedomain.LexEVSPickListServices pls = lbs.getPickListService();
Step 2 :Call resolvePickListForTerm  method:
ResolvedPickListEntryList pleList  =  pls.resolvePickListForTerm ("AUTO:DomesticAutoMakers","Jaguar", MatchAlgorithms.exactMatch.name(), "en", null, true);

...

Downloads for LexEVS 5.1 will be located on the Vocabulary Knowledge Center Wiki https://cabig-kc.nci.nih.gov/Vocab/KC/index.php/LexBig_and_LexEVS

Scrollbar
icons

...

false