diff --git a/pythonbpf/maps.py b/pythonbpf/maps.py index 585d9c8..9926826 100644 --- a/pythonbpf/maps.py +++ b/pythonbpf/maps.py @@ -5,4 +5,10 @@ class HashMap: self.max_entries = max_entries self.entries = {} + def lookup(self, key): + if key in self.entries: + return self.entries[key] + else: + return None + # add other supported map functions here