All checks were successful
/ job (push) Successful in 1m12s
new development branch from root commit
26 lines
492 B
Python
26 lines
492 B
Python
"""Abstract Operating System."""
|
|
|
|
from abc import ABC, abstractmethod
|
|
from pathlib import Path
|
|
|
|
from rwx import Object
|
|
|
|
|
|
class OS(Object, ABC):
|
|
"""Operating System."""
|
|
|
|
def __init__(self, path: Path) -> None:
|
|
"""Set root.
|
|
|
|
:param path: root directory
|
|
:type path: Path
|
|
"""
|
|
self.root = path
|
|
self.name = self.get_name()
|
|
|
|
@abstractmethod
|
|
def get_name(self) -> str:
|
|
"""Return mandatory name.
|
|
|
|
:rtype: str
|
|
"""
|