I need help trying to figure out the proper design of my classes.
I have a user class:
class AppUser:
_email - String
_fullname - String
_organizations - List of ????
_active - Boolean
------------------
getOrgs - Method
Also, I have an Organizations class:
class Organization:
_name - String
_domain - String
_members - List of ????
------------------
getMembers
So, my issue is the Lists. The Org class has a list of _members. This list should probably be a list of AppUser objects. And, the AppUser class has a list of _organizations. This list should probably be a list of Organization objects.
But this would create a circular reference.
So, how should I implement this?
Edit: Need to implement this using Python.