Class AtlasRelationshipDef
As with other typeDefs the AtlasRelationshipDef has a name. Once created the RelationshipDef has a guid. The name and the guid are the 2 ways that the RelationshipDef is identified.
RelationshipDefs have 2 ends, each of which specify cardinality, an EntityDef type name and name and optionally whether the end is a container.
RelationshipDefs can have AttributeDefs - though only primitive types are allowed.
RelationshipDefs have an AtlasRelationshipCategory specifying the UML type of relationship required
RelationshipDefs also have an AtlasPropagateTag - indicating which way tags could flow over the relationships.
The way EntityDefs and RelationshipDefs are intended to be used is that EntityDefs will define AttributeDefs these AttributeDefs will not specify an EntityDef type name as their types.
RelationshipDefs introduce new attributes to the entity instances. For example
EntityDef A might have attributes attr1,attr2,attr3
EntityDef B might have attributes attr4,attr5,attr6
RelationshipDef AtoB might define 2 ends
end1: type A, name attr7 end2: type B, name attr8
When an instance of EntityDef A is created, it will have attributes attr1,attr2,attr3,attr7
When an instance of EntityDef B is created, it will have attributes attr4,attr5,attr6,attr8
In this way relationshipDefs can be authored separately from entityDefs and can inject relationship attributes into the entity instances.
-
Field Summary
Fields inherited from class org.odpi.openmetadata.adapters.connectors.apacheatlas.resource.properties.AtlasTypeDefBase
ATLAS_BUILTIN_TYPES, ATLAS_PRIMITIVE_TYPES, ATLAS_RELATIONSHIP_ATTRIBUTE_TYPES, ATLAS_TYPE_ARRAY_PREFIX, ATLAS_TYPE_ARRAY_SUFFIX, ATLAS_TYPE_ASSET, ATLAS_TYPE_BIGDECIMAL, ATLAS_TYPE_BIGINTEGER, ATLAS_TYPE_BOOLEAN, ATLAS_TYPE_BYTE, ATLAS_TYPE_DATASET, ATLAS_TYPE_DATE, ATLAS_TYPE_DOUBLE, ATLAS_TYPE_FLOAT, ATLAS_TYPE_INFRASTRUCTURE, ATLAS_TYPE_INT, ATLAS_TYPE_LONG, ATLAS_TYPE_MAP_KEY_VAL_SEP, ATLAS_TYPE_MAP_PREFIX, ATLAS_TYPE_MAP_SUFFIX, ATLAS_TYPE_OBJECT_ID, ATLAS_TYPE_PROCESS, ATLAS_TYPE_SHORT, ATLAS_TYPE_STRING, TYPEDEF_OPTION_SUPPORTS_PROFILE, TYPEDEF_OPTION_SUPPORTS_SCHEMA
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
setEndDef1
(AtlasRelationshipEndDef endDef1) void
setEndDef2
(AtlasRelationshipEndDef endDef2) void
setPropagateTags
(AtlasPropagateTags propagateTags) void
setRelationshipCategory
(AtlasRelationshipCategory relationshipCategory) void
setRelationshipLabel
(String relationshipLabel) toString()
Methods inherited from class org.odpi.openmetadata.adapters.connectors.apacheatlas.resource.properties.AtlasStructDef
getAttributeDefs, setAttributeDefs
Methods inherited from class org.odpi.openmetadata.adapters.connectors.apacheatlas.resource.properties.AtlasTypeDefBase
getCategory, getCreatedBy, getCreateTime, getDescription, getGuid, getName, getServiceType, getTypeVersion, getUpdateBy, getUpdateTime, getVersion, setCategory, setCreatedBy, setCreateTime, setDescription, setGuid, setName, setServiceType, setTypeVersion, setUpdateBy, setUpdateTime, setVersion
-
Constructor Details
-
AtlasRelationshipDef
public AtlasRelationshipDef()
-
-
Method Details
-
getRelationshipCategory
-
setRelationshipCategory
-
getRelationshipLabel
-
setRelationshipLabel
-
getPropagateTags
-
setPropagateTags
-
getEndDef1
-
setEndDef1
-
getEndDef2
-
setEndDef2
-
toString
- Overrides:
toString
in classAtlasStructDef
-