package Ġcom . nil ang p ate l . t ms . model Ċ Ċ import Ġjavax . persistence .* Ċ Ċ @ Entity Ċ @ Table ( name =" comments ", catalog =" task _ mgmt _ system ") Ċ class ĠComments Ġ{ Ċ ĉ @ Id Ċ ĉ @ GeneratedValue ( strategy = Generation Type . IDENTITY ) Ċ ĉ private Ġvar Ġid Ġ: Int ?= null ĊĊ ĉ @ ManyToOne Ċ ĉ @ JoinColumn ( name Ġ= Ġ" user _ id ", nullable Ġ= Ġfalse ) Ċ ĉ private Ġvar Ġuser Ġ: ĠUser ? Ġ= Ġnull ĊĊ ĉ @ ManyToOne Ċ ĉ @ JoinColumn ( name Ġ= Ġ" task _ id ", Ġnullable Ġ= Ġfalse ) Ċ ĉ private Ġvar Ġtask Ġ: ĠTask ? Ġ= Ġnull ; ĊĊ ĉ private Ġvar Ġcomment : String ? Ġ= Ġnull ĊĊ ĉ fun ĠsetId ( id : Int ){ Ċĉ ĉ this . id = id Ċ ĉ } ĊĊ ĉ fun ĠgetId (): Int ? { Ċĉ ĉ return Ġthis . id Ċ ĉ } ĊĊ ĉ fun Ġset Task ( task : Task ){ Ċĉ ĉ this . task Ġ= Ġtask Ċ ĉ } ĊĊ ĉ fun Ġget Task (): Task ? { Ċĉ ĉ return Ġthis . task Ċ ĉ } ĊĊ ĉ fun ĠsetUser ( user : User ){ Ċĉ ĉ this . user = user Ċ ĉ } ĊĊ ĉ fun ĠgetUser (): User ? { Ċĉ ĉ return Ġthis . user Ċ ĉ } ĊĊ ĉ fun Ġset Comment ( comment : String ){ Ċĉ ĉ this . comment = comment Ċ ĉ } ĊĊ ĉ fun Ġget Comment (): String ? { Ċĉ ĉ return Ġthis . comment Ċ ĉ } Ċĉ Ċ }