[docs]classFile:""" Base class for all files in a package. :param str path: The path to the file. """def__init__(self,path:str):self.path=pathdef__str__(self):returnf"<{self.__class__.__name__}{self.path}>"
[docs]defread(self)->str:""" Read the file content. :return: The content of the file. """raiseNotImplementedError()
[docs]defwrite(self,text:str):""" Write to the file. :param str text: The text to write. """raiseNotImplementedError()