Skip to content

Assignment 4

Data Modeling

app TrueLink

Concept: User

State:
user: set UserT
username, password: user -> one String
Concept: User

State:
user: set UserT
username, password: user -> one String
Concept: Post [Author, Content]

State:
post: set PostT
author: post --> one Author
content: post --> one Content
Concept: Post [Author, Content]

State:
post: set PostT
author: post --> one Author
content: post --> one Content
Concept: Comment [Post, Author]

State:
comment: set CommentT
author: comment -> one Author
post: comment -> one Post
content: comment -> one String
Concept: Comment [Post, Author]

State:
comment: set CommentT
author: comment -> one Author
post: comment -> one Post
content: comment -> one String
Concept: AIImageGenerator [ImageIn]

State: 
old_image : set ImageIn
input: set Input
imageOut: old_image, input --> one Image
Concept: AIImageGenerator [ImageIn]

State: 
old_image : set ImageIn
input: set Input
imageOut: old_image, input --> one Image
Concept: Friend[User]

State:
friendLists: set Friend
user1, user2 : friendLists (one friend) --> one User
Concept: Friend[User]

State:
friendLists: set Friend
user1, user2 : friendLists (one friend) --> one User
Concept: Session[User]

State
session: set Session
user: session -> one User
Concept: Session[User]

State
session: set Session
user: session -> one User
Concept: MemoryTimeCapsule [Author, Post]

State:
timeCapsule: set TimeCapsule
author: timeCapsule --> one Author
dateToOpen: timeCapsule --> one Date
memory: timeCapsule --> one Post
Concept: MemoryTimeCapsule [Author, Post]

State:
timeCapsule: set TimeCapsule
author: timeCapsule --> one Author
dateToOpen: timeCapsule --> one Date
memory: timeCapsule --> one Post
Concept: Reflection[Author, Content]

State:
reflection: set Reflection
author: reflection --> one Author
date: reflection --> one Date
content: reflection --> one Content
Concept: Reflection[Author, Content]

State:
reflection: set Reflection
author: reflection --> one Author
date: reflection --> one Date
content: reflection --> one Content

Data Model Diagram

Diagram

app TrueLink
    include
        Comment[User.user, Post.post]
        Post[User.user]
        MemoryTimeCapsule[User.user, Post.post]
        Reflection[User.user]
        Friend[User.user]
        Session[User.user]
app TrueLink
    include
        Comment[User.user, Post.post]
        Post[User.user]
        MemoryTimeCapsule[User.user, Post.post]
        Reflection[User.user]
        Friend[User.user]
        Session[User.user]

Design Reflection

Design Reflection: Separating Memories from Posts

Initially, I conceived a system where memories and posts were intertwined, allowing users to share posts while reserving them for future viewing. However, this approach posed a fundamental contradiction. Memories, by nature, are private until a set date. Combining them with posts, which are meant for immediate sharing, could lead to a user creating a post only to have it remain unseen—an unintended outcome.

To address this, I opted to distinctly separate memories and posts. This empowers users to create private memories, preserving their sanctity until the chosen date arrives. This shift aligns closely with the core essence of memories—precious moments to be revisited with a touch of surprise and anticipation.

The separation simplifies the user experience, eliminating potential confusion regarding when a post should be public versus kept as a cherished memory. This design decision not only upholds the integrity of both posts and memories but also enhances overall user satisfaction.

Collabs

I used chatGpt to help me with some of the coding parts for my comment, and memory concepts and my design reflection.