public abstract class ClassificationMapping extends Object
| Constructor and Description |
|---|
ClassificationMapping(String igcAssetType,
String igcRelationshipProperty,
String omrsClassificationType) |
| Modifier and Type | Method and Description |
|---|---|
abstract EntityDetail |
addClassificationToIGCAsset(IGCOMRSRepositoryConnector igcomrsRepositoryConnector,
Reference igcAsset,
String entityGUID,
InstanceProperties initialProperties,
String userId)
Implement this method to define how to add an OMRS classification to an existing IGC asset.
|
void |
addExcludedIgcAssetType(String igcAssetType)
When the asset this applies to is a 'main_object', use this method to add any objects that should NOT be
included under that umbrella.
|
void |
addIgcRelationshipProperty(String property)
Add the provided property as one of the IGC properties needed to setup this classification.
|
abstract void |
addMappedOMRSClassifications(IGCOMRSRepositoryConnector igcomrsRepositoryConnector,
List<Classification> classifications,
Reference fromIgcObject,
String userId)
Implement this method to actually define the logic for the classification.
|
void |
addMappedOmrsProperty(String name)
Add the provided property name as one supported by this classification mapping.
|
void |
addSupportedStatus(InstanceStatus status)
Add the provided status as one supported by this classification mapping.
|
String |
getIgcAssetType()
Retrieve the IGC asset type to which this classification mapping applies.
|
List<String> |
getIgcRelationshipProperties()
Retrieve the list of IGC properties used to apply this classification mapping.
|
abstract IGCSearchConditionSet |
getIGCSearchCriteria(InstanceProperties matchClassificationProperties)
Implement this method to define how IGC assets can be searched based on this classification.
|
protected static Classification |
getMappedClassification(IGCOMRSRepositoryConnector igcomrsRepositoryConnector,
String omrsClassificationType,
String omrsEntityType,
InstanceProperties classificationProperties,
Reference fromIgcObject,
String userId)
Retrieve a Classification instance based on the provided information.
|
Set<String> |
getMappedOmrsPropertyNames()
Retrieve the set of OMRS properties that are supported by the classification mapping.
|
String |
getOmrsClassificationType()
Retrieve the name of the OMRS ClassificationDef represented by this mapping.
|
List<InstanceStatus> |
getSupportedStatuses()
Retrieve the list of statuses that are supported by the classification mapping.
|
boolean |
matchesAssetType(String igcAssetType)
Indicates whether this classification mapping matches the provided IGC asset type: that is, this mapping
can be used to translate to the provided IGC asset type.
|
public void addSupportedStatus(InstanceStatus status)
status - a status that is supported by the mappingpublic List<InstanceStatus> getSupportedStatuses()
List<InstanceStatus>public void addMappedOmrsProperty(String name)
name - the name of the OMRS property supported by the mappingpublic Set<String> getMappedOmrsPropertyNames()
Set<String>public String getIgcAssetType()
public List<String> getIgcRelationshipProperties()
List<String>public String getOmrsClassificationType()
public void addExcludedIgcAssetType(String igcAssetType)
igcAssetType - the IGC asset type to exclude from 'main_object' considerationpublic void addIgcRelationshipProperty(String property)
property - the IGC asset's property namepublic abstract void addMappedOMRSClassifications(IGCOMRSRepositoryConnector igcomrsRepositoryConnector, List<Classification> classifications, Reference fromIgcObject, String userId)
igcomrsRepositoryConnector - connectivity to the IGC repository via OMRS connectorclassifications - the list of classifications to which new classifications should be addedfromIgcObject - the IGC object from which to determine the classificationsuserId - the user requesting the classifications (currently unused)public abstract IGCSearchConditionSet getIGCSearchCriteria(InstanceProperties matchClassificationProperties)
matchClassificationProperties - the criteria to use when searching for the classificationpublic abstract EntityDetail addClassificationToIGCAsset(IGCOMRSRepositoryConnector igcomrsRepositoryConnector, Reference igcAsset, String entityGUID, InstanceProperties initialProperties, String userId) throws RepositoryErrorException, EntityNotKnownException
igcomrsRepositoryConnector - connectivity to the IGC repository via OMRS connectorigcAsset - the IGC object to which to add the OMRS classificationentityGUID - the GUID of the OMRS entity (ie. including any prefix)initialProperties - the set of classification-specific properties to add to the classificationuserId - the user requesting the classification to be added (currently unused)RepositoryErrorExceptionEntityNotKnownExceptionpublic boolean matchesAssetType(String igcAssetType)
igcAssetType - the IGC asset type to check the mapping againstprotected static Classification getMappedClassification(IGCOMRSRepositoryConnector igcomrsRepositoryConnector, String omrsClassificationType, String omrsEntityType, InstanceProperties classificationProperties, Reference fromIgcObject, String userId) throws RepositoryErrorException
omrsClassificationType - the type name of the OMRS classificationomrsEntityType - the OMRS type of entity the OMRS classification is being linked againstclassificationProperties - the properties to setup on the classificationRepositoryErrorExceptionCopyright © 2018–2019 ODPi. All rights reserved.