# Path: src/sii/lib/types/Branch.py
# class Branch(object):
# 
#     def __init__(self, yml):
#         self.__dict__.update(yml)
# 
#     def __getattr__(self, key):
#         if key.startswith('__'):
#             return super().__getattr__(key)
# 
#         if key in self.__dict__:
#             return super().__getattr__(key)
#         else:
#             raise RuntimeError("Expected and did not find <{0}> in branch section of YAML.".format(key))


from .Branch import Branch
""" Static Company Data (coming from YAML)

For a Template example look into files/companies.yml at the root of the repository.
"""


class Company(object):

    def __init__(self, data):
        self.__dict__.update(data)

# Path: src/sii/lib/types/Branch.py
# class Branch(object):
# 
#     def __init__(self, yml):
#         self.__dict__.update(yml)
# 
#     def __getattr__(self, key):
#         if key.startswith('__'):
#             return super().__getattr__(key)
# 
#         if key in self.__dict__:
#             return super().__getattr__(key)
#         else:
#             raise RuntimeError("Expected and did not find <{0}> in branch section of YAML.".format(key))


# Path: src/sii/lib/types/Company.py
from .Branch import Branch

""" Static Company Data (coming from YAML)

For a Template example look into files/companies.yml at the root of the repository.
"""


class Company(object):

    def __init__(self, data):
        self.__dict__.update(data)

        self.branches = [Branch(b) for b in self.branches]