habitmove/src/habitmove/parser.py

26 lines
673 B
Python
Raw Normal View History

2021-12-16 12:11:49 +00:00
from __future__ import annotations
from habitmove.nomiedata import Event, ImportData, Tracker
class Parser:
2021-12-16 12:11:49 +00:00
def parse(self, path: str, filename: str) -> ImportData:
"""Load in a data set"""
2021-12-16 12:11:49 +00:00
raise NotImplementedError
def extract_version(self) -> str:
"""Extract import dataset version from the data set"""
raise NotImplementedError
def extract_trackers(self) -> list[Tracker]:
"""Extract trackers from the data set"""
raise NotImplementedError
def extract_events(self) -> list[Event]:
"""Extract events from the data set"""
raise NotImplementedError
2021-12-16 12:11:49 +00:00
class NomieParser(Parser):
pass