Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Task 3 Your application allows you to manage Task and Project entities. You have to add missing annotations and code over entity classes and converters
Task
Your application allows you to manage Task and Project
entities.
You have to add missing annotations and code over entity classes
and converters to make it possible to store Task and Project
and their relations in specified tables.
Requirements
Project. updates should be persisted in a table with the
following structure:
Table name: PROJECTEVENTUPDATES
Columns:
PROJECTID : foreign key;
USERNAME : value of Itemupdate.user ;
EVENTDATE: value of Itemupdate. date
Task, watchers should be persisted in a table with the
following structure:
Table name: TODOWATCHERS :
Columns:
TODOID : foreign key;
LOGIN: value of string from the set.Task
NAME: Key trom the Map;
DESCRIPTION: value from the Map
Tables
The following tables should exist after implementation:
PROJECTS with columnS PROJECTID NAME ;
PROJECTEVENTUPDATES with columnS PROJECTID
USERNAME, EVENTDATE ;
TODOS with columns TODOID SUBJECT, DETAILS;
TODOWATCHERS with columnS TODOID LOGIN ;
TODOCOMMENTS with columns TODOID AUTHOR,
ADDDATE, COMMENT ;
TODOUPDATES with columns TODOID AUTHOR,
UPDATEDATE;
TODOWATCHERS with columnS TODOID NAME,
DESCRIPTION
Assumptions
Class names and function signatures should not be changed. Hints
In order to satisfy the requirements you should:
add missing annotations from the javax.persistencepackage to the Taskand
Projectclasses.
Source Code
The following classes have already been implemented:
ItemUpdate
@Embeddable
@NoArgsConstructoraccess AccessLevel.PRIVATE
@AllArgsConstructor
@Getter
public class ItemUpdate
private String user;
private LocalDate date;
Comment
@Embeddable
@NoArgsConstructoraccess AccessLevel.PRIVATE
@AllArgsConstructor
@Getter
public class Comment
@Columnname "AUTHOR"
private String author;
@Columnname "ADDDATE"
private LocalDate date;
@Columnname "COMMENT"
private String comment;
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started