<reponame>kira607/config_loader<gh_stars>0
from abc import ABC, abstractmethod


class ConfigSection(ABC):
    def __init__(self, section: dict):
        self._d = section
        self._init()

    def __getitem__(self, key):
        return self._d[key]

    def __len__(self) -> int:
        return len(self._d)

    def __iter__(self):
        return iter(self._d)

    @abstractmethod
    def _init(self):
        pass


class DefaultSection(ConfigSection):
    def _init(self):
        pass

from abc import ABC, abstractmethod


class ConfigSection(ABC):
    def __init__(self, section: dict):
        self._d = section
        self._init()

    def __getitem__(self, key):
        return self._d[key]

    def __len__(self) -> int:
        return len(self._d)

    def __iter__(self):
        return iter(self._d)

    @abstractmethod
    def _init(self):
        pass


class DefaultSection(ConfigSection):
    def _init(self):
        pass