Interface DuplicateManagementInterface
- All Known Implementing Classes:
StewardshipAction
public interface DuplicateManagementInterface
DuplicateManagementInterface defines the operations to manage the linking of elements that are duplicates of one another.
-
Method Summary
Modifier and TypeMethodDescriptiongetConsolidatedDuplicate
(String userId, String elementGUID) Return details of the consolidated duplicate for a requested element.getContributingDuplicates
(String userId, String consolidatedDuplicateGUID, int startFrom, int pageSize) List the elements that are contributing to a consolidating duplicate element.getPeerDuplicates
(String userId, String elementGUID, int startFrom, int pageSize) List the elements that are linked as peer duplicates to the requested element.void
linkElementsAsDuplicates
(String userId, String element1GUID, String element2GUID, int statusIdentifier, String steward, String stewardTypeName, String stewardPropertyName, String source, String notes) Create a simple relationship between two elements.void
linkElementToConsolidatedDuplicate
(String userId, String consolidatedDuplicateGUID, String contributingElementGUID) Create a ConsolidatedDuplicateLink relationship between the consolidated duplicate element and one of its contributing element.void
markAsConsolidatedDuplicate
(String userId, String consolidatedDuplicateGUID, int statusIdentifier, String steward, String stewardTypeName, String stewardPropertyName, String source, String notes) Mark an element as a consolidated duplicate (or update the properties if it is already marked as such).void
markElementAsKnownDuplicate
(String userId, String elementGUID) Classify an element as a known duplicate.void
removeConsolidatedDuplicate
(String userId, String consolidatedDuplicateGUID) Remove the consolidated duplicate element and the links to the elements that contributed to its values.void
unlinkElementFromConsolidatedDuplicate
(String userId, String consolidatedDuplicateGUID, String contributingElementGUID) Remove the relationship between two elements that marks them as duplicates.void
unlinkElementsAsDuplicates
(String userId, String element1GUID, String element2GUID) Remove the relationship between two elements that marks them as duplicates.void
unmarkElementAsKnownDuplicate
(String userId, String elementGUID) Remove the classification that identifies this element as a known duplicate.
-
Method Details
-
linkElementsAsDuplicates
void linkElementsAsDuplicates(String userId, String element1GUID, String element2GUID, int statusIdentifier, String steward, String stewardTypeName, String stewardPropertyName, String source, String notes) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Create a simple relationship between two elements. These elements must be of the same type. If the relationship already exists, the properties are updated.- Parameters:
userId
- calling userelement1GUID
- unique identifier of first elementelement2GUID
- unique identifier of second elementstatusIdentifier
- what is the status of this relationship (negative means untrusted, 0 means unverified and positive means trusted)steward
- identifier of the stewardstewardTypeName
- type of element used to identify the stewardstewardPropertyName
- property name used to identify stewardsource
- source of the duplicate detection processingnotes
- notes for the steward- Throws:
InvalidParameterException
- one of the parameters is null or invalid, or the elements are of different typesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
unlinkElementsAsDuplicates
void unlinkElementsAsDuplicates(String userId, String element1GUID, String element2GUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Remove the relationship between two elements that marks them as duplicates.- Parameters:
userId
- calling userelement1GUID
- unique identifier of first elementelement2GUID
- unique identifier of second element- Throws:
InvalidParameterException
- one of the parameters is null or invalid or the elements are not linked as duplicatesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
markElementAsKnownDuplicate
void markElementAsKnownDuplicate(String userId, String elementGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Classify an element as a known duplicate. This will mean that it is included in duplicate processing during metadata retrieval requests.- Parameters:
userId
- calling userelementGUID
- unique identifier of the element- Throws:
InvalidParameterException
- one of the parameters is null or invalid, or the elements are of different typesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
unmarkElementAsKnownDuplicate
void unmarkElementAsKnownDuplicate(String userId, String elementGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Remove the classification that identifies this element as a known duplicate.- Parameters:
userId
- calling userelementGUID
- unique identifier of the element- Throws:
InvalidParameterException
- one of the parameters is null or invalid or the elements are not linked as duplicatesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getPeerDuplicates
List<DuplicateElement> getPeerDuplicates(String userId, String elementGUID, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException List the elements that are linked as peer duplicates to the requested element.- Parameters:
userId
- calling userelementGUID
- element to querystartFrom
- paging start pointpageSize
- maximum results that can be returned- Returns:
- list of linked duplicates
- Throws:
InvalidParameterException
- one of the parameters is null or invalidPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
markAsConsolidatedDuplicate
void markAsConsolidatedDuplicate(String userId, String consolidatedDuplicateGUID, int statusIdentifier, String steward, String stewardTypeName, String stewardPropertyName, String source, String notes) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Mark an element as a consolidated duplicate (or update the properties if it is already marked as such). This method assumes that a standard create method has been used to create the element first using the values from contributing elements. It is just adding the ConsolidatedDuplicate classification to the element.- Parameters:
userId
- calling userconsolidatedDuplicateGUID
- unique identifier of the element that contains the consolidated information from a collection of elements that are all duplicates of one another.statusIdentifier
- what is the status of this relationship (negative means untrusted, 0 means unverified and positive means trusted)steward
- identifier of the stewardstewardTypeName
- type of element used to identify the stewardstewardPropertyName
- property name used to identify stewardsource
- source of the duplicate detection processingnotes
- notes for the steward- Throws:
InvalidParameterException
- one of the parameters is null or invalidPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
linkElementToConsolidatedDuplicate
void linkElementToConsolidatedDuplicate(String userId, String consolidatedDuplicateGUID, String contributingElementGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Create a ConsolidatedDuplicateLink relationship between the consolidated duplicate element and one of its contributing element.- Parameters:
userId
- calling userconsolidatedDuplicateGUID
- unique identifier of consolidated duplicatecontributingElementGUID
- unique identifier of duplicate element- Throws:
InvalidParameterException
- one of the parameters is null or invalid or the elements are not linked as duplicatesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
unlinkElementFromConsolidatedDuplicate
void unlinkElementFromConsolidatedDuplicate(String userId, String consolidatedDuplicateGUID, String contributingElementGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Remove the relationship between two elements that marks them as duplicates.- Parameters:
userId
- calling userconsolidatedDuplicateGUID
- unique identifier of consolidated duplicatecontributingElementGUID
- unique identifier of duplicate element- Throws:
InvalidParameterException
- one of the parameters is null or invalid or the elements are not linked as duplicatesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getContributingDuplicates
List<ElementStub> getContributingDuplicates(String userId, String consolidatedDuplicateGUID, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException List the elements that are contributing to a consolidating duplicate element.- Parameters:
userId
- calling userconsolidatedDuplicateGUID
- element to querystartFrom
- paging start pointpageSize
- maximum results that can be returned- Returns:
- list of contributing duplicates
- Throws:
InvalidParameterException
- one of the parameters is null or invalid or the elements are not linked as duplicatesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getConsolidatedDuplicate
ElementStub getConsolidatedDuplicate(String userId, String elementGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Return details of the consolidated duplicate for a requested element.- Parameters:
userId
- calling userelementGUID
- element to query- Returns:
- header of consolidated duplicated or null if none
- Throws:
InvalidParameterException
- one of the parameters is null or invalid or the elements are not linked as duplicatesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
removeConsolidatedDuplicate
void removeConsolidatedDuplicate(String userId, String consolidatedDuplicateGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Remove the consolidated duplicate element and the links to the elements that contributed to its values.- Parameters:
userId
- calling userconsolidatedDuplicateGUID
- unique identifier of element to remove- Throws:
InvalidParameterException
- one of the parameters is null or invalid or the elements are not linked as duplicatesPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-