Concept/Terminology Provider

IConceptRepositoryService in assembly SanteDB.Core.Api version 3.0.1980.0

Summary

Represents a service which is responsible for the maintenance of concepts.

Description

This class is responsible for the management of Concept, ConceptSet, and ReferenceTerm definitions from the SanteDB CDR's concept dictionary. The implementation of this service contract should provide methods for contacting the storage provider (either local database or a remote terminology service) to:

  • Resolve ReferenceTerm instances from inbound messages from code/system pairs

  • Resolve appropriate ReferenceTerm data given a Concept instance from the SanteDB CDR to be sent on an outbound message

  • Determine the membership of a Concept in a ConceptSet

  • Determiner relationships between Concept instances

Operations

Operation
Response/Return
Input/Parameter
Description

FindConceptsByName

IEnumerable<Concept>

String name String language

Searches for a by name and language.

FindConceptsByReferenceTerm

IEnumerable<ConceptReferenceTerm>

String code Uri codeSystem

Finds a concept by reference term information, returning the so the caller can determine if the and are equivalent, narrower than, etc.

GetConceptSetMembers

IEnumerable<Concept>

String mnemonic

Gets all the members of the specified concept set

GetConceptByReferenceTerm

Concept

String code String codeSystemDomain

Finds a concept by reference term only where the concept is equivalent to the reference term

FindConceptsByReferenceTerm

IEnumerable<ConceptReferenceTerm>

String code String codeSystemDomain

Finds a concept by reference term information, returning the so the caller can determine if the and are equivalent, narrower than, etc.

GetConcept

Concept

String mnemonic

Get a instance given the concept's unique mnemonic

Implies

Boolean

Concept a Concept b

Returns a value which indicates whether concept implies concept through a indicating the two are the same

IsMember

Boolean

ConceptSet set Concept concept

Returns true if the concept is a member of set

IsMember

Boolean

Guid set Guid concept

Returns true if the concept is a member of set

GetConceptReferenceTerm

ReferenceTerm

Guid conceptId String codeSystem Boolean exact

Gets the concept reference term for the specified code system

GetConceptReferenceTerm

ReferenceTerm

String conceptMnemonic String codeSystem

Gets the concept reference term for the specified code system

FindReferenceTermsByConcept

IEnumerable<ConceptReferenceTerm>

Guid conceptId String codeSystem

Finds all reference terms for the concept with in the specified system.

GetName

String

Guid conceptId String twoLetterISOLanguageName

Get the specified concept name

ExpandConceptSet

IQueryResultSet<Concept>

Guid conceptSetId

Expand the concept set to a flat list of values

ExpandConceptSet

IQueryResultSet<Concept>

String conceptSetMnemonic

Expand the concept set to a flat list of values

Implementations

LocalConceptRepository - (SanteDB.Core.Api)

Represents a service which is responsible for the maintenance of concepts using local persistence.

Service Registration

...
<section xsi:type="ApplicationServiceContextConfigurationSection" threadPoolSize="4">
	<serviceProviders>
		...
		<add type="SanteDB.Core.Services.Impl.Repository.LocalConceptRepository, SanteDB.Core.Api, Version=3.0.1980.0, Culture=neutral, PublicKeyToken=null" />
		...
	</serviceProviders>

Example Implementation

/// Example Implementation
using SanteDB.Core.Services;
/// Other usings here
public class MyConceptRepositoryService : SanteDB.Core.Services.IConceptRepositoryService { 
	public String ServiceName => "My own IConceptRepositoryService service";
	/// <summary>
	/// Searches for a  by name and language.
	/// </summary>
	public IEnumerable<Concept> FindConceptsByName(String name,String language){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Finds a concept by reference term information, returning the              so the caller can determine if the  and  are equivalent,            narrower than, etc.
	/// </summary>
	public IEnumerable<ConceptReferenceTerm> FindConceptsByReferenceTerm(String code,Uri codeSystem){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Gets all the  members of the specified concept set
	/// </summary>
	public IEnumerable<Concept> GetConceptSetMembers(String mnemonic){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Finds a concept by reference term only where the concept is equivalent to the reference term
	/// </summary>
	public Concept GetConceptByReferenceTerm(String code,String codeSystemDomain){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Finds a concept by reference term information, returning the              so the caller can determine if the  and  are equivalent,            narrower than, etc.
	/// </summary>
	public IEnumerable<ConceptReferenceTerm> FindConceptsByReferenceTerm(String code,String codeSystemDomain){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Get a  instance given the concept's unique mnemonic
	/// </summary>
	public Concept GetConcept(String mnemonic){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Returns a value which indicates whether concept  implies concept  through             a  indicating the two are the same
	/// </summary>
	public Boolean Implies(Concept a,Concept b){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Returns true if the concept  is a member of set
	/// </summary>
	public Boolean IsMember(ConceptSet set,Concept concept){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Returns true if the concept  is a member of set
	/// </summary>
	public Boolean IsMember(Guid set,Guid concept){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Gets the concept reference term for the specified code system
	/// </summary>
	public ReferenceTerm GetConceptReferenceTerm(Guid conceptId,String codeSystem,Boolean exact){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Gets the concept reference term for the specified code system
	/// </summary>
	public ReferenceTerm GetConceptReferenceTerm(String conceptMnemonic,String codeSystem){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Finds all reference terms for the concept with  in the specified  system.
	/// </summary>
	public IEnumerable<ConceptReferenceTerm> FindReferenceTermsByConcept(Guid conceptId,String codeSystem){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Get the specified concept name
	/// </summary>
	public String GetName(Guid conceptId,String twoLetterISOLanguageName){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Expand the concept set to a flat list of values
	/// </summary>
	public IQueryResultSet<Concept> ExpandConceptSet(Guid conceptSetId){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Expand the concept set to a flat list of values
	/// </summary>
	public IQueryResultSet<Concept> ExpandConceptSet(String conceptSetMnemonic){
		throw new System.NotImplementedException();
	}
}

References

Last updated