mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-07-12 13:29:04 +00:00
Parser factory chooses parser class based on filepath 🟩
This commit is contained in:
parent
c073a4cb43
commit
4d36fce83d
1 changed files with 5 additions and 1 deletions
|
|
@ -1,4 +1,8 @@
|
||||||
from backend.condition.parsing.parser import Parser
|
from backend.condition.parsing.parser import Parser
|
||||||
|
from backend.condition.parsing.lbwf_parser import LbwfParser
|
||||||
|
|
||||||
def select_parser(filepath: str) -> Parser:
|
def select_parser(filepath: str) -> Parser:
|
||||||
raise NotImplementedError
|
path = filepath.lower()
|
||||||
|
|
||||||
|
if "lbwf" in path:
|
||||||
|
return LbwfParser()
|
||||||
Loading…
Add table
Reference in a new issue