Page History
...
Panel | ||
---|---|---|
| ||
Table of Contents | ||
---|---|---|
|
Introduction
LexEVS CTS2 Code System Authoring API provides capability to author Code System and its contents.
...
Description: | Creates new coding system. | ||||||||
Input: |
| ||||||||
Output: | org.LexGrid.codingSchemes.CodingScheme - Created Code System | ||||||||
Exception: | org.LexGrid.LexBIG.Exceptions.LBException | ||||||||
Sample Call: |
|
...
Description: | Adds new properties to code system. | ||||||||
Input: |
| ||||||||
Output: | org.LexGrid.codingSchemes.CodingScheme - Updated Code System | ||||||||
Exception: | org.LexGrid.LexBIG.Exceptions.LBException | ||||||||
Sample Call: |
|
...
This function creates a new Code System Supplement as a container of a set of concepts and concept properties to be appended to a target code system. This function does not add the concepts and properties.
createCodeSystemSuppliment(AbsoluteCodingSchemeVersionReference parent, AbsoluteCodingSchemeVersionReference supplement)
*Description: * | Creates a new Code System Supplement as a container of a set of concepts and concept properties to be appended to a target code system. |
*Input: * |
...
|
...
*Output: * |
...
None |
...
*Exception: * |
...
org.lexevs.cts2.exception.author.InvalidCodeSystemSupplementException |
...
*Sample Call: * |
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
createConcept
This function creates a concept to be included in a Code System. The new concept is defined by the set of meta-data properties that describe it.
createConcept(String codingSchemeUri, String codeSystemVersion, String conceptCode, String namespace, RevisionInfo revision)
*Description: * | Creates new concept in a code system. |
*Input: * |
...
|
...
*Output: * |
...
None |
...
*Exception: * |
...
org.LexGrid.LexBIG.Exceptions.LBException |
...
*Sample Call: * |
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
addNewConceptProperty
This function provides capability to add a new property to a concept.
addNewConceptProperty(String codingSchemeUri, String codeSystemVersion, String conceptCode, String namespace, Property property, RevisionInfo revision)
Description: *Description: * | Adds a new property to a concept. |
*Input: * |
...
|
...
*Output: * |
...
None |
...
*Exception: * |
...
org.LexGrid.LexBIG.Exceptions.LBException |
...
*Sample Call: * |
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
createAssociationType
This function provides capability to create a new association type, an instance of which may be used to link two concepts.
createAssociationType(String codingSchemeUri, String codeSystemVersion, String relationsContainerName, String associationName, String forwardName, String reverseName, Boolean isNavigable, Boolean isTransitive, RevisionInfo revision)
Description: *Description: * | Creates new association type. |
*Input: * |
...
|
...
*Output: * |
...
None |
...
*Exception: * |
...
org.LexGrid.LexBIG.Exceptions.LBException |
...
*Sample Call: * |
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
Edit Operations
The edit operation provides the capability to modify existing code system resources like code system metadata, property, concept, association type etc. For every entry that gets modified, a unique revision(version) identifier will be assigned to that entry. This helps in retrieving snapshots of an entry based on its revision(version) identifier. This unique id can be passed in using the RevisionInfo object described above.
updateCodeSystem
This function provides capability to modify the meta-data that describes the Code System. This method takes in any changes to the meta-data as a form of input parameters. If 'null' no changes will be performed on that particular attribute.
...
*Description: *
...
Modify the meta-data that describes the Code System.
...
*Input: *
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
updateCodeSystemProperties
This function provides capability to update properties of a Code System.
updateCodeSystemProperties(RevisionInfo revision, String codingSchemeName, String codingSchemeURI, String representsVersion, Properties properties)'
*Description: * | Updates properties of a code system. |
*Input: * |
...
|
...
*Output: * |
...
org.LexGrid.codingSchemes.CodingScheme - Updated Code System |
...
*Exception: * |
...
org.LexGrid.LexBIG.Exceptions.LBException |
...
*Sample Call: * |
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
Presentation prop = new Presentation();
prop.setPropertyId("propertyId1");
prop.setPropertyName("propertyName");
prop.setIsActive(true);
prop.setLanguage("eng");
...
properties.addProperty(prop);
Code Block |
---|
* _Step 4:_ call modify properties method by passing the code system information and modified set of properties: |
...
|
CodingScheme codeScheme = csAuthOp.updateCodeSystemProperties(revInfo, "New Coding Scheme", "urn:oid:11.11.0.99", "1.0", properties);
...
updateConcept
This function provides capability to modify existing concept in a Code System.
...
*Description: *
...
Modified an existing concept in a code system.
...
*Input: *
Code Block |
---|
|
h4. updateConcept
This function provides capability to modify existing concept in a Code System.
{{updateConcept(String codingSchemeUri, String codeSystemVersion, Entity entity, RevisionInfo revisionInfo)}}
| *Description:* | Modified an existing concept in a code system. |
| *Input:* | * *_ |
Panel |
java.lang.String codingSchemeURI_* - (*Mandatory*) URI of Code System that contains the concept. * *_java.lang.String codeSystemVersion_* - (*Mandatory*) Version of Code System that contains the concept. * *_org.LexGrid.concepts.Entity entity_* - (*Mandatory*) Modified concept(Entity object). * *_org.lexevs.cts2.core.update.RevisionInfo revision_* - (*Mandatory*) Contains revision information like unique RevisionId, change description, author information etc. | | *Output:* |
...
Panel |
---|
None | |
| None | | *Exception: |
...
Panel |
---|
* | *_org.LexGrid.LexBIG.Exceptions.LBException_* | | *Sample Call:* | * |
...
_Step 1:_ Instantiate CodeSystemAuthoringOperation if it is not done yet : |
Panel |
---|
org.lexevs.cts2.author.CodeSystemAuthoringOperation csAuthorOp = LexEvsCTS2Impl.defaultInstance().getAuthoringOperation().getCodeSystemAuthoringOperation();_
- Step 2: Populate RevisionInfo object:
...
Code Block RevisionInfo revInfo = new RevisionInfo();
...
revInfo.setChangeAgent("change Agent Name");
...
revInfo.setChangeInstruction("here goes the change Instructions");
...
revInfo.setDescription("description of the resource");
...
revInfo.setEditOrder(1L);
...
revInfo.setRevisionDate(new Date());
...
revInfo.setRevisionId(UUID.randomUUID().toString());
...
* _Step 3:_ Populate Entity with modified concept:
...
Entity entityToUpdate = new Entity();
entityToUpdate.setEntityCode("C12345");
entityToUpdate.setEntityCodeNamespace("NCIT");
entityToUpdate.setEntityDescription(Constructors.createEntityDescription("Modified ED"));Code Block * _Step 4:_ call modify concept method by passing code system version and concept information:
...
csAuthOp.updateConcept("NCIT", "10.0", entityToUpdate, revInfo);
...
updateConceptProperty
This function provides capability to modify existing property of a concept.
...
*Description: *
...
Modifies existing property of a concept.
...
*Input: *
...
Code Block | h4. updateConceptProperty This function provides capability to modify existing property of a concept. {{updateConceptProperty(String codingSchemeUri, String codeSystemVersion, String conceptCode, String namespace, Property property, RevisionInfo revision)}} | *Description:* | Modifies existing property of a concept. | | *Input:* | * *_java.lang.String codingSchemeURI_* - (*Mandatory*) URI of a Code System that contains the concept.
...
* *_java.lang.String codeSystemVersion_* - (*Mandatory*) Version of a Code System that contains the concept.
...
* *_java.lang.String conceptCode_* - (*Mandatory*) Concept code that contains the property.
...
* *_java.lang.String namespace_* - (*Mandatory*) Namespace of a concept that contains the property.
...
* *_org.LexGrid.commonTypes.Property property_* - (*Mandatory*) Modified property.
...
* *_org.lexevs.cts2.core.update.RevisionInfo revision_* - (*Mandatory*) Contains revision information like unique RevisionId, change description, author information etc. |
...
| *Output:*
...
Panel |
---|
None | |
| None | | *Exception:*
...
| *_org.LexGrid.LexBIG.Exceptions.LBException_* | |
...
*Sample Call
...
:* | * _Step 1:_ Instantiate CodeSystemAuthoringOperation if it is not done yet :
...
org.lexevs.cts2.author.CodeSystemAuthoringOperation csAuthorOp = LexEvsCTS2Impl.defaultInstance().getAuthoringOperation().getCodeSystemAuthoringOperation();Code Block * _Step 2:_ Populate RevisionInfo object:
...
- RevisionInfo revInfo = new RevisionInfo();
revInfo.setChangeAgent("change Agent Name");
revInfo.setChangeInstruction("here goes the change Instructions");
revInfo.setDescription("description of the resource");
revInfo.setEditOrder(1L);
revInfo.setRevisionDate(new Date());
revInfo.setRevisionId(UUID.randomUUID().toString());Code Block * _Step 3:_ Populate a modified property. Just modified isActive to 'true' and language to 'eng' in property 'propertyId1':
...
- Property prop = new Property();
prop.setPropertyId("propertyId1");
prop.setPropertyName("propertyName");
prop.setIsActive(true);
prop.setLanguage("eng");Code Block * _Step 4:_ call update property method by passing the code system information, concept information and the modified property:
...
csAuthOp.updateConceptProperty("urn:oid:11.11.0.99", "1.0", "C12345", "NCIT", prop, revInfo);
...
updateAssociationType
This function provides capability to modify existing association type.
...
*Description: *
...
Modifies existing association type.
...
*Input: *
...
Code Block | h4. updateAssociationType This function provides capability to modify existing association type. {{updateAssociationType(String codingSchemeUri, String codeSystemVersion, AssociationEntity associationEntity, RevisionInfo revision)}} | *Description:* | Modifies existing association type. | | *Input:* | * *_java.lang.String codingSchemeURI_* - (*Mandatory*) URI of a Code System that contains the association type.
...
* *_java.lang.String codeSystemVersion_* - (*Mandatory*) Version of a Code System that contains the association type.
...
* *_org.LexGrid.relations.AssociationEntity associationEntity_* - (*Mandatory*) Modified association type.
...
* *_org.lexevs.cts2.core.update.RevisionInfo revision_* - (*Mandatory*) Contains revision information like unique RevisionId, change description, author information etc. | |
...
*Output:*
...
Panel |
---|
None | |
| None | | *Exception:*
...
| *_org.LexGrid.LexBIG.Exceptions.LBException_* | |
...
*Sample Call:*
...
| * _Step 1:_ Instantiate CodeSystemAuthoringOperation if it is not done yet :
...
org.lexevs.cts2.author.CodeSystemAuthoringOperation csAuthorOp = LexEvsCTS2Impl.defaultInstance().getAuthoringOperation().getCodeSystemAuthoringOperation();- Step 2: Populate RevisionInfo object:
...
Code Block RevisionInfo revInfo = new RevisionInfo();
...
revInfo.setChangeAgent("change Agent Name");
...
revInfo.setChangeInstruction("here goes the change Instructions");
...
revInfo.setDescription("description of the resource");
...
revInfo.setEditOrder(1L);
...
revInfo.setRevisionDate(new Date());
...
revInfo.setRevisionId(UUID.randomUUID().toString());
...
* _Step 3:_ Populate a modified association type. Just modified isActive to 'true' and forwardName to 'newForwardName' for associationType 'SameAS':
...
AssociationEntity associationEntity = new AssociationEntity();
associationEntity.setEntityCode("SameAs");
associationEntity.setIsActive(true);
associationEntity.setForwardName("NewForwardName");Code Block * _Step 4:_ call update association type method by passing the code system information and the modified association type:
...
- csAuthOp.updateAssociationType("urn:oid:11.11.0.99", "1.0", associationEntity, revInfo);
...
Remove Operations
Remove operation provides capability to remove code system and its contents.
removeCodeSystem
This function provides capability to remove entire code system from terminology service.
...
*Description: *
...
Remove entire code system from terminology service.
...
*Input: *
...
Code Block | h3. Remove Operations Remove operation provides capability to remove code system and its contents. h4. removeCodeSystem This function provides capability to remove entire code system from terminology service. {{removeCodeSystem(RevisionInfo revision, String codingSchemeURI, String representsVersion)}} | *Description:* | Remove entire code system from terminology service. | | *Input:* | * *_org.lexevs.cts2.core.update.RevisionInfo revision_* - (*Mandatory*) Contains revision information like unique RevisionId, change description, author
...
information etc. * *_java.lang.String codingSchemeURI_* - (*Mandatory*) URI of a Code System that needs to be removed.
...
* *_java.lang.String codeSystemVersion_* - (*Mandatory*) Version of a Code System that needs to be removed. | |
...
*Output:
...
Panel |
---|
boolean - True means deletion was success, otherwise false. | |
*Exception: * |
...
* | *_boolean_* - True means deletion was success, otherwise false. | | *Exception:* | *_org.LexGrid.LexBIG.Exceptions.LBException_* | |
...
*Sample Call:
...
* | * _Step 1:_ Instantiate CodeSystemAuthoringOperation if it is not done yet :
...
org.lexevs.cts2.author.CodeSystemAuthoringOperation csAuthorOp = LexEvsCTS2Impl.defaultInstance().getAuthoringOperation().getCodeSystemAuthoringOperation();Code Block * _Step 2:_ Populate RevisionInfo object:
...
RevisionInfo revInfo = new RevisionInfo();
revInfo.setChangeAgent("change Agent Name");
revInfo.setChangeInstruction("here goes the change Instructions");
revInfo.setDescription("description of the resource");
revInfo.setEditOrder(1L);
revInfo.setRevisionDate(new Date());
revInfo.setRevisionId(UUID.randomUUID().toString());- Step 3: call remove code system method by passing the code system information:
...
|Code Block csAuthOp.removeCodeSystem(revInfo, "urn:oid:11.11.0.99", "1.0");
removeCodeSystemProperty
This function provides capability to remove property of a Code System.
removeCodeSystemProperty(RevisionInfo revision, String codingSchemeURI, String representsVersion, String propertyId)
*Description: * | Removes a property of a Code System |
*Input: * |
...
|
...
*Output: * |
...
org.LexGrid.codingSchemes.CodingScheme - Updated Code System |
...
*Exception: * |
...
org.LexGrid.LexBIG.Exceptions.LBException |
...
*Sample Call: * |
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
deleteConcept
This function provides capability to remove a concept from code system.
...
*Description: *
...
Removes a concept from code system.
...
*Input: *
...
|
...
|
...
|
...
|
...
|
...
|
Panel |
---|
None | |
|
...
|
...
|
...
|
...
|
...
|
...
|
...
deleteConceptProperty
This function provides capability to remove property of a concept.
deleteConceptProperty(String codingSchemeUri, String codeSystemVersion, String conceptCode, String namespace, Property property, RevisionInfo revision)
Description: *Description: * | Removes a property of a concept. |
*Input: * |
...
|
...
*Output: * |
...
None |
*Exception: * |
...
org.LexGrid.LexBIG.Exceptions.LBException |
*Sample Call: * |
Step 1: Instantiate CodeSystemAuthoringOperation if it is not done yet :
...
org.lexevs.cts2.author.CodeSystemAuthoringOperation csAuthorOp = LexEvsCTS2Impl.defaultInstance().getAuthoringOperation().getCodeSystemAuthoringOperation();
Step 2: Populate RevisionInfo object:
...
RevisionInfo revInfo = new RevisionInfo();
revInfo.setChangeAgent("change Agent Name");
revInfo.setChangeInstruction("here goes the change Instructions");
revInfo.setDescription("description of the resource");
revInfo.setEditOrder(1L);
revInfo.setRevisionDate(new Date());
revInfo.setRevisionId(UUID.randomUUID().toString());
Step 3: Populate property that needs to be removed:
...
Property propertyToRemove = new Property();
propertyToRemove.setPropertyId("p1");
Step 2: Call remove property method by passing the code system, concept and property information:
...
csAuthOp.deleteConceptProperty("urn:oid:11.11.0.99", "1.0", "C1234", "NCIT", propertyToRemove, revInfo); |
Status Change Operations
Status Change operations provides the capability to change the status a code system or a concept. Status could anything like : isActive, retired, published, pending etc. There is also a flag called 'isActive' that is associated with both code system and concept meta-data that can be changed using this function as well.
...
*Description: * | Modifies the status of a code system. |
*Input: * |
...
java.lang.String codingSchemeURI - (Mandatory) Code System URI.
java.lang.String representsVersion - (Mandatory) Version of the Code System.
java.lang.String status - (Mandatory) Modified status value.
java.lang.Boolean isActive - (Optional) Set to true or false. Null for no change.
org.lexevs.cts2.core.update.RevisionInfo revision - (Mandatory) Contains revision information like unique RevisionId, change description, author information etc. |
*Output: * |
...
None |
*Exception: * |
...
org.LexGrid.LexBIG.Exceptions.LBException |
*Sample Call: * |
Step 1: Instantiate CodeSystemAuthoringOperation if it is not done yet :
...
org.lexevs.cts2.author.CodeSystemAuthoringOperation csAuthorOp = LexEvsCTS2Impl.defaultInstance().getAuthoringOperation().getCodeSystemAuthoringOperation();
Step 2: Populate RevisionInfo object:
...
RevisionInfo revInfo = new RevisionInfo();
revInfo.setChangeAgent("change Agent Name");
revInfo.setChangeInstruction("here goes the change Instructions");
revInfo.setDescription("description of the resource");
revInfo.setEditOrder(1L);
revInfo.setRevisionDate(new Date());
revInfo.setRevisionId(UUID.randomUUID().toString());
Step 2: Call status change method by passing the code system and status information:
...
csAuthOp.updateCodeSystemVersionStatus("urn:oid:11.11.0.99", "1.0", "Active", true, revInfo); |
updateConceptStatus
This function modifies the status of a concept.
*Description: * | Modifies the status of a concept. |
*Input: * |
...
java.lang.String codingSchemeURI - (Mandatory) Code System URI that contains the concept.
java.lang.String representsVersion - (Mandatory) Version of the Code System that contains the concept.
java.lang.String conceptCode - (Mandatory) Code/identifier of a concept.
java.lang.String namespace - (Mandatory) Mamespace of a concept.
java.lang.String status - (Mandatory) Modified status value.
java.lang.Boolean isActive - (Optional) Set to true or false. Null for no change.
org.lexevs.cts2.core.update.RevisionInfo revision - (Mandatory) Contains revision information like unique RevisionId, change description, author information etc. |
*Output: * |
...
None |
*Exception: * |
...
org.LexGrid.LexBIG.Exceptions.LBException |
*Sample Call: * |
Step 1: Instantiate CodeSystemAuthoringOperation if it is not done yet :
...
org.lexevs.cts2.author.CodeSystemAuthoringOperation csAuthorOp = LexEvsCTS2Impl.defaultInstance().getAuthoringOperation().getCodeSystemAuthoringOperation();
Step 2: Populate RevisionInfo object:
...
RevisionInfo revInfo = new RevisionInfo();
revInfo.setChangeAgent("change Agent Name");
revInfo.setChangeInstruction("here goes the change Instructions");
revInfo.setDescription("description of the resource");
revInfo.setEditOrder(1L);
revInfo.setRevisionDate(new Date());
revInfo.setRevisionId(UUID.randomUUID().toString());
Step 2: Call status change method by passing the code system, concept and status information:
...
csAuthOp.updateCodeSystemVersionStatus("urn:oid:11.11.0.99", "1.0", "C1234", "NCIT", "Active", true, revInfo); |
Scrollbar | ||
---|---|---|
|