+
+ @staticmethod
+ def vpp_get_bridge_domain_data(node, bd_id=None):
+ """Get all bridge domain data from a VPP node. If a domain ID number is
+ provided, return only data for the matching bridge domain.
+
+ :param node: VPP node to get bridge domain data from.
+ :param bd_id: Numeric ID of a specific bridge domain.
+ :type node: dict
+ :type bd_id: int
+ :return: List of dictionaries containing data for each bridge domain, or
+ a single dictionary for the specified bridge domain.
+ :rtype: list or dict
+ """
+ with VatTerminal(node) as vat:
+ response = vat.vat_terminal_exec_cmd_from_template("l2_bd_dump.vat")
+
+ data = response[0]
+
+ if bd_id is not None:
+ for bridge_domain in data:
+ if bridge_domain["bd_id"] == bd_id:
+
+ return bridge_domain
+
+ return data