Revert "fix(IPsecUtil): Delete keywords no longer used"
[csit.git] / resources / libraries / python / topology.py
index 7e53a4b..22ed366 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (c) 2022 Cisco and/or its affiliates.
+# Copyright (c) 2024 Cisco and/or its affiliates.
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
 # You may obtain a copy of the License at:
@@ -1087,6 +1087,19 @@ class Topology:
         except KeyError:
             return None
 
+    def get_bus(node):
+        """Return bus configuration of the node.
+
+        :param node: Node created from topology.
+        :type node: dict
+        :returns: bus configuration string.
+        :rtype: str
+        """
+        try:
+            return node[u"bus"]
+        except KeyError:
+            return None
+
     @staticmethod
     def get_uio_driver(node):
         """Return uio-driver configuration of the node.