def export_node_data(bpmn_diagram, process_id, params, process):
        """
        Creates a new XML element (depends on node type) for given node parameters and adds it to 'process' element.

        :param bpmn_diagram: BPMNDiagramGraph class instantion representing a BPMN process diagram,
        :param process_id: string representing ID of given flow node,
        :param params: dictionary with node parameters,
        :param process: object of Element class, representing BPMN XML 'process' element (root for nodes).
        """
        node_type = params[consts.Consts.type]
        output_element = eTree.SubElement(process, node_type)
        output_element.set(consts.Consts.id, process_id)
        output_element.set(consts.Consts.name, params[consts.Consts.node_name])

        for incoming in params[consts.Consts.incoming_flow]:
            incoming_element = eTree.SubElement(output_element, consts.Consts.incoming_flow)
            incoming_element.text = incoming
        for outgoing in params[consts.Consts.outgoing_flow]:
            outgoing_element = eTree.SubElement(output_element, consts.Consts.outgoing_flow)
            outgoing_element.text = outgoing

        if node_type == consts.Consts.task \
                or node_type == consts.Consts.user_task \
                or node_type == consts.Consts.service_task \
                or node_type == consts.Consts.manual_task:
            BpmnDiagramGraphExport.export_task_info(params, output_element)
        elif node_type == consts.Consts.subprocess:
            BpmnDiagramGraphExport.export_subprocess_info(bpmn_diagram, params, output_element)
        elif node_type == consts.Consts.data_object:
            BpmnDiagramGraphExport.export_data_object_info(bpmn_diagram, params, output_element)
        elif node_type == consts.Consts.complex_gateway:
            BpmnDiagramGraphExport.export_complex_gateway_info(params, output_element)
        elif node_type == consts.Consts.event_based_gateway:
            BpmnDiagramGraphExport.export_event_based_gateway_info(params, output_element)
        elif node_type == consts.Consts.inclusive_gateway or node_type == consts.Consts.exclusive_gateway:
            BpmnDiagramGraphExport.export_inclusive_exclusive_gateway_info(params, output_element)
        elif node_type == consts.Consts.parallel_gateway:
            BpmnDiagramGraphExport.export_parallel_gateway_info(params, output_element)
        elif node_type == consts.Consts.start_event:
            BpmnDiagramGraphExport.export_start_event_info(params, output_element)
        elif node_type == consts.Consts.intermediate_catch_event:
            BpmnDiagramGraphExport.export_catch_event_info(params, output_element)
        elif node_type == consts.Consts.end_event or node_type == consts.Consts.intermediate_throw_event:
            BpmnDiagramGraphExport.export_throw_event_info(params, output_element)
        elif node_type == consts.Consts.boundary_event:
            BpmnDiagramGraphExport.export_boundary_event_info(params, output_element)
Creates a new XML element (depends on node type) for given node parameters and adds it to 'process' element.

        :param bpmn_diagram: BPMNDiagramGraph class instantion representing a BPMN process diagram,
        :param process_id: string representing ID of given flow node,
        :param params: dictionary with node parameters,
        :param process: object of Element class, representing BPMN XML 'process' element (root for nodes).