package io.gmss.fiscad.entities.metadata;

import com.vladmihalcea.hibernate.type.json.JsonBinaryType;
import io.gmss.fiscad.entities.BaseEntity;
import io.gmss.fiscad.entities.infocad.metier.Piece;
import io.gmss.fiscad.entities.infocad.metier.Upload;
import jakarta.persistence.*;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.annotations.Type;

import java.io.Serializable;

@Entity
@Getter
@Setter
public class PieceMetaData extends BaseEntity implements Serializable {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    private Long pieceId;

    @Type(JsonBinaryType.class)
    @Column(columnDefinition = "jsonb")
    private Piece pieceJson;

}