Synchronize concepts for a given code system
(→Response) |
|||
Zeile 85: | Zeile 85: | ||
</S:Body> | </S:Body> | ||
</S:Envelope> | </S:Envelope> | ||
+ | </source> | ||
+ | =Java= | ||
+ | WSDL: http://193.25.22.69:8080/TermServer/Search?wsdl | ||
+ | |||
+ | Sample has been created with netbeans. You have to add a web service reference with above WSDL to use the code below. | ||
+ | |||
+ | <source lang="java"> | ||
</source> | </source> |
Version vom 2. Dezember 2014, 13:02 Uhr
Inhaltsverzeichnis |
Description
You can synchronize concepts for a given code system with the method "ListCodeSystemConcepts" in the "Search" web service.
Therefore you have to specify a timestamp from your last synchronization. If it is your first, leave it empty. You have to save the current timestamp at every synchronization and save it to specify it at the next call.
SOAP
Web service: Search
Method: ListCodeSystemConcepts
Request
versionId: versionId from your code system you want to get concepts from
isMainClass: true, if you want to get only the root concepts (if code system is hierarchical)
lookForward: true, if you want to get the childs from the concepts, if available (if code system is hierarchical)
statusVisibilityDate: your last synchronization date
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sear="http://search.ws.terminologie.fhdo.de/"> <soapenv:Header/> <soapenv:Body> <sear:ListCodeSystemConcepts> <parameter> <codeSystem> <codeSystemVersions> <versionId>1</versionId> </codeSystemVersions> </codeSystem> <codeSystemEntity> <codeSystemEntityVersions> <statusVisibilityDate>2014-11-17T11:10:00+01:00</statusVisibilityDate> </codeSystemEntityVersions> </codeSystemEntity> <searchParameter> </searchParameter> <lookForward>false</lookForward> </parameter> </sear:ListCodeSystemConcepts> </soapenv:Body> </soapenv:Envelope>
Response
The following result show all concepts which are changed after "2014-11-17T11:10:00+01:00". You have to update the concepts in your database.
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Body> <ns2:ListCodeSystemConceptsResponse xmlns:ns2="http://search.ws.terminologie.fhdo.de/"> <return> <returnInfos> <count>1</count> <message>Konzepte erfolgreich gelesen, Anzahl: 1</message> <overallErrorCategory>INFO</overallErrorCategory> <status>OK</status> </returnInfos> <codeSystemEntity> <codeSystemEntityVersions> <codeSystemConcepts> <code>C</code> <codeSystemEntityVersionId>7</codeSystemEntityVersionId> <isPreferred>true</isPreferred> <term>Testgemeinschaft C</term> </codeSystemConcepts> <effectiveDate>2014-11-17T11:11:48+01:00</effectiveDate> <insertTimestamp>2014-11-17T11:11:48+01:00</insertTimestamp> <isLeaf>true</isLeaf> <statusDeactivated>0</statusDeactivated> <statusDeactivatedDate>2014-11-17T11:11:48+01:00</statusDeactivatedDate> <statusVisibility>1</statusVisibility> <statusVisibilityDate>2014-11-17T11:11:48+01:00</statusVisibilityDate> <statusWorkflow>0</statusWorkflow> <statusWorkflowDate>2014-11-17T11:11:48+01:00</statusWorkflowDate> <versionId>7</versionId> </codeSystemEntityVersions> <codeSystemVersionEntityMemberships> <isAxis>false</isAxis> <isMainClass>true</isMainClass> </codeSystemVersionEntityMemberships> <currentVersionId>7</currentVersionId> <id>7</id> </codeSystemEntity> </return> </ns2:ListCodeSystemConceptsResponse> </S:Body> </S:Envelope>
Java
WSDL: http://193.25.22.69:8080/TermServer/Search?wsdl
Sample has been created with netbeans. You have to add a web service reference with above WSDL to use the code below.