Class IsARelationshipMapper
- java.lang.Object
-
- org.odpi.openmetadata.accessservices.subjectarea.server.mappers.relationships.RelationshipMapper<IsA>
-
- org.odpi.openmetadata.accessservices.subjectarea.server.mappers.relationships.IsARelationshipMapper
-
- All Implemented Interfaces:
IRelationshipMapper<IsA>,Mapper<Relationship,IsA>
public class IsARelationshipMapper extends RelationshipMapper<IsA>
Mapping methods to map between the iSARelationship and the equivalent omrs Relationship.
-
-
Field Summary
Fields Modifier and Type Field Description static StringISA_RELATIONSHIP-
Fields inherited from class org.odpi.openmetadata.accessservices.subjectarea.server.mappers.relationships.RelationshipMapper
genericHandler, repositoryHelper
-
-
Constructor Summary
Constructors Constructor Description IsARelationshipMapper(OpenMetadataAPIGenericHandler genericHandler)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected IsAgetRelationshipInstance()StringgetTypeName()get type nameprotected booleanmapEnumToRelationship(IsA iSARelationship, String propertyName, EnumPropertyValue enumPropertyValue)Map an omrs enum property to a Subject Area relationship property.protected booleanmapPrimitiveToRelationship(IsA iSARelationship, String propertyName, Object value)Map a primitive omrs property to the iSARelationship object.protected voidmapRelationshipToInstanceProperties(IsA iSARelationship, InstanceProperties instanceProperties)Map the supplied relationship to omrs InstanceProperties.-
Methods inherited from class org.odpi.openmetadata.accessservices.subjectarea.server.mappers.relationships.RelationshipMapper
getTypeDefGuid, map, map, mapInstancePropertiesToRelationship, mapMapToRelationship
-
-
-
-
Field Detail
-
ISA_RELATIONSHIP
public static final String ISA_RELATIONSHIP
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
IsARelationshipMapper
public IsARelationshipMapper(OpenMetadataAPIGenericHandler genericHandler)
-
-
Method Detail
-
mapRelationshipToInstanceProperties
protected void mapRelationshipToInstanceProperties(IsA iSARelationship, InstanceProperties instanceProperties)
Map the supplied relationship to omrs InstanceProperties.- Overrides:
mapRelationshipToInstancePropertiesin classRelationshipMapper<IsA>- Parameters:
iSARelationship- supplied relationshipinstanceProperties- equivalent instance properties to the relationship
-
mapPrimitiveToRelationship
protected boolean mapPrimitiveToRelationship(IsA iSARelationship, String propertyName, Object value)
Map a primitive omrs property to the iSARelationship object.- Overrides:
mapPrimitiveToRelationshipin classRelationshipMapper<IsA>- Parameters:
iSARelationship- the omas relationship to be updatedpropertyName- the omrs property namevalue- the omrs primitive property value- Returns:
- true if the propertyName was recognised and mapped to the relationship, otherwise false
-
mapEnumToRelationship
protected boolean mapEnumToRelationship(IsA iSARelationship, String propertyName, EnumPropertyValue enumPropertyValue)
Description copied from class:RelationshipMapperMap an omrs enum property to a Subject Area relationship property. The child class is expected to override this method if the type has enum properties- Overrides:
mapEnumToRelationshipin classRelationshipMapper<IsA>- Parameters:
iSARelationship- the relationship to be updatedpropertyName- the omrs property nameenumPropertyValue- the omrs enum property value- Returns:
- true if it was a property we were expecting , otherwise false;
-
getTypeName
public String getTypeName()
Description copied from class:RelationshipMapperget type name- Specified by:
getTypeNamein interfaceMapper<Relationship,IsA>- Specified by:
getTypeNamein classRelationshipMapper<IsA>- Returns:
- the omrs type name.
-
getRelationshipInstance
protected IsA getRelationshipInstance()
-
-