Abstract Data Models and Diagram
User
Registered: set User
username,password: registered => one String
Profile[Post,User,SkillScore]
Current_posts: Profile=>set Post
profile_info: Profile=>set(Dict('gender':one String,sports: set String, skill: SkillScore, location: String,goal:String))
Alike[User,SkillScore]
preferences: Alike => set(Dict('location_range': Number, 'gender':one String, 'goal':one String, 'sport':set String,'skill_range': (SkillScore,SkillScore)))
recommended_users: Alike => set User
Post[Profile]
Stat: Post => one Stat
Picture: Post => one Picture
comment: Post => set Comment
postDate: Post => one date
Visibility[Post,User]
status: Visibility=> {Private | Friends | Public}
Friends: Visibility => set User post: Visibility => one Post userToAdd: Visibility => one User userToRemove:Visibility => one User
Connect[Profile]
from,to: Connect => one User
user1Group: Connect => Profile.profile_info.Friends user2Group: Connect => Profile.profile_info.Friends
SkillScore[Post]
currentScore: SkillScore=> one Number
opponentScore:SkillScore=> one Number Score: SkillScore => (Post.Stat, otherScore) :Post.Stat is the match score, otherScore is the opponents skillScore
valid_scores: SkillScore => set Scores
ExpiringResource[Post]
active: set Post.Stat
expiry: Post -> one Date
Diagram
Links to Vercel and Git
Look at git link to see Route outlines and code for visibility and connect concepts.