def import_flow_di(diagram_graph, sequence_flows, message_flows, flow_element):
        """
        Adds Diagram Interchange information (information about rendering a diagram) to appropriate
        BPMN sequence flow represented as graph edge.
        We assume that each BPMNEdge has a list of 'waypoint' elements. BPMN 2.0 XML Schema states,
        that each BPMNEdge must have at least two waypoints.

        :param diagram_graph: NetworkX graph representing a BPMN process diagram,
        :param sequence_flows: dictionary (associative list) of sequence flows existing in diagram.
            Key attribute is sequenceFlow ID, value is a dictionary consisting three key-value pairs: "name" (sequence
            flow name), "sourceRef" (ID of node, that is a flow source) and "targetRef" (ID of node, that is a flow target),
        :param message_flows: dictionary (associative list) of message flows existing in diagram.
            Key attribute is messageFlow ID, value is a dictionary consisting three key-value pairs: "name" (message
            flow name), "sourceRef" (ID of node, that is a flow source) and "targetRef" (ID of node, that is a flow target),
        :param flow_element: object representing a BPMN XML 'BPMNEdge' element.
        """
        flow_id = flow_element.getAttribute(consts.Consts.bpmn_element)
        waypoints_xml = flow_element.getElementsByTagNameNS("*", consts.Consts.waypoint)
        length = len(waypoints_xml)

        waypoints = [None] * length
        for index in range(length):
            waypoint_tmp = (waypoints_xml[index].getAttribute(consts.Consts.x),
                            waypoints_xml[index].getAttribute(consts.Consts.y))
            waypoints[index] = waypoint_tmp

        flow_data = None
        if flow_id in sequence_flows:
            flow_data = sequence_flows[flow_id]
        elif flow_id in message_flows:
            flow_data = message_flows[flow_id]

        if flow_data is not None:
            name = flow_data[consts.Consts.name]
            source_ref = flow_data[consts.Consts.source_ref]
            target_ref = flow_data[consts.Consts.target_ref]
            diagram_graph[source_ref][target_ref][consts.Consts.waypoints] = waypoints
            diagram_graph[source_ref][target_ref][consts.Consts.name] = name
Adds Diagram Interchange information (information about rendering a diagram) to appropriate
        BPMN sequence flow represented as graph edge.
        We assume that each BPMNEdge has a list of 'waypoint' elements. BPMN 2.0 XML Schema states,
        that each BPMNEdge must have at least two waypoints.

        :param diagram_graph: NetworkX graph representing a BPMN process diagram,
        :param sequence_flows: dictionary (associative list) of sequence flows existing in diagram.
            Key attribute is sequenceFlow ID, value is a dictionary consisting three key-value pairs: "name" (sequence
            flow name), "sourceRef" (ID of node, that is a flow source) and "targetRef" (ID of node, that is a flow target),
        :param message_flows: dictionary (associative list) of message flows existing in diagram.
            Key attribute is messageFlow ID, value is a dictionary consisting three key-value pairs: "name" (message
            flow name), "sourceRef" (ID of node, that is a flow source) and "targetRef" (ID of node, that is a flow target),
        :param flow_element: object representing a BPMN XML 'BPMNEdge' element.