Name Alias Provider

IAliasProvider in assembly SanteDB.Core.Api version 3.0.1980.0

Summary

Provider for name and place aliasing

Description

Some implementations of the SanteDB engine allow for searching of data based on aliases. This aliasing allows SanteDB to map an inbound query parameter like 'Bob' to 'Robert' or 'Will' to 'Bill' and 'William'. The service is responsible for providing the known aliases for each name into the SanteDB infrastructure, and these can be accessed using the HDSI extended query filter:

name.component.value=:(alias|Bob)>=1.0
        which indicates that the aliases of the stored name should match Bob.

Operations

OperationResponse/ReturnInput/ParameterDescription

GetAlias

IEnumerable<ComponentAlias>

String name

Gets the known alias names and score for the alias

AddAlias

void

String name String alias Double weight

Add an alias to the alias provider

RemoveAlias

void

String name String alias

Remove the specified alias

GetAllAliases

IDictionary<String,IEnumerable<ComponentAlias>>

String filter Int32 offset Nullable<Int32> count Int32& totalResults

Get all aliases

Implementations

None

Example Implementation

/// Example Implementation
using SanteDB.Core.Services;
/// Other usings here
public class MyAliasProvider : SanteDB.Core.Services.IAliasProvider { 
	public String ServiceName => "My own IAliasProvider service";
	/// <summary>
	/// Gets the known alias names and score for the alias
	/// </summary>
	public IEnumerable<ComponentAlias> GetAlias(String name){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Add an alias to the alias provider
	/// </summary>
	public void AddAlias(String name,String alias,Double weight){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Remove the specified alias
	/// </summary>
	public void RemoveAlias(String name,String alias){
		throw new System.NotImplementedException();
	}
	/// <summary>
	/// Get all aliases
	/// </summary>
	public IDictionary<String,IEnumerable<ComponentAlias>> GetAllAliases(String filter,Int32 offset,Nullable<Int32> count,Int32& totalResults){
		throw new System.NotImplementedException();
	}
}

References

Last updated