NIH | National Cancer Institute | NCI Wiki  

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin
Scrollbar
iconsfalse

...

Page info
title
title

Panel
titleContents of this Page
Table of Contents
minLevel2

Introduction

This document is a section of the Migration Guide.

Purpose of this Document

The transition from EVS API to LexEVS API will require the use of different methods to accomplish the same function as was previously provided in EVS API. This document will identify each deprecated class and provide the alternative LexEVS API.

Classes no longer Available

As a result of the deprecation of the EVS API, the following classes are no longer available:

  • EVSQuery and EVSQueryImpl
  • EVSQueryDAOImpl - Not a public API.
  • EVSWSDAOImpl - Not a public API.
  • EVSWSQuery - Not a public API.
  • DLBAdapter - Not a public API.
  • DLBWrapper (DLBWrapper is extended by DLBAdapter and it is not been used anywhere else) - Not a public API.
  • EVSApplicationService and EVSApplicationServiceImpl

EVSApplicationService - evsSearch and search - and LexEVS Counterparts

These methods are replaced either by the LexEVS API or the LexEVS caCORE SDK Data Service 'search' method. This uses the standard caCORE SDK API. More information about the caCORE SDK can be obtained on the caCORE SDK site.

EVSQuery Methods and LexEVS Counterparts

getTree

All 'getTree' functionality is replaced by the LexEVS CodedNodeGraph API. For example:

Code Block
:title}
{panel:title=Contents of this Page}
{toc:minLevel=2}
{panel}

h2. Introduction
This document is a section of the [Migration Guide|LexEVS 5.x Migration Guide]. 

h2. Purpose of this Document
The transition from EVS API to LexEVS API will require the use of different methods to accomplish the same function as was previously provided in EVS API. This document will identify each deprecated class and provide the alternative LexEVS API. 

h2. Classes no longer Available
As a result of the deprecation of the EVS API, the following classes are no longer available:
* EVSQuery and EVSQueryImpl
* EVSQueryDAOImpl - Not a public API.
* EVSWSDAOImpl  - Not a public API.
* EVSWSQuery - Not a public API.
* DLBAdapter - Not a public API.
* DLBWrapper (DLBWrapper is extended by DLBAdapter and it is not been used anywhere else) - Not a public API.
* EVSApplicationService and EVSApplicationServiceImpl

h2. EVSApplicationService - evsSearch and search - and LexEVS Counterparts

These methods are replaced either by the LexEVS API or the LexEVS caCORE SDK Data Service 'search' method. This uses the standard caCORE SDK API. More information about the caCORE SDK can be obtained on the [caCORE SDK site|http://ncicb.nci.nih.gov/infrastructure/cacoresdk].

h2. EVSQuery Methods  and LexEVS Counterparts

h3. getTree

All 'getTree' functionality is replaced by the LexEVS *CodedNodeGraph* API. For example:

{code}
 public void getTree(String vocabularyName, String rootCode, boolean 
direction, boolean isaFlag, int attributes, int levels, Vector roles);
{code}

is

...

replaced

...

by:

{
Code Block
}
 CodedNodeGraph cng = lexevsService.getNodeGraph(String codingScheme, 
CodingSchemeVersionOrTag, versionOrTag, String relationContainerName);
 ResolvedConceptReference[] rcr = cng.resolveAsList(ConceptReference 
graphFocus, boolean resolveForward, 
                                                     boolean 
resolveBackward, int resolveCodedEntryDepth, int 
resolveAssociationDepth, 
                                                     LocalNameList 
propertyNames, PropertyType[] propertyTypes, SortOptionList 
sortOptions, 
                                                     int 
maxToReturn).getResolvedConceptReference();
{code}

Also,

...

various

...

methods

...

in

...

LexBIGServiceConvenienceMethods

...

can

...

be

...

used

...

to

...

show

...

hierarchies.

...

See

...

the

...

following

...

methods:

...

  • getHierarchyRoots
  • getHierarchyRootSet
  • getHierarchyLevelNext
  • getHierarchyLevelPrev
  • getHierarchyPathToRoot

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.BuildTreeForCode

...

  • org.LexGrid.LexBIG.example.ListHierarchy

...

  • org.LexGrid.LexBIG.example.ListHierarchyByCode

...

  • org.LexGrid.LexBIG.example.ListHierarchyPathToRoot

searchDescLogicConcepts

LexEVS provides many ways to restrict the result of a query. The method 'searchDescLogicConcepts' searches for matches based on a text String. To conduct similar queries using LexEVS, use the CodedNodeSet API.

Obtain a CodedNodeSet from LexEVS:

Code Block


h3. searchDescLogicConcepts
LexEVS provides many ways to restrict the result of a query. The method 'searchDescLogicConcepts' searches for matches based on a text String. To conduct similar queries using LexEVS, use the *CodedNodeSet* API.

Obtain a CodedNodeSet from LexEVS:

{code}
 CodedNodeSet nodes = lexevsService.getNodeSet(String codingScheme, 
CodingSchemeVersionOrTag versionOrTag, LocalNameList entityTypes);
{code}

Once

...

established,

...

the

...

CodedNodeSet

...

can

...

be

...

further

...

restricted

...

using

...

the

...

various

...

'restrict'

...

methods

...

in

...

the

...

CodedNodeSet

...

API.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.SoundsLike

...

  • org.LexGrid.LexBIG.example.FindCodesForDescription

...

getConceptWithPropertyMatching

See example above.

...

For

...

Property-specific

...

matching,

...

see

...

the

...

following

...

method

...

in

...

the

...

CodedNodeSet

...

API

  • restrictToProperties

This will ensure that each of the results will have at least one Property that matches the supplied criteria.

isSubConcept

In LexEVS, use the CodedNodeGraph API to find the immediate relations of a Concept.
For instance:

Code Block

* restrictToProperties

This will ensure that each of the results will have at least one Property that matches the supplied criteria.

h3. isSubConcept
In LexEVS, use the *CodedNodeGraph* API to find the immediate relations of a Concept.
For instance:
{code}
 CodedNodeGraph cng = lexevsService.getNodeGraph(String codingScheme, 
CodingSchemeVersionOrTag versionOrTag, String relationContainerName);
 ResolvedConceptReference[] rcr = cng.resolveAsList(ConceptReference 
graphFocus, boolean resolveForward, boolean resolveBackward, 
                                                    int 
resolveCodedEntryDepth, int resolveAssociationDepth, LocalNameList 
propertyNames, 
                                                    PropertyType[] 
propertyTypes, SortOptionList sortOptions, int 
maxToReturn).getResolvedConceptReference();
{code}

Set

...

the

...

ConceptReference

...

graphFocus

...

to

...

the

...

desired

...

code,

...

this

...

will

...

focus

...

the

...

Graph.

...

Then

...

check

...

the

...

relationships.

...

Alternatively,

...

use

...

the

...

CodedNodeGraph

...

API

...

method

...

'areCodesRelated'

{
Code Block
}
 Boolean areCodesRelated(NameAndValue association, ConceptReference 
sourceCode, ConceptReference targetCode, boolean directOnly) 
{code}

h3. isRetired
Use the *LexBIGServiceConvenienceMethods* API method 

isRetired

Use the LexBIGServiceConvenienceMethods API method 'isCodeRetired'

...

method.

getDescendants

Use the LexEVS HistoryService API

Obtain a the HistoryService API as follows:

Code Block


h3. getDescendants
Use the LexEVS *HistoryService* API

Obtain a the HistoryService API as follows:

{code}
 HistoryService historySvc = lexevsService.getHistoryService
(StringcodingSchemeName);
{code}

To

...

get

...

the

...

decendents

...

of

...

a

...

given

...

code,

...

use

...

the

...

'getDecendants'

...

method:

{
Code Block
}
 NCIChangeEventList changeEventList = historySvc.getDescendants
(ConceptReference conceptReference);
{code}

h3. getPropertyValues
Through the _Entity_ class, all Properties 

getPropertyValues

Through the Entity class, all Properties (Presentations,

...

Definitions,

...

etc)

...

are

...

available.

...

  • Entity

...

  • -

...

  • To

...

  • find

...

  • the

...

  • 'Presentations'

...

  • of

...

  • a

...

  • given

...

  • Entity:

...

  • Code Block

...

  • 
        Entity entity = ....;
        Presentation[] presentations = entity.getPresentation();
    

...

  • To find the 'Definitions'

...

  • of

...

  • a

...

  • given

...

  • Entity:

...

  • Code Block

...

  • 
        Entity entity = ....;
        Definition[] definitions = entity.getDefinition();
    

...

  • To find the 'Comments'

...

  • of

...

  • a

...

  • given

...

  • Entity:

...

  • Code Block

...

  • 
        Entity entity = ....;
        Comment[] comments= entity.getComment();
      

...

  • To find the non-classified

...

  • Properties

...

  • of

...

  • a

...

  • given

...

  • Entity:

...

  • Code Block

...

  • 
        Entity entity = ....;
        Property[] properties = entity.getProperties();
      

getAncestors

Use the LexEVS HistoryService API

Obtain a the HistoryService API as follows:

Code Block
{code}

h3. getAncestors
Use the LexEVS *HistoryService* API

Obtain a the HistoryService API as follows:

{code}
 HistoryService historySvc = lexevsService.getHistoryService
(StringcodingSchemeName);
{code}

To

...

get

...

the

...

ancestors

...

of

...

a

...

given

...

code,

...

use

...

the

...

'getDecendants'

...

method:

{
Code Block
}
 NCIChangeEventList changeEventList = historySvc.getAncestors
(ConceptReference conceptReference);

getSubConcepts

Use the CodedNodeGraph API to find the immediate relations of a Concept.
For instance:

Code Block
{code}

h3. getSubConcepts
Use the *CodedNodeGraph* API to find the immediate relations of a Concept.
For instance:
{code}
 CodedNodeGraph cng = lexevsService.getNodeGraph(String codingScheme, 
CodingSchemeVersionOrTag versionOrTag, String relationContainerName);
 ResolvedConceptReference[] rcr = cng.resolveAsList(ConceptReference 
graphFocus, boolean resolveForward, boolean resolveBackward, 
                                                    int 
resolveCodedEntryDepth, int resolveAssociationDepth, LocalNameList 
propertyNames, 
                                                    PropertyType[] 
propertyTypes, SortOptionList sortOptions, int 
maxToReturn).getResolvedConceptReference();
{code}

Focus

...

the

...

'graphFocus'

...

on

...

the

...

desired

...

Concept

...

to

...

see

...

relationships

...

from

...

a

...

given

...

Concept.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getSuperConcepts

See above 'getSubConcepts'

...

– setting

...

your

...

resolve

...

direction

...

(boolean

...

resolveForward,

...

boolean

...

resolveBackward)

...

will

...

determine

...

if

...

sub-concepts

...

or

...

super-concepts

...

are

...

resolved.

getPropertiesByConceptCode

To find the Properties of a given code, for example, code 'C1234' in the 'NCI Thesaurus' ontology - first obtain a 'CodedNodeSet' from the 'NCI Thesaurus' ontology:

Code Block


h3. getPropertiesByConceptCode
To find the Properties of a given code, for example, code 'C1234' in the 'NCI Thesaurus' ontology - first obtain a 'CodedNodeSet' from the 'NCI Thesaurus' ontology:

{code}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = 
ConvenienceMethods.createConceptReferenceList(new String[] 
{ "C1234"}, "NCI Thesaurus");
     
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

To

...

view

...

the

...

Properties,

...

see

...

'getPropertyValues'

...

above.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getVocabularyNames

Use the 'LexBIGService'

...

API

...

method

...

'getSupportedCodingSchemes'

...

-

...

and

...

extract

...

the

...

Names

...

(local

...

name,

...

registered

...

name,

...

etc...)

...

as

...

needed.

...

getAllVocabularies

Use the 'LexBIGService'

...

API

...

method

...

'getSupportedCodingSchemes'.

...

getVocabularyByName

Use 'LexBIGService'

...

API

...

method

...

'resolveCodingScheme'.

...

getVocabularyVersion

Use 'LexBIGService'

...

API

...

method

...

'resolveCodingScheme'

...

and

...

extract

...

the

...

'representsVersion'

...

attribute

...

from

...

the

...

Resulting

...

CodingScheme.

getConceptEditAction

Use the LexEVS HistoryService API

Obtain a the HistoryService API as follows:

Code Block


h3. getConceptEditAction
Use the LexEVS *HistoryService* API

Obtain a the HistoryService API as follows:

{code}
 HistoryService historySvc = lexevsService.getHistoryService
(StringcodingSchemeName);
{code}

To

...

get

...

the

...

'EditActionList'

...

of

...

a

...

given

...

code,

...

use

...

the

...

'getEditActionList'

...

method:

{
Code Block
}
 NCIChangeEventList changeEventList = historySvc.getEditActionList(ConceptReference conceptReference, 
CodingSchemeVersion codingSchemeVersion);
{code}

h3. getRootConcepts
Use 

getRootConcepts

Use 'LexBIGServiceConvenienceMethods'

...

API

...

method

...

'getHierarchyRoots'

...

or

...

'getHierarchyRootSet'

...

searchSourceByCode

Use 'CodedNodeSet'

...

API

...

-

...

adding

...

a

...

'restrictToCodes'

...

restriction.

...

To

...

find

...

the

...

a

...

given

...

code,

...

for

...

example,

...

code

...

'C1234'

...

in

...

the

...

'NCI

...

Thesaurus'

...

ontology

...

-

...

first

...

obtain

...

a

...

'CodedNodeSet'

...

from

...

the

...

'NCI

...

Thesaurus'

...

ontology:

{
Code Block
}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to 
search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = ConvenienceMethods.createConceptReferenceList
(new String[] 
{ "C1234"}, "NCI Thesaurus");
    
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

h3. searchSourceByAtomCode
In the NCI MetaThesaurus, fidning the 

searchSourceByAtomCode

In the NCI MetaThesaurus, fidning the 'source'

...

of

...

an

...

'Atom'

...

is

...

equivalent

...

to

...

finding

...

the

...

'source'

...

of

...

a

...

given

...

Property

...

of

...

an

...

Entity.

...

Each

...

CUI

...

(which

...

is

...

equivalent

...

to

...

an

...

Entity

...

in

...

LexEVS)

...

may

...

contain

...

several

...

Presentation

...

Properties

...

(Atoms

...

or

...

AUI's

...

of

...

that

...

CUI).

...

Each

...

of

...

these

...

Presentation

...

Properties

...

is

...

Qualified

...

by

...

a

...

'source-code'

...

Qualifier,

...

which

...

reflects

...

the

...

code

...

of

...

this

...

Atom

...

in

...

its

...

original

...

source,

...

and

...

a

...

'source'

...

qualifier,

...

which

...

states

...

the

...

source

...

itself

...

that

...

this

...

Atom

...

came

...

from.

getMetaConceptNameByCode

To find the Properties of a given code, for example, code 'C1234567' in the 'NCI MetaThesaurus' ontology - first obtain a 'CodedNodeSet' from the 'NCI MetaThesaurus' ontology:

Code Block


h3. getMetaConceptNameByCode
To find the Properties of a given code, for example, code 'C1234567' in the 'NCI MetaThesaurus' ontology - first obtain a 'CodedNodeSet' from the 'NCI MetaThesaurus' ontology:

{code}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
MetaThesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234567'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to 
search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = 
ConvenienceMethods.createConceptReferenceList(new String[] 
{ "C1234567"}, "NCI MetaThesaurus");
  
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

To

...

see

...

the

...

name

...

of

...

the

...

code,

...

use

...

'getEntityDescription'

...

on

...

the

...

resulting

...

ResolvedConceptReference.

...

The

...

'EntityDescription'

...

will

...

always

...

be

...

equal

...

to

...

the

...

Preferred

...

Presentation

...

in

...

the

...

Default

...

Language.

...

getMetaSources

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Association

...

Qualifiers

...

using

...

the

...

'getSupportedSource'

...

method.

{:=
Info
title
Note
}

This

can

be

applied

to

any

Coding

Scheme,

not

just

the

NCI

MetaThesaurus.

{info} h3. getChildren Use the

getChildren

Use the 'CodedNodeGraph'

...

API.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getParent

Use the 'CodedNodeGraph'

...

API.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getBroaderConcepts

Use the CodedNodeGraph API to find the immediate relations of a Concept. Resolve forward or backwards based on the hierarchy structure of the ontology.

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getNarrowerConcepts

Use the CodedNodeGraph API to find the immediate relations of a Concept. Resolve forward or backwards based on the hierarchy structure of the ontology.

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getRelatedConcepts

Use the CodedNodeGraph API to find the immediate relations of a Concept.

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

containsInverseRole

Use the LexBIGServiceConvenienceMethods API method 'isReverseName'

...

method.

...

containsRole

Use the LexBIGServiceConvenienceMethods API method 'isForwardName'

...

method.

...

getAllAssociationTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Associations

...

using

...

the

...

'getSupportedAssociation'

...

method.

...

getAllConceptAssociationQualifierTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Association

...

Qualifiers

...

using

...

the

...

'getSupportedAssociationQualifier'

...

method.

...

getAllConceptAssociationTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Associations

...

using

...

the

...

'getSupportedAssociation'

...

method.

...

getAllConceptPropertyQualifierTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Property

...

Qualifiers

...

using

...

the

...

'getSupportedPropertyQualifier'

...

method.

...

getAllConceptPropertyTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Properties

...

using

...

the

...

'getSupportedProperty'

...

method.

...

getAllLicenses

Use the 'LexBIGService'

...

API

...

method

...

'resolveCodingSchemeCopyright'.

...

To

...

get

...

the

...

Copyright

...

for

...

every

...

loaded

...

ontology,

...

do

...

this

...

for

...

each

...

one.

...

getAllPropertyTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Properties

...

using

...

the

...

'getSupportedProperty'

...

method.

...

getAllQualifierTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Property

...

Qualifiers

...

using

...

the

...

'getSupportedPropertyQualifier'

...

method.

...

getAllRoleNames

Use the 'LexBIGService'

...

API

...

method

...

'resolveCodingScheme'.

...


Once

...

the

...

CodingScheme

...

Object

...

is

...

obtained,

...

use

...

the

...

method

...

'getRelations'.

...

getAllSubConceptCodes

Use the CodedNodeGraph API to find the immediate relations of a Concept.

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getAllSynonymTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Associations

...

using

...

the

...

'getSupportedAssociation'

...

method.

{:=
Info
title
Note
}

Different

ontologies

may

describe

their

'Synonym'

relations

differently.

{info} h3. getAllTermAssociationQualifierTypes Use the

getAllTermAssociationQualifierTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Association

...

Qualifiers

...

using

...

the

...

'getSupportedAssociationQualifier'

...

method.

...

getAllTermPropertyQualifierTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Property

...

Qualifiers

...

using

...

the

...

'getSupportedPropertyQualifier'

...

method.

...

getAllTermPropertyTypes

Use the 'LexBIGService'

...

API

...

method

...

'getMappings'.

...


Extract

...

for

...

this

...

the

...

Supported

...

Property

...

using

...

the

...

'getSupportedProperty'

...

method.

...

getParentConcepts

Use the CodedNodeGraph API to find the immediate relations of a Concept.

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getChildConcepts

Use the CodedNodeGraph API to find the immediate relations of a Concept.

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

hasParents

Use the CodedNodeGraph API to find the immediate relations of a Concept.

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

hasChildren

Use the CodedNodeGraph API to find the immediate relations of a Concept.

For examples, see the following LexEVS Example classes:

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getDescLogicConcept

A 'DescLogicConcept'

...

can

...

be

...

thought

...

of

...

as

...

an

...

'Entity'

...

in

...

LexEVS.

...

To

...

obtain

...

an

...

Entity,

...

use

...

the

...

CodedNodeSet

...

API,

...

restricting

...

the

...

query

...

as

...

necessary.

...

For

...

instance,

...

a

...

'DescLogicConcept'

...

with

...

a

...

code

...

of

...

'C1234'

...

can

...

be

...

queried

...

for

...

by

...

the

...

example

...

below.

...

The

...

example

...

will

...

return

...

a

...

ResolvedConceptReference

...

and

...

ultimately

...

an

...

Entity,

...

but

...

is

...

functionally

...

the

...

same

...

as

...

searching

...

for

...

a

...

DescLogicConcept.

...

To

...

find

...

the

...

a

...

given

...

code,

...

for

...

example,

...

code

...

'C1234'

...

in

...

the

...

'NCI

...

Thesaurus'

...

ontology

...

-

...

first

...

obtain

...

a

...

'CodedNodeSet'

...

from

...

the

...

'NCI

...

Thesaurus'

...

ontology:

{
Code Block
}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to 
search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = 
ConvenienceMethods.createConceptReferenceList(new String[] 
{ "C1234"}, "NCI Thesaurus");
    
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, null, 1);
{code}

h3. getHistoryRecords
Use the *HistoryService* API 

getHistoryRecords

Use the HistoryService API 'getBaselines'

...

and

...

specify

...

the

...

required

...

Data

...

range.

...

Obtain

...

a

...

the

...

HistoryService

...

API

...

as

...

follows:

{
Code Block
}
 HistoryService historySvc = lexevsService.getHistoryService
(StringcodingSchemeName);
{code}

Use

...

the

...

'getBaselines'

...

method:

{
Code Block
}
 SystemReleaseList systemReleaseList = historySvc.getBaselines(Date 
releasedAfter, Date releasedBefore);
{code}

h3. getHistoryStartDate
Use the *HistoryService* API method 

getHistoryStartDate

Use the HistoryService API method 'getEarliestBaseline';

...

Obtain

...

a

...

the

...

HistoryService

...

API

...

as

...

follows:

{
Code Block
}
 HistoryService historySvc = lexevsService.getHistoryService
(StringcodingSchemeName);
{code}

Use

...

the

...

'getEarliestBaseline'

...

method:

{
Code Block
}
 SystemRelease systemRelease = historySvc.getEarliestBaseline();
{code}

h3. getHistoryEndDate
Use the *HistoryService* API method 

getHistoryEndDate

Use the HistoryService API method 'getLatestBaseline';

...

Obtain

...

a

...

the

...

HistoryService

...

API

...

as

...

follows:

{
Code Block
}
 HistoryService historySvc = lexevsService.getHistoryService
(StringcodingSchemeName);
{code}

Use

...

the

...

'getLatestBaseline'

...

method:

{
Code Block
}
 SystemRelease systemRelease = historySvc.getLatestBaseline();
{code}

h3. getCodeActionChildren
Use the *HistoryService* API method 

getCodeActionChildren

Use the HistoryService API method 'getDescendants';

...


Obtain

...

a

...

the

...

HistoryService

...

API

...

as

...

follows:

{
Code Block
}
 HistoryService historySvc = lexevsService.getHistoryService
(StringcodingSchemeName);
{code}

Use

...

the

...

'getDescendants'

...

method:

{
Code Block
}
 NCIChangeEventList changeEventList = historySvc.getDescendants
(ConceptReference conceptReference);
{code}

h3. getCodeActionParents
Use the *HistoryService* API method 

getCodeActionParents

Use the HistoryService API method 'getAncestors';

...

Obtain

...

a

...

the

...

HistoryService

...

API

...

as

...

follows:

{
Code Block
}
 HistoryService historySvc = lexevsService.getHistoryService
(StringcodingSchemeName);
{code}

Use

...

the

...

'getDescendants'

...

method:

{
Code Block
}
 NCIChangeEventList changeEventList = historySvc.getAncestors
(ConceptReference conceptReference);

getAssociationCollectionbyCode

Use the CodedNodeGraph API to find the immediate relations of a Concept.
For instance:

Code Block
{code}

h3. getAssociationCollectionbyCode
Use the *CodedNodeGraph* API to find the immediate relations of a Concept.
For instance:
{code}
 CodedNodeGraph cng = lexevsService.getNodeGraph(String codingScheme, 
CodingSchemeVersionOrTag versionOrTag, String relationContainerName);
 ResolvedConceptReference[] rcr = cng.resolveAsList(ConceptReference 
graphFocus, boolean resolveForward, boolean resolveBackward, 
                                                    int 
resolveCodedEntryDepth, int resolveAssociationDepth, LocalNameList 
propertyNames, 
                                                    PropertyType[] 
propertyTypes, SortOptionList sortOptions, int 
maxToReturn).getResolvedConceptReference();
{code}

Focus

...

the

...

'graphFocus'

...

on

...

the

...

desired

...

Concept

...

to

...

see

...

relationships

...

from

...

a

...

given

...

Concept.

...

Once

...

focused

...

and

...

resolved,

...

use

...

the

...

'getSourceOf'

...

or

...

'getTargetOf'

...

methods

...

on

...

the

...

ResolvedConceptReference

...

to

...

find

...

the

...

Associations

...

of

...

a

...

given

...

Code.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getSemanticTypeCollectionbyCui

Use 'CodedNodeSet'

...

API

...

-

...

adding

...

a

...

'restrictToCodes'

...

restriction.

...

Note

...

that

...

a

...

CUI

...

is

...

simply

...

a

...

reference

...

to

...

a

...

Code

...

in

...

the

...

NCI

...

MetaThesaurus

...

ontology.

...

To

...

find

...

the

...

a

...

given

...

code,

...

for

...

example,

...

code

...

'C1234'

...

in

...

the

...

'NCI

...

Thesaurus'

...

ontology

...

-

...

first

...

obtain

...

a

...

'CodedNodeSet'

...

from

...

the

...

'NCI

...

Thesaurus'

...

ontology:

{
Code Block
}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to 
search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = 
ConvenienceMethods.createConceptReferenceList(new String[] 
{ "C1234"}, "NCI Thesaurus");
    
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, null, 1);
{code}

Once

...

the

...

ResolvedConceptReference

...

has

...

been

...

obtained,

...

extract

...

the

...

desired

...

Properties

...

and

...

inspect

...

the

...

Qualifiers

...

for

...

the

...

Semantic

...

Type.

...

getQualifierCollectionbyName

Use 'CodedNodeSet'

...

API

...

-

...

adding

...

a

...

'restrictToCodes'

...

restriction.

...

Note

...

that

...

a

...

CUI

...

is

...

simply

...

a

...

reference

...

to

...

a

...

Code

...

in

...

the

...

NCI

...

MetaThesaurus

...

ontology.

...

To

...

find

...

the

...

a

...

given

...

code,

...

for

...

example,

...

code

...

'C1234'

...

in

...

the

...

'NCI

...

Thesaurus'

...

ontology

...

-

...

first

...

obtain

...

a

...

'CodedNodeSet'

...

from

...

the

...

'NCI

...

Thesaurus'

...

ontology:

{
Code Block
}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to 
search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = 
ConvenienceMethods.createConceptReferenceList(new String[] 
{ "C1234"}, "NCI Thesaurus");
    
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

Once

...

the

...

ResolvedConceptReference

...

has

...

been

...

obtained,

...

extract

...

the

...

desired

...

Properties

...

and

...

inspect

...

the

...

Qualifiers.

{:=
Info
title
Note
}

Associations

between

codes

may

also

have

Qualifiers.

{info} h3. getAtomCollectionbyCui In

getAtomCollectionbyCui

In LexEVS,

...

a

...

NCI

...

MetaThesaurus

...

CUI

...

is

...

represented

...

by

...

an

...

Entity

...

(with

...

the

...

CUI

...

being

...

the

...

code

...

for

...

that

...

Entity).

...


Atoms

...

of

...

that

...

CUI

...

are

...

represented

...

by

...

'Presentation'(s)

...

of

...

the

...

Entity.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getSynonymCollectionbyCui

Use 'CodedNodeGraph'

...

API

...

-

...

restricting

...

to

...

Synonym

...

Associations.

...

Note:

...

Each

...

ontology

...

may

...

describe

...

their

...

Synonym

...

Associations

...

differently.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getSourceCollectionbyCui

Use 'CodedNodeSet'

...

API

...

-

...

adding

...

a

...

'restrictToCodes'

...

restriction.

...

Note

...

that

...

a

...

CUI

...

is

...

simply

...

a

...

reference

...

to

...

a

...

Code

...

in

...

the

...

NCI

...

MetaThesaurus

...

ontology.

...

To

...

find

...

the

...

a

...

given

...

code,

...

for

...

example,

...

code

...

'C1234'

...

in

...

the

...

'NCI

...

Thesaurus'

...

ontology

...

-

...

first

...

obtain

...

a

...

'CodedNodeSet'

...

from

...

the

...

'NCI

...

Thesaurus'

...

ontology:

{
Code Block
}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to 
search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = 
ConvenienceMethods.createConceptReferenceList(new String[] 
{ "C1234"}, "NCI Thesaurus");
    
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

Once

...

the

...

ResolvedConceptReference

...

has

...

been

...

obtained,

...

extract

...

the

...

desired

...

Properties

...

and

...

inspect

...

Source

...

using

...

'getSource'.

...

getSemanticTypeCollectionbyCui

Use 'CodedNodeSet'

...

API

...

-

...

adding

...

a

...

'restrictToCodes'

...

restriction.

...

Note

...

that

...

a

...

CUI

...

is

...

simply

...

a

...

reference

...

to

...

a

...

Code

...

in

...

the

...

NCI

...

MetaThesaurus

...

ontology.

...

To

...

find

...

the

...

a

...

given

...

code,

...

for

...

example,

...

code

...

'C1234'

...

in

...

the

...

'NCI

...

Thesaurus'

...

ontology

...

-

...

first

...

obtain

...

a

...

'CodedNodeSet'

...

from

...

the

...

'NCI

...

Thesaurus'

...

ontology:

{
Code Block
}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to 
search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = 
ConvenienceMethods.createConceptReferenceList(new String[] 
{ "C1234"}, "NCI Thesaurus");
    
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

Once

...

the

...

ResolvedConceptReference

...

has

...

been

...

obtained,

...

extract

...

the

...

desired

...

Properties

...

and

...

inspect

...

the

...

Semantic

...

Types.

...

Semantic

...

Types

...

are

...

held

...

as

...

Qualifiers

...

to

...

the

...

Properties

...

of

...

an

...

Entity.

...

getSourcebyDefinition

Use 'CodedNodeSet'

...

API

...

-

...

adding

...

a

...

'restrictToCodes'

...

restriction.

...

To

...

find

...

a

...

given

...

code,

...

for

...

example,

...

code

...

'C1234'

...

in

...

the

...

'NCI

...

Thesaurus'

...

ontology

...

-

...

first

...

obtain

...

a

...

'CodedNodeSet'

...

from

...

the

...

'NCI

...

Thesaurus'

...

ontology:

{
Code Block
}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts("NCI 
Thesaurus", null);
{code}

;

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to 
search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = 
ConvenienceMethods.createConceptReferenceList(new String[] 
{ "C1234"}, "NCI Thesaurus");
   
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

Once

...

the

...

ResolvedConceptReference

...

has

...

been

...

obtained,

...

using

...

'getDefinition',

...

extract

...

the

...

Definition

...

Collection

...

from

...

the

...

Entity.

...

Then

...

extract

...

the

...

source

...

using

...

'getSource'

...

getDefinitionCollectionbyCui

Use 'CodedNodeSet'

...

API

...

-

...

adding

...

a

...

'restrictToCodes'

...

restriction.

...

To

...

find

...

the

...

a

...

given

...

code,

...

for

...

example,

...

code

...

'C1234'

...

in

...

the

...

'NCI

...

Thesaurus'

...

ontology

...

-

...

first

...

obtain

...

a

...

'CodedNodeSet'

...

from

...

the

...

'NCI

...

Thesaurus'

...

ontology:

{
Code Block
}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts
("NCI Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = ConvenienceMethods.createConceptReferenceList
(new String[] 
{ "C1234"}, "NCI Thesaurus");
    
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

Once

...

the

...

ResolvedConceptReference

...

has

...

been

...

obtained,

...

use

...

the

...

'getReferencedEntry'

...

method

...

to

...

obtain

...

the

...

actual

...

Entity.

...

Using

...

the

...

'getDefinition',

...

extract

...

the

...

Definition

...

Collection

...

from

...

the

...

Entity.

getPropertyCollectionbyName

To find the Properties of a given code, for example, a code with a name of 'Heart' in the 'NCI Thesaurus' ontology - first obtain a 'CodedNodeSet' from the 'NCI Thesaurus' ontology:

Code Block


h3. getPropertyCollectionbyName
To find the Properties of a given code, for example, a code with a name of 'Heart' in the 'NCI Thesaurus' ontology - first obtain a 'CodedNodeSet' from the 'NCI Thesaurus' ontology:

{code}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts
("NCI Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

Name

...

('Heart'

...

in

...

this

...

example):

{:=
Info
title
Note
}

To

match

the

String

'Heart'

exactly,

use

the

search

algorithm

'exactMatch'.

Code Block
{info}

{code}
 //Next, restrice the CodedNodeSet.
   cns = cns.restrictToMatchingDesignations("Heart", null, "exactMatch", null);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, null, 1);
{code}

To

...

view

...

the

...

Properties,

...

see

...

'getPropertyValues'

...

above.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

getPropertyCollectionbyCode

To find the Properties of a given code, for example, code 'C1234' in the 'NCI Thesaurus' ontology - first obtain a 'CodedNodeSet' from the 'NCI Thesaurus' ontology:

Code Block


h3. getPropertyCollectionbyCode
To find the Properties of a given code, for example, code 'C1234' in the 'NCI Thesaurus' ontology - first obtain a 'CodedNodeSet' from the 'NCI Thesaurus' ontology:

{code}
 ResolvedConceptReferenceList cns = lbSvc.getCodingSchemeConcepts
("NCI Thesaurus", null);
{code}

Next,

...

restrict

...

that

...

to

...

the

...

desired

...

Code

...

('C1234'

...

in

...

this

...

example):

{
Code Block
}
 //First create a ConceptReferenceList to describe the Concept to search for. 
 //In this example we use the helper class 'ConvenienceMethods'.
 ConceptReferenceList crefs = ConvenienceMethods.createConceptReferenceList
(new String[] 
{ "C1234"}, "NCI Thesaurus");
    
 //Next, restrice the CodedNodeSet.
 cns.restrictToCodes(crefs);
{code}

Lastly,

...

resolve

...

the

...

match.

{
Code Block
}
 ResolvedConceptReferenceList matches = cns.resolveToList(null, null, 
null, 1);
{code}

To

...

view

...

the

...

Properties,

...

see

...

'getPropertyValues'

...

above.

...

For

...

examples,

...

see

...

the

...

LexEVS

...

Example

...

classes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

fetchPropertyCollectionByCodes

See 'getPropertyCollectionbyCode;

...

getRoleCollectionbyCode

Use the CodedNodeGraph API to find the immediate relations of a Concept.

If a desired Relations Collection is requested (for example, 'roles'),

...

the

...

'relationContainerName'

...

may

...

be

...

restricted.

...


For

...

instance:

{
Code Block
}
 //Restrict the 'relationContainerName' to the desired container. NOTE: These containers are
 //ontology specific--each ontology defines its own relation container names.
 CodedNodeGraph cng = lexevsService.getNodeGraph(String codingScheme, 
CodingSchemeVersionOrTag versionOrTag, String relationContainerName);
 ResolvedConceptReference[] rcr = cng.resolveAsList(ConceptReference 
graphFocus, boolean resolveForward, boolean resolveBackward, 
                                           int resolveCodedEntryDepth, int 
resolveAssociationDepth, LocalNameList propertyNames, 
                                          PropertyType[] propertyTypes, 
SortOptionList sortOptions, int maxToReturn).getResolvedConceptReference();
{code}

Focus

...

the

...

'graphFocus'

...

on

...

the

...

desired

...

Concept

...

to

...

see

...

relationships

...

from

...

a

...

given

...

Concept.

...

Once

...

focused

...

and

...

resolved,

...

use

...

the

...

'getSourceOf'

...

or

...

'getTargetOf'

...

methods

...

on

...

the

...

ResolvedConceptReference

...

to

...

find

...

the

...

Associations

...

of

...

a

...

given

...

Code.

...

For

...

examples,

...

see

...

the

...

LexEVS

...

Example

...

classes

...

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

getInverseRoleCollectionbyCode

Use the CodedNodeGraph API to find the immediate relations of a Concept.

To find the Inverse Roles, restricting the Relations Container may be necessary (see getRoleCollectionbyCode above).
Depending on how the onotology defines an 'inverse' role or association, these can be restricted as well.

For instance:

Code Block


h3. getInverseRoleCollectionbyCode
Use the *CodedNodeGraph* API to find the immediate relations of a Concept.

To find the Inverse Roles, restricting the Relations Container may be necessary (see getRoleCollectionbyCode above).
Depending on how the onotology defines an 'inverse' role or association, these can be restricted as well.

For instance:
{code}
 CodedNodeGraph cng = lexevsService.getNodeGraph(String codingScheme, 
CodingSchemeVersionOrTag versionOrTag, String relationContainerName);
 ResolvedConceptReference[] rcr = cng.resolveAsList(ConceptReference 
graphFocus, boolean resolveForward, boolean resolveBackward, 
                                         int resolveCodedEntryDepth, int 
resolveAssociationDepth, LocalNameList propertyNames, 
                                         PropertyType[] propertyTypes, 
SortOptionList sortOptions, int maxToReturn).getResolvedConceptReference();
{code}

Focus

...

the

...

'graphFocus'

...

on

...

the

...

desired

...

Concept

...

to

...

see

...

relationships

...

from

...

a

...

given

...

Concept.

...

Once

...

focused

...

and

...

resolved,

...

use

...

the

...

'getSourceOf'

...

or

...

'getTargetOf'

...

methods

...

on

...

the

...

ResolvedConceptReference

...

to

...

find

...

the

...

Associations

...

of

...

a

...

given

...

Code.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

getInverseAssociationCollectionbyCode

Use the CodedNodeGraph API to find the immediate relations of a Concept.

To find the Inverse Collections, restricting the Relations Container may be necessary (see getInverseRoleCollectionbyCode above).
Depending on how the onotology defines an 'inverse' role or association, these can be restricted as well.

For instance:

Code Block


h3. getInverseAssociationCollectionbyCode
Use the *CodedNodeGraph* API to find the immediate relations of a Concept.

To find the Inverse Collections, restricting the Relations Container may be necessary (see getInverseRoleCollectionbyCode above).
Depending on how the onotology defines an 'inverse' role or association, these can be restricted as well.

For instance:
{code}
 CodedNodeGraph cng = lexevsService.getNodeGraph(String codingScheme, 
CodingSchemeVersionOrTag versionOrTag, String relationContainerName);
 ResolvedConceptReference[] rcr = cng.resolveAsList(ConceptReference 
graphFocus, boolean resolveForward, boolean resolveBackward, 
                                       int resolveCodedEntryDepth, int 
resolveAssociationDepth, LocalNameList propertyNames, 
                                       PropertyType[] propertyTypes, 
SortOptionList sortOptions, int maxToReturn).getResolvedConceptReference();
{code}

Focus

...

the

...

'graphFocus'

...

on

...

the

...

desired

...

Concept

...

to

...

see

...

relationships

...

from

...

a

...

given

...

Concept.

...

Once

...

focused

...

and

...

resolved,

...

use

...

the

...

'getSourceOf'

...

or

...

'getTargetOf'

...

methods

...

on

...

the

...

ResolvedConceptReference

...

to

...

find

...

the

...

Associations

...

of

...

a

...

given

...

Code.

...

For

...

examples,

...

see

...

the

...

following

...

LexEVS

...

Example

...

classes:

...

  • org.LexGrid.LexBIG.example.FindRelatedCodes

...

  • org.LexGrid.LexBIG.example.FindPropsAndAssocForCode

...

getHasParentsbyCode

Either:

...

  • Use

...

  • the

...

  • 'LexBIGServiceConvenienceMethods'

...

  • API

...

  • method

...

  • 'getHierarchyLevelPrev'

...

  • Use

...

  • the

...

  • CodedNodeGraph

...

  • API

...

  • to

...

  • resolve

...

  • the

...

  • immediate

...

  • Associations

...

  • of

...

  • a

...

  • given

...

  • code,

...

  • and

...

  • check

...

  • if

...

  • they

...

  • exist.

...

getHasChildrenbyCode

Either:

...

  • Use

...

  • the

...

  • 'LexBIGServiceConvenienceMethods'

...

  • API

...

  • method

...

  • 'getHierarchyLevelNext'

...

  • Use

...

  • the

...

  • CodedNodeGraph

...

  • API

...

  • to

...

  • resolve

...

  • the

...

  • immediate

...

  • Associations

...

  • of

...

  • a

...

  • given

...

  • code,

...

  • and

...

  • check

...

  • if

...

  • they

...

  • exist.

...

getIsRetiredbyCode

Use the 'LexBIGServiceConvenienceMethods'

...

API

...

method

...

'isCodeRetired'

...

getLocalNames

Use the 'LexBIGService'

...

API

...

method

...

'getSupportedCodingSchemes'

...

-

...

and

...

extract

...

the

...

Names

...

(local

...

name,

...

registered

...

name,

...

etc...)

...

as

...

needed.

...

Scrollbar
iconsfalse