package com.iqser.red.service.persistence.management.v1.processor.entity.annotations;

import java.time.OffsetDateTime;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.persistence.ManyToOne;
import jakarta.persistence.Table;

import com.iqser.red.service.persistence.management.v1.processor.entity.dossier.FileEntity;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@Builder
@Entity
@Table(name = "comment")
@AllArgsConstructor
@NoArgsConstructor
public class CommentEntity {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private long id;

    @Column
    private String fileId;

    @Column
    private String annotationId;

    @Column
    private OffsetDateTime date;
    @Column(length = 4000)
    private String text;
    @Column(name = "user_id")
    private String user;

    @Column
    private OffsetDateTime softDeletedTime;

    @ManyToOne
    private FileEntity fileStatus;

}
