def all_control_flow_elements_count(bpmn_graph):
gateway_counts = get_gateway_counts(bpmn_graph)<EOL>events_counts = get_events_counts(bpmn_graph)<EOL>control_flow_elements_counts = gateway_counts.copy()<EOL>control_flow_elements_counts.update(events_counts)<EOL>return sum([<EOL>count for name, count in control_flow_elements_counts.items()<EOL>])<EOL>
Returns the total count of all control flow elements
in the BPMNDiagramGraph instance.


:param bpmn_graph: an instance of BpmnDiagramGraph representing BPMN model.
:return: total count of the control flow elements in the BPMNDiagramGraph instance