Oracle® Healthcare Master Person Index Message Processing Reference Release 2.0.13 E25319-05 |
|
|
PDF · Mobi · ePub |
This chapter provides an overview of the Java API for an Oracle Healthcare Master Person Index (OHMPI) application. For detailed information about the JAVA API classes and methods, refer to the Oracle Healthcare Master Person Index Javadocs. Unless otherwise noted, all classes and methods described in this chapter are public. Methods inherited from classes other than those described in this chapter are listed, but not described:
This chapter includes the following sections:
Oracle Healthcare Master Person Index provides several Java classes and methods to use to transform and process data in a Master Person Index or IHE Profile project. The master person index API is specifically designed to help you maintain the integrity of the data in the database by providing specific methods for updating, adding, and merging records in the database.
Oracle Healthcare Master Person Index provides a set of JAVA API classes that can be used with any object structure for the OHMPI application.
JAVA API classes provide the methods you need to perform basic data cleansing and processing functions against incoming data, such as performing searches, reviewing potential duplicates, adding and updating records, and merging and unmerging records. The primary class containing these functions is the MasterController
class, which includes the executeMatch
methods. Several classes support the MasterController
class by defining additional objects and functions. Documentation for the JAVA API classes methods is provided in Javadoc format.
This method changes the status of a deactivated enterprise object back to active.
public void activateEnterpriseObject(java.lang.String euid)
Name | Description |
---|---|
euid | The EUID associated with the enterprise object to activate. |
None
ProcessingException
UserException
This method changes the status of a deactivated system object back to active.
public void activateSystemObject(SystemObjectPK systemKey)
Name | Description |
---|---|
systemKey | The system code and local ID of the system object to activate. |
None
ProcessingException
UserException
This method adds the system object to the enterprise object associated with the specified EUID.
public void addSystemObject(java.lang.String euid, SystemObject sysobj)
Name | Description |
---|---|
euid | The EUID of the enterprise object to which you want to add the system object. |
sysobj | The system object to add to the enterprise object. |
None
ProcessingException
UserException
This method calculates potential duplicates for the specified EUID and transaction ID.
public void calculatePotentialDuplicates(java.lang.String euid, java.lang.String transID)
Name | Description |
---|---|
euid | The EUID for which potential duplicates are calculated. |
transID | The transaction number for which potential duplicates are calculated. |
None
ProcessingException
This method calculates a new single best record (SBR) for an enterprise object that is updated.
public SBR calculateSBR(EnterpriseObject eo)
Name | Description |
---|---|
eo | The enterprise object whose SBR is recalculated. |
The recalculated SBR of the enterprise object.
ProcessingException
UserException
This method counts the number of assumed match records matching the date criteria specified in search object.
public int countAssumedMatches(AssumedMatchSearchObject amso)
None
Count of the assumed match records matching the search criteria.
ProcessingException
UserException
This method counts the number of potential duplicate records matching the criteria specified in search object.
public int countPotentialDuplicates(PotentialDuplicateSearchObject pdso)
None
Count of the potential duplicate records matching the search criteria.
ProcessingException
UserException
This method creates a new enterprise object to add to the master index database using the information in the specified system object.
public EnterpriseObject createEnterpriseObject(SystemObject sysobj)
Name | Description |
---|---|
sysobj | The system object to use as a basis for the enterprise object. |
The enterprise object created from the specified system object.
ProcessingException
UserException
This method changes the status of an enterprise object from active to inactive and deletes all potential duplicate listings for that object.
public void deactivateEnterpriseObject(java.lang.String euid)
Name | Description |
---|---|
euid | The EUID associated with the enterprise object to deactivate. |
None
ProcessingException
UserException
This method changes the status of an active system object to inactive.
public void deactivateSystemObject(SystemObjectPK systemKey)
Name | Description |
---|---|
systemKey | The system code and local ID of the system object to deactivate. |
None
ProcessingException
UserException
This method performs a query against the MPI database using search options specified in DeduplicationOption and attributes of system object. If a match is found, it performs an update using the system object and returns the updated enterprise object. If no match is found, a new enterprise object is created.
It always matches the entity with the highest match score for BLOCKER-SEARCH. The range search is not supported.
The deduplicateSystemObject API supports all the functionalities of block queries, matching policies except MostRecentReceived, survivorship rules, and update policies.
Note:
To merge and unmerge enterprise objects which contain the system-assigned local Ids, see Deduplication Merge Policy and Deduplication Unmerge Policy in Oracle Healthcare Master Person Index User's Guide.public DeduplicationResult deduplicateSystemObject(SystemObject so, DeduplicationOption option) throws ProcessingException, UserException;
Name | Description |
---|---|
SystemObject | The source system object with system code, and with or without the local ID assigned. |
DeduplicationOption | Options for the method.
|
DeduplicationResult that includes:
Euid: The euid of the enterprise object created or updated.
EnterpriseObject: The enterprise object created or updated.
resultCode: The status of the deduplication result. The valid values are MATCH_UPDATE, MATCH_NO_CHANGE, NEW_EO, and SYS_ID_MATCH.
matchScore: The match score if a match is found.
transactionId: The transaction ID.
potentialDuplicates: A list of potential duplicates if any potential duplicate is found.
ProcessingException
UserException
This method permanently deletes a system object from its associated enterprise object.
public void deleteSystemObject(SystemObjectPK systemKey)
Name | Description |
---|---|
systemKey | The system code and local ID of the system object to delete. |
None
ProcessingException
UserException
executeMatch
is one of four methods that process a system object based on the configuration defined for the Master Index Manager Service and associated runtime components. This method searches for possible matches in the database, and if it finds a match, it replaces the system object (instead of updating the system object, which is what executeMatchUpdate
does).
The following runtime components configure executeMatch
.
The Query Builder defines the blocking queries used for matching.
Threshold configuration specifies which blocking query to use and specifies matching parameters, including duplicate and match thresholds and whether potential duplicates are automatically recalculated for updated records.
The pass controller and block picker classes specify how the blocking query is executed.
public MatchResult executeMatch(SystemObject sysObj)
Name | Description |
---|---|
sysObj | The system object to process into the database. |
A match result object containing the results of the matching process.
ProcessingException
UserException
executeMatchDupRecalc
is one of four methods that process a system object based on the configuration defined for the Master Index Manager Service and associated runtime components. It is configured by the same components as executeMatch
, and is similar to executeMatch
but allows you to control whether potential duplicates are recalculated when an object is updated regardless of whether the update mode is set to optimistic or pessimistic.
executeMatchDupRecalc
differs from executeMatch
in two ways:
It provides an override flag for the update mode specified in the Threshold configuration file.
The match result object returned by this method includes an indicator of whether match fields were modified. This helps you determine whether you need to process potential duplicates for this object at a later time.
Note:
To process potential duplicates at a later time, callcalculatePotentialDuplicates
.public MatchResult executeMatchDupRecalc(SystemObject sysObj, java.lang.Boolean performPessimistic)
Name | Description |
---|---|
sysObj | The system object to process into the database. |
performPessimistic | A Boolean indicator of whether to recalculate potential duplicates on update or to defer it until later. Specify true to recalculate on update and false to defer the recalculation. |
A match result object containing the results of the matching process.
ProcessingException
UserException
executeMatchGui
is identical to executeMatch
, but it is only called by the Enterprise Data Manager. It processes a system object based on the configuration defined for the Master Index Manager Service and associated runtime components. This method searches for possible matches in the database, and if it finds a match, it replaces the system object (instead of updating the system object).
The following runtime components configure executeMatchGui
:
The Query Builder defines the blocking queries used for matching.
Threshold configuration specifies which blocking query to use and specifies matching parameters, including duplicate and match thresholds.
The pass controller and block picker classes specify how the blocking query is executed.
public MatchResult executeMatchGui(SystemObject sysObj)
Name | Description |
---|---|
sysObj | The system object to process into the database. |
A match result object containing the results of the matching process.
ProcessingException
UserException
executeMatchUpdate
is one of four methods that process a system object based on the configuration defined for the Master Index Manager Service and associated runtime components. It is configured by the same components as executeMatch
. This method searches for possible matches in the database, and if it finds a match, it updates the system object (instead of replacing the system object, which is what executeMatch
does).
The following runtime components configure executeMatchUpdate.
The Query Builder defines the blocking queries used for matching.
Threshold configuration specifies which blocking query to use and specifies matching parameters, including duplicate and match thresholds.
The pass controller and block picker classes specify how the blocking query is executed.
public MatchResult executeMatchUpdate(SystemObject sysObj)
Name | Description |
---|---|
sysObj | The system object to process into the database. |
A match result object containing the results of the matching process.
ProcessingException
UserException
executeMatchUpdateDupRecalc
is one of four methods that process a system object based on the configuration defined for the Master Index Manager Service and associated runtime components. It is configured by the same components as executeMatch
, and is similar to executeMatchUpdate
but allows you to control whether potential duplicates are recalculated when an object is updated regardless of whether the update mode is set to optimistic or pessimistic.
executeMatchUpdateDupRecalc
differs from executeMatchUpdate
in two ways:
It provides an override flag for the update mode specified in the Threshold configuration file.
The match result object returned by this method includes an indicator of whether match fields were modified. This helps you determine whether you need to process potential duplicates for this object at a later time.
public MatchResult executeMatchUpdateDupRecalc(SystemObject sysObj, java.lang.Boolean performPessimistic)
Note:
To process potential duplicates at a later time, callcalculatePotentialDuplicates
.Name | Description |
---|---|
sysObj | The system object to process into the database. |
performPessimistic | A Boolean indicator of whether to recalculate potential duplicates on update or to defer it until later. Specify true to recalculate on update and false to defer the recalculation. |
A match result object containing the results of the matching process.
ProcessingException
UserException
This method retrieves the Assumed Match threshold.
public float getAssumedMatchThreshold()
This method retrieves the configuration for a master controller parameter, such as the EUID length, duplicate threshold, or match threshold.
public java.lang.Object getConfigurationValue(java.lang.String param)
Name | Description |
---|---|
param | This parameter is defined in the Threshold configuration file of the Master Index Project. |
An object containing the value of the specified parameter.
ProcessingException
UserException
This method retrieves the status of the master index database.
public java.lang.String getDatabaseStatus()
None
The status of the master index database.
ProcessingException
UserException
This method retrieves the potential duplicate threshold.
public float getDuplicateThreshold()
This method returns the enterprise object associated with the specified EUID.
public EnterpriseObject getEnterpriseObject(java.lang.String euid)
Name | Description |
---|---|
euid | The EUID of the enterprise object you want to retrieve. |
options | A list of ePaths that define which types of objects to retrieve to create the resulting EnterpriseObject. |
key | The system object primary key. |
The enterprise object associated with the specified EUID. Returns null if no enterprise object with the specified EUID is found.
ProcessingException
UserException
This method returns the EUID associated with the system code and local ID specified in the SystemObjectPK object.
public java.lang.String getEUID(SystemObjectPK key)
Name | Description |
---|---|
key | The system object key containing the system code and local ID to use as search criteria. |
The EUID associated with the given system object key. Returns null if no results are found.
ProcessingException
UserException
This method returns a map with (fieldName, actual value for link) for the given EO.
public java.util.Map getLinkValues(EnterpriseObject eo)
Name | Description |
---|---|
eo | The EnterpriseObject that has LINKs. |
resultMap map (fieldName, actual value for link) for the given EO.
ObjectException
ConnectionInvalidException
OPSException
ProcessingException
This method retrieves the history of the merge transactions associated with the specified EUID.
public MergeHistoryNode getMergeHistory(java.lang.String euid)
Name | Description |
---|---|
euid | The EUID associated with the merge history to retrieve. |
The merge history tree for the specified EUID.
ProcessingException
UserException
This method retrieves the SBR revision number for the specified EUID.
public java.lang.Integer getRevisionNumber(java.lang.String euid)
Name | Description |
---|---|
euid | The EUID containing the SBR revision number to retrieve. |
The revision number for the SBR.
ProcessingException
This method returns the single best record (SBR) object associated with the specified EUID.
public SBR getSBR(java.lang.String euid)
Name | Description |
---|---|
euid | The EUID of the enterprise object whose SBR you want to retrieve. |
The SBR object associated with the specified EUID. Returns null if no SBR associated with the specified EUID is found.
ProcessingException
UserException
This method returns the system object associated with the system code and local ID contained in the specified SystemObjectPK object.
public SystemObject getSystemObject(SystemObjectPK key)
Name | Description |
---|---|
key | The system object key containing the local ID and system code to lookup. |
The system object associated with the specified local ID and system code.
ProcessingException
UserException
This method inserts an audit log record of a transaction into the database.
public void insertAuditLog(AuditDataObject auditObject)
Name | Description |
---|---|
auditObject | The audit log record to insert. |
None
ProcessingException
UserException
This method returns an iterator of AssumedMatchSummary objects based on the criteria contained in the assumed match search object (AssumedMatchSearchObject class).
public AssumedMatchIterator lookupAssumedMatches(AssumedMatchSearchObject obj)
Name | Description |
---|---|
obj | An instance of AssumedMatchSearchObject containing the potential duplicate search criteria. |
An iterator of search results (AssumedMatchSummary objects).
ProcessingException
UserException
This method looks up an audit log record based on the criteria contained in an audit search object.
public AuditIterator lookupAuditLog(AuditSearchObject obj)
Name | Description |
---|---|
obj | An instance of AuditSearchObject containing the audit log search criteria. |
An iterator of audit log matches to the given search criteria.
ProcessingException
UserException
This method returns an iterator of PotentialDuplicateSummary objects based on the criteria contained in the potential duplicate search object (PotentialDuplicateSearchObject class).
public PotentialDuplicateIterator lookupPotentialDuplicates(PotentialDuplicateSearchObject obj)
Name | Description |
---|---|
obj | An instance of PotentialDuplicateSearchObject containing the potential duplicate search criteria. |
An iterator of search results (PotentialDuplicateSummary objects).
ProcessingException
UserException
This method retrieves the attributes of an external system from the master index database based on the system code.
public SystemDefinition lookupSystemDefinition(java.lang.String systemCode)
Name | Description |
---|---|
systemCode | The system code of an external system. |
A set of system attributes for the system identified the given system code.
ProcessingException
This method retrieves the attributes of an external system from the master index database, such as the system code, masking flags, local ID format and so on.
public SystemDefinition[] lookupSystemDefinitions()
None
An array of system attributes.
ProcessingException
This method returns an array of all system objects associated with the specified EUID.
public SystemObjectPK[] lookupSystemObjectPKs(java.lang.String euid)
Name | Description |
---|---|
euid | The EUID of the enterprise object containing the system objects to retrieve. |
An array of system objects associated with the specified EUID.
ProcessingException
UserException
This method looks up the active system objects associated with the specified EUID.
public SystemObject[] lookupSystemObjects(java.lang.String euid)
Name | Description |
---|---|
euid | The EUID whose associated system objects will be retrieved. |
An array of system objects that are associated with the specified EUID.
ProcessingException
UserException
This method returns a transaction summary for the transaction associated with the specified transaction number.
public TransactionSummary lookupTransaction(java.lang.String transId)
Name | Description |
---|---|
transId | The transaction number for the transaction to look up. |
The transaction summary for the specified transaction ID.
ProcessingException
UserException
This method returns an array of transaction summaries based on the search criteria contained in the specified transaction search object.
public TransactionIterator lookupTransactions(TransactionSearchObject obj)
Name | Description |
---|---|
obj | The transaction search object containing the search criteria. |
An array of transaction summaries matching the given search criteria.
ProcessingException
UserException
This method merges two enterprise objects based on the specified EUID and enterprise object.
public MergeResult mergeEnterpriseObject(java.lang.String sourceEUID, EnterpriseObject destinationEO, boolean calculateOnly)
Name | Description |
---|---|
sourceEUID | The EUID of the enterprise object that will not survive the merge. |
destinationEO | The EUID of the enterprise object that will survive the merge. |
calculateOnly | An indicator of whether to commit changes to the database or to simply compute the merge results. Specify false to commit the changes. |
The results of the merge operation.
ProcessingException
UserException
This method merges multiple enterprise objects based on the specified EUIDs and enterprise object.
public MergeResult[] mergeMultipleEnterpriseObjects(java.lang.String[] sourceEUIDs, EnterpriseObject destinationEO, java.lang.String[] srcRevisionNumbers, java.lang.String destRevisionNumber, boolean calculateOnly)
Name | Description |
---|---|
sourceEUID | The EUID of the enterprise object that will not survive the merge. |
destinationEO | The EUID of the enterprise object that will survive the merge. |
srcRevisionNumbers | The SBR revision number of the non-surviving enterprise object. |
destRevisionNumber | The SBR revision number of the surviving enterprise object. |
calculateOnly | An indicator of whether to commit changes to the database or to simply compute the merge results. Specify false to commit the changes. |
The results of the merge operation.
ProcessingException
UserException
Merges two system objects from the specified system. The system objects may belong to a single enterprise object or to two different enterprise objects.
public MergeResult mergeSystemObject(java.lang.String systemCode, java.lang.String sourceLID, java.lang.String destLID, boolean calculateOnly)
Name | Description |
---|---|
systemCode | The processing code of the system to which the two system objects belong. |
sourceLID | The local ID of the system object that will not survive the merge. |
destLID | The local ID of the system object that will survive the merge. |
calculateOnly | An indicator of whether to commit changes to the database or to simply compute the merge results. Specify false to commit the changes. |
The results of the merge operation.
ProcessingException
UserException
This method previews the undo assumed match.
public EnterpriseObject previewUndoAssumedMatch(java.lang.String assumedMatchId)
Name | Description |
---|---|
assumedMatchId | Id of assumed match to be resolved |
EUID of new EO
ProcessingException
UserException
This method flags a potential duplicate pair with Resolved or Auto Resolved status. If resolved, the pair can be marked as potential duplicates again during a future transaction. If auto-resolved, the pair is permanently flagged as resolved.
public void resolvePotentialDuplicate(java.lang.String id, boolean autoResolve)
Name | Description |
---|---|
id | The potential duplicate ID of the pair to be resolved. |
autoResolve | A Boolean value indicating whether to resolve or auto-resolve the pair. Use true for auto-resolve and false for resolve. |
None
ProcessingException
UserException
This method returns an iterator of enterprise objects that match the specified search criteria and options.
public EOSearchResultIterator searchEnterpriseObject(EOSearchCriteria criteria, EOSearchOptions searchOptions)
Name | Description |
---|---|
criteria | An EOSearchCriteria object containing the search criteria. |
searchOptions | An EOSearchOptions object defining attributes of the search. |
An iterator containing the results of the query.
ProcessingException
UserException
This method transfers a system object from one enterprise record to another enterprise record.
public void transferSystemObject(java.lang.String toEUID, SystemObjectPK systemKey)
Name | Description |
---|---|
toEUID | The EUID of the enterprise object to which the system object will be transferred. |
systemKey | The system code and local ID of the system object to transfer. |
None
ProcessingException
UserException
This method reverses an assumed match transaction, unmerging the two objects that were matched and creating a new enterprise object for the record that caused the assumed match. Potential duplicates are calculated for the new enterprise object.
public java.lang.String undoAssumedMatch(java.lang.String assumedMatchId)
Name | Description |
---|---|
assumedMatchId | The ID of the assumed match transaction to reverse. |
The EUID of the newly created enterprise object resulting from the reversing assumed match.
ProcessingException
UserException
This method unmerges the two enterprise objects that were involved in the most recent merge transaction for the specified EUID. When the calculateOnly is set to true, the unmerge results is calculated, but the changes are not committed to the database.
public MergeResult unmergeEnterpriseObject(java.lang.String euid, boolean calculateOnly)
Name | Description |
---|---|
euid | The EUID of the enterprise object to be unmerged. |
calculateOnly | An indicator of whether to commit the unmerge to the database or to calculate the changes for viewing. Specify true to calculate for viewing and false to commit to the database. |
The result of the unmerge transaction.
ProcessingException
UserException
This method unmerges the two system objects that were involved in the most recent merge transaction for the specified local ID. When the calculateOnly is set to true, the unmerge results is computed, but the changes are not committed to the database.
public MergeResult unmergeSystemObject(java.lang.String systemCode, java.lang.String sourceLID, java.lang.String destLID, boolean calculateOnly)
Name | Description |
---|---|
systemCode | The system code of the system object to be unmerged. |
sourceLID | The local ID of the non-surviving system object. |
destLID | The local ID of the surviving system object. |
calculateOnly | An indicator of whether to commit unmerge to the database or to calculate the changes for viewing. Specify true to calculate for viewing; specify false to commit to the database. |
The result of the unmerge transaction.
ProcessingException
UserException
This method changes the status of a resolved or auto-resolved potential duplicate record pair back to unresolved and places the records back in the potential duplicate listing.
public void unresolvePotentialDuplicate(java.lang.String id)
Name | Description |
---|---|
id | The potential duplicate ID of the records to be unresolved. |
None
ProcessingException
UserException
This method updates the database to reflect the new values of the specified enterprise object. This method is similar to updateEnterpriseObject
but it allows you to control whether potential duplicate recalculation is performed when an enterprise object is updated, regardless of whether the update mode is set to optimistic or pessimistic.
This method differs from updateEnterpriseObject
in two ways:
It provides an override flag for the update mode specified in the Threshold configuration file.
The update result object returned by this method includes an indicator of whether match fields were modified. This helps you determine whether you need to process potential duplicates for this object at a later time.
Note:
To process potential duplicates at a later time, callcalculatePotentialDuplicates
.public UpdateResult updateEnterpriseDupRecalc(EnterpriseObject eo, java.lang.Boolean performPessimistic)
Name | Description |
---|---|
eo | The enterprise object (EnterpriseObject class) to be updated. |
performPessimistic | A Boolean indicator of whether to defer potential duplicate processing. Specify true to recalculate potential duplicates on update and false to defer recalculation to a later time. |
The UpdateResult object created from the update.
ProcessingException
UserException
This method updates the database to reflect the new values of the specified enterprise object. If the enterprise object is deactivated during the update, potential duplicates are deleted for that object. If the enterprise object is still active, was changed during the transaction, and the update mode is set to pessimistic, the application checks whether any key fields were updated in the SBR of the enterprise object. If key fields were updated, potential duplicates are recalculated.
public void updateEnterpriseObject(EnterpriseObject eo)
Name | Description |
---|---|
eo | The enterprise object (EnterpriseObject class) to be updated. |
None
ProcessingException
UserException
This method updates SBR by collecting the values from MAP to the SBR that specified by EUID.
public EnterpriseObject updateSBR(java.util.Map mapSystems, EnterpriseObject eo, boolean removalFlag)
Name | Description |
---|---|
mapSystems | The Map consists of epath as key and System as value from which the filed should take for updating SBR. |
None
ProcessingException
UserException