@@ -277,50 +277,50 @@ class OMCPath(pathlib.PurePath, metaclass=abc.ABCMeta):
277277 def __init__ (self , * path ):
278278 super ().__init__ (* path )
279279
280- # functions from pathlib.Path
281- @abc .abstractmethod
282- def with_segments (self , * pathsegments ):
283- raise NotImplementedError
284-
285- @abc .abstractmethod
286- def is_file (self , * , follow_symlinks = True ):
287- raise NotImplementedError
288-
289- @abc .abstractmethod
290- def is_dir (self , * , follow_symlinks = True ):
291- raise NotImplementedError
292-
293- @abc .abstractmethod
294- def read_text (self , encoding = None , errors = None , newline = None ):
295- raise NotImplementedError
296-
297- @abc .abstractmethod
298- def write_text (self , data : str , encoding = None , errors = None , newline = None ):
299- raise NotImplementedError
300-
301- @abc .abstractmethod
302- def mkdir (self , mode = 0o777 , parents = False , exist_ok = False ):
303- raise NotImplementedError
304-
305- @abc .abstractmethod
306- def cwd (self ):
307- raise NotImplementedError
308-
309- @abc .abstractmethod
310- def unlink (self , missing_ok : bool = False ):
311- raise NotImplementedError
312-
313- @abc .abstractmethod
314- def resolve (self , strict : bool = False ):
315- raise NotImplementedError
316-
317- @abc .abstractmethod
318- def absolute (self ):
319- raise NotImplementedError
320-
321- @abc .abstractmethod
322- def exists (self , * , follow_symlinks = True ):
323- raise NotImplementedError
280+ # # functions from pathlib.Path
281+ # @abc.abstractmethod
282+ # def with_segments(self, *pathsegments):
283+ # raise NotImplementedError
284+ #
285+ # @abc.abstractmethod
286+ # def is_file(self, *, follow_symlinks=True):
287+ # raise NotImplementedError
288+ #
289+ # @abc.abstractmethod
290+ # def is_dir(self, *, follow_symlinks=True):
291+ # raise NotImplementedError
292+ #
293+ # @abc.abstractmethod
294+ # def read_text(self, encoding=None, errors=None, newline=None):
295+ # raise NotImplementedError
296+ #
297+ # @abc.abstractmethod
298+ # def write_text(self, data: str, encoding=None, errors=None, newline=None):
299+ # raise NotImplementedError
300+ #
301+ # @abc.abstractmethod
302+ # def mkdir(self, mode=0o777, parents=False, exist_ok=False):
303+ # raise NotImplementedError
304+ #
305+ # @abc.abstractmethod
306+ # def cwd(self):
307+ # raise NotImplementedError
308+ #
309+ # @abc.abstractmethod
310+ # def unlink(self, missing_ok: bool = False):
311+ # raise NotImplementedError
312+ #
313+ # @abc.abstractmethod
314+ # def resolve(self, strict: bool = False):
315+ # raise NotImplementedError
316+ #
317+ # @abc.abstractmethod
318+ # def absolute(self):
319+ # raise NotImplementedError
320+ #
321+ # @abc.abstractmethod
322+ # def exists(self, *, follow_symlinks=True):
323+ # raise NotImplementedError
324324
325325 # additional function specific for OMCPath
326326 @abc .abstractmethod
@@ -478,45 +478,48 @@ class OMCPathLocal(OMCPath, pathlib.Path):
478478 Shortcut using pathlib.Path implementation; only working if OMCPath is used locally.
479479 """
480480
481+ def __init__ (self , * args , ** kwargs ):
482+ super ().__init__ (* args )
483+
481484 # modified copy of pathlib.Path.__new__() definition
482485 def __new__ (cls , * args ):
483486 if cls is OMCPathLocal :
484487 cls = OMCPathLocalWindows if os .name == 'nt' else OMCPathLocalPosix
485488 return object .__new__ (cls )
486489
487- # functions from pathlib.Path
488- def with_segments (self , * pathsegments ):
489- pathlib .Path .with_segments (self , * pathsegments )
490-
491- def is_file (self , * , follow_symlinks = True ):
492- pathlib .Path .is_file (self , follow_symlinks = follow_symlinks )
493-
494- def is_dir (self , * , follow_symlinks = True ):
495- pathlib .Path .is_dir (self , follow_symlinks = follow_symlinks )
496-
497- def read_text (self , encoding = None , errors = None , newline = None ):
498- pathlib .Path .read_text (self , encoding = encoding , errors = errors , newline = newline )
499-
500- def write_text (self , data : str , encoding = None , errors = None , newline = None ):
501- pathlib .Path .write_text (self , data = data , encoding = encoding , errors = errors , newline = newline )
502-
503- def mkdir (self , mode = 0o777 , parents = False , exist_ok = False ):
504- pathlib .Path .mkdir (self , mode = mode , parents = parents , exist_ok = exist_ok )
505-
506- def cwd (self ):
507- pathlib .Path .cwd (self )
508-
509- def unlink (self , missing_ok : bool = False ):
510- pathlib .Path .unlink (self , missing_ok = missing_ok )
511-
512- def resolve (self , strict : bool = False ):
513- pathlib .Path .resolve (self , strict = strict )
514-
515- def absolute (self ):
516- pathlib .Path .absolute (self )
517-
518- def exists (self , * , follow_symlinks = True ):
519- pathlib .Path .exists (self , follow_symlinks = follow_symlinks )
490+ # # functions from pathlib.Path
491+ # def with_segments(self, *pathsegments):
492+ # pathlib.Path.with_segments(self, *pathsegments)
493+ #
494+ # def is_file(self, *, follow_symlinks=True):
495+ # pathlib.Path.is_file(self, follow_symlinks=follow_symlinks)
496+ #
497+ # def is_dir(self, *, follow_symlinks=True):
498+ # pathlib.Path.is_dir(self, follow_symlinks=follow_symlinks)
499+ #
500+ # def read_text(self, encoding=None, errors=None, newline=None):
501+ # pathlib.Path.read_text(self, encoding=encoding, errors=errors, newline=newline)
502+ #
503+ # def write_text(self, data: str, encoding=None, errors=None, newline=None):
504+ # pathlib.Path.write_text(self, data=data, encoding=encoding, errors=errors, newline=newline)
505+ #
506+ # def mkdir(self, mode=0o777, parents=False, exist_ok=False):
507+ # pathlib.Path.mkdir(self, mode=mode, parents=parents, exist_ok=exist_ok)
508+ #
509+ # def cwd(self):
510+ # pathlib.Path.cwd(self)
511+ #
512+ # def unlink(self, missing_ok: bool = False):
513+ # pathlib.Path.unlink(self, missing_ok=missing_ok)
514+ #
515+ # def resolve(self, strict: bool = False):
516+ # pathlib.Path.resolve(self, strict=strict)
517+ #
518+ # def absolute(self):
519+ # pathlib.Path.absolute(self)
520+ #
521+ # def exists(self, *, follow_symlinks=True):
522+ # pathlib.Path.exists(self, follow_symlinks=follow_symlinks)
520523
521524 # additional function specific for OMCPath
522525 def size (self ) -> int :
@@ -527,11 +530,13 @@ def size(self) -> int:
527530
528531
529532class OMCPathLocalPosix (pathlib .PosixPath , OMCPathLocal ):
530- pass
533+ def __init__ (self , * args , ** kwargs ):
534+ super ().__init__ (* args )
531535
532536
533537class OMCPathLocalWindows (pathlib .WindowsPath , OMCPathLocal ):
534- pass
538+ def __init__ (self , * args , ** kwargs ):
539+ super ().__init__ (* args )
535540
536541
537542class OMCSessionZMQ :
0 commit comments