package de.avatic.taric.model;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import de.avatic.taric.serializer.FootnoteReferenceSerializer;
import lombok.Getter;
import lombok.Setter;
import org.springframework.data.jdbc.core.mapping.AggregateReference;
import org.springframework.data.relational.core.mapping.Column;

import jakarta.validation.constraints.NotNull;


@Getter
@Setter
public class NomenclatureFootnote {

    @JsonIgnore
    private Integer id;

    @NotNull
    @Column("footnote_id")
    @JsonSerialize(using = FootnoteReferenceSerializer.class)
    private AggregateReference<Footnote, Integer> footnote;

}
