Skip to content

Instantly share code, notes, and snippets.

@inesp
Created September 2, 2019 13:26
Show Gist options
  • Save inesp/06a1755d853712718ff04479ae59dea6 to your computer and use it in GitHub Desktop.
Save inesp/06a1755d853712718ff04479ae59dea6 to your computer and use it in GitHub Desktop.
class Zoo:
def __init__(zoo_outline: ZooOutline):
self._owner_name: str = zoo_outline.owner_name
# TODO: It would be great to replace self._owner_name with
# reference to an actual Person model instance from the database.
# We probably get the owner name by fetching the owner person
# from the database.
# But this might be too invasive.
self._free_entrance_day = zoo_outline.free_entrance_day.value
# zoo_outline.free_entrance_day is an Enum, thus we call .value
...
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment