private fun MutableMap<RelationshipGroupKey, MutableSet<Relationship>>.addAggregationEntry(nodeDefinition: NodeDefinition, relationshipDefinition: RelationshipDefinition, node: Node, relatedNodes: Collection<Node>, nodeIdLookup: Map<Node, String>)

Groups all relatedNodes by their RelationshipGroupKey and adds them to the MutableMap

Parameters

nodeDefinition

the NodeDefinition of the node

relationshipDefinition

the RelationshipDefinition of the relationship of node to all nodes in relatedNodes

node

the start node of the relationships

relatedNodes

the end nodes of the relationships

nodeIdLookup

a map from Node to their id for saved nodes