1
0
Fork 0

AbstractParser is an abstract class

This commit is contained in:
jvoisin 2018-04-01 12:06:50 +02:00
parent da5cef8c90
commit 711347c87f
1 changed files with 7 additions and 3 deletions

View File

@ -1,4 +1,6 @@
class AbstractParser(object):
import abc
class AbstractParser(abc.ABC):
meta_list = set()
mimetypes = set()
@ -6,8 +8,10 @@ class AbstractParser(object):
self.filename = filename
self.output_filename = filename + '.cleaned'
@abc.abstractmethod
def get_meta(self) -> dict:
raise NotImplementedError
pass
@abc.abstractmethod
def remove_all(self) -> bool:
raise NotImplementedError
pass