Unverified Commit e4a05183 authored by Robin Mueller's avatar Robin Mueller
Browse files

matching 3 digits subsystem ids now

parent b2f7cb79
......@@ -21,14 +21,14 @@ class SubsystemDefinitionParser(FileParser):
def _handle_file_parsing(self, file_name: str, *args, **kwargs):
file = open(file_name, "r")
for line in file.readlines():
match = re.search(r'([A-Z0-9_]*) = ([0-9]{1,2})', line)
match = re.search(r'([A-Z0-9_]*) = ([0-9]{1,3})', line)
if match:
self.mib_table.update({match.group(1): [match.group(2)]})
def _handle_file_parsing_moving_window(
self, file_name: str, current_line: int, moving_window_size: int, moving_window: list,
*args, **kwargs):
match = re.search(r'([A-Z0-9_]*) = ([0-9]{1,2})', moving_window[self.moving_window_center_idx])
match = re.search(r'([A-Z0-9_]*) = ([0-9]{1,3})', moving_window[self.moving_window_center_idx])
if match:
self.mib_table.update({match.group(1): [match.group(2)]})
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment